Hello @HugPeter-9392
I will try to help as much as possible from my side, meanwhile SME on this topic respond to your queries!
Question 1: Can you confirm that the function pointer approach is a good and safe solution as long as residential application and ThreadX module use absolute positioning? What are the limitations of this approach?
Idea is good, it may not be portable across different platforms or architectures, as the memory layout may differ. For example, it can be difficult to debug and maintain the code when using function pointers, the function must be accessible from the residential application. More
Question 2: Can you confirm that when one of residential application and ThreadX module do not make use of absolute positioning, the solution is uncertain. Such an approach is not advisable for a new development.
This can lead to issues with memory alignment and address translation. Not advisable for new development. It is advisable to use a more robust approach such as message passing or shared memory.
Question 3: Can you explain the event flags approach in more detail? In my understanding event flags are for asynchronous event passing. But we need a synchronous return of the callback.
You can use event flags to signal the ThreadX module that the callback has been called and to wait for the ThreadX module to return the requested information.