I am working on a project where I would like to port the control part on a cloud and exchanging data via 4G.
Right now I’m trying to setup the network and RTPS seems to be the way to go. I will use a Raspberry pi to connect on the 4G network using a dongle.
I think RTPS is installed correctly, the path is ok but after building there is no client file in the build.
I installed Px4 3 weeks ago. Anyone knows about this issue ?
Trying to run the manual generation also doesnt work since the python files missing in the src/Tools directory but are only in the srs/msg/tools/ directory.
Moreover, I can’t find the set(GENERATE_RTPS_BRIDGE on) in my cmake/config/posix_sitl_default.cmake so i just added set(GENERATE_RTPS_BRIDGE off), not sure if it is correct ?
Problem solved.
The tutorial conserning RTPS is not up to date with the latest version of PX4.
I had to move files inside the folder srs/msg/tools/ to src/Tools and run manually the python client/agent generator. It looks like the auto generator is not working anymore.
Hi,
I am having the same problem here…
I moved the files to src/Tools and then I ran the “generate_microRTPS_bridge.py” script.
After that, I moved to “~/src/Firmware/src/modules/micrortps_bridge/micrortps_agent/build” and ran the “cmake …” and “make” commands, but I got an error.
It returns:
error: ‘get_header_length’ was not declared in this scope
uint16_t header_length = get_header_length();
^~~~~~~~~~~~~~~~~
Do you know what’s missing?
Thank you so much,
elBarto
edit
I fixed it! There’s an error in the code…
In order to build the agent, you have to change:
Hi,
I found out that the rtps module can be included in the build process using the makefiles whose names end with “_rtps”.
If you make the px4fmu-v3_rtps, the module is correctly built and included in the elf target file ([ 95%] Built target modules__micrortps_bridge__micrortps_client).
Unfortunately, I have a first generation pixhawk (one of those with the flash size issue) and I can’t upload the v3 firmware on it. The v2 firmware instead doesn’t have a makefile that includes the rtps module, probably because it wouldn’t fit in the flash.
Finally, I tried to build the “posix_sitl_rtps” makefile, but I got this error:
/home/emanuele/Firmware_clone/Firmware/src/modules/micrortps_bridge/micrortps_client/microRTPS_transport.h:41:7: error: redefinition of ‘class Transport_node’
I am still trying to make it work… let’s keep in touch
Yes idealy I would like to test everything in simulation. Right now I can run the agent and listener but not the client. I believe they changed quite a bit the Transport_node class. I’ll dig into the code tomorrow and let you know if I can get any results.
Hi,
thank you so much for guiding me through it.
I did a fresh start, deleted the old folder, made a new one, pulled the repository… and it finally worked.
I have been able to build client, agent and listener. But when I run the client from the jMavsim console, it fails because it can’t open the /dev/ttyUSB0 port (how can I blame it since a physical tty port doesn’t exist).
So I think I will wait for a real pixhawk to test it. I have already ordered a new mRo Pixhawk.
Have you been able to make it work within the SITL simulator? It would be great to test it before flying