eProsima / Micro-XRCE-DDS-Apps

Looking for commercial support? Contact info@eprosima.com
10 stars 5 forks source link

Run SharedMemoryReqRep example on nuttx on board #25

Closed PierrePeng closed 3 years ago

PierrePeng commented 3 years ago

I am trying to run the SharedMemoryReqRep example on NuttX. It works on the simulation but gets some fused output on board. Here are the steps I have done.

  1. Copy the SharedMemoryReqRep example to nuttx/apps/examples.
  2. Add Makefile, Kconfig, Make.defs files in the SharedMemoryReqRep folder.

log.txt SharedMemoryReqRep.tar.gz

pablogs9 commented 3 years ago

Could you debug and explain a bit what is happening? Segfault? Which board are you using?

PierrePeng commented 3 years ago

Some debug info flash the screen after running the SharedMemoryReqRep example. The output log has attached above. The board is bes2600(Cortex-M33).

https://user-images.githubusercontent.com/23045104/138846245-a7d2e59b-906b-4c2f-9ebb-cb33f4597ec0.mp4

pablogs9 commented 3 years ago

But could you determine the line that is causing the error?

PierrePeng commented 3 years ago

In this line. https://github.com/eProsima/Micro-XRCE-DDS-Client/blob/781fce66fcff3efff027d2f0d4cfa0b1d3e76d29/examples/SharedMemoryReqRep/main.c#L122

PierrePeng commented 3 years ago

I found the reason is buffer size! Thanks a lot