Driveworks plugin for an IMU integrated GNSS

Please provide the following info:
Hardware Platform: DRIVE AGX Xavier™ Developer Kit
Software Version: DRIVE Software 10
Host Machine Version: native Ubuntu 18.04

Hello,
I wish to write a custom IMU & GPS plugin for SAL to use the SBG ellipse Single Antenna RTK GNSS which is basically an IMU integrated with a GNSS reciever.
It has its own SDK for communicating with the device which I thought to use writing my plugin but the problem is that from what I saw the plugin is for GPS or IMU not both and so I can’t write a single plugin which will output both IMU frames and GPS frames.

I do have a solution which is to have an object shared between the GPS and IMU plugins which will save the messages from the device and the plugins will read from it instead directly from the device.
Is there a better solution?

Thank you

Hi @biber.barak,

From software perspective, I’m not sure what’s the limitation of not able to write a single plugin for both IMU and GPS.

Below are the plugin interface documents for GPS and IMU respectively on your host system (after installed DRIVE Software 10.0). Please take a look at them for the details.

/usr/local/driveworks-2.2/doc/nvsdk_html/group__sensor__plugins__ext__gps__group.html
/usr/local/driveworks-2.2/doc/nvsdk_html/group__sensor__plugins__ext__imu__group.html

Hi @VickNV ,

I have a similar requirement writing a plugin for a device that provides both IMU orientation and GNSS longitude/latitude.

Do you have any example code to achieve this?

I guess there needs to be two separate dw plugins (but maybe the appropriate function tables can be in the same .so file). The two dw plugins need to implement dwSensorIMUPluginFunctionTable and dwSensorGPSPluginFunctionTable

Some functions in the function tables could be common between the two plugins.

Let’s start at readRawData.

If the sensor uses TCP socket, does this mean there should be two separate sockets, one for IMU and one for GPS? Of course it would be better to just have a single socket shared between both IMU and GPS, but can this be done with the plugin system?

Hi @gpu_power ,

As far as I know, our implementation for “Xsens: Inertial Measurement Unit MTi-G-710” listed in DRIVE Ecosystem Hardware and Software Components | NVIDIA Developer also has different drivers for GPS and IMU but uses the same tty device (not with the Plugin Framework though) and some rig file (e.g. /usr/local/driveworks-3.5/tools/capture/configs/rwd/hyperion7_1/release.json) uses both at the same time. So, I don’t think it will have any problem.

@VickNV can you please explain how to do this without the Plugin Framework?

Sorry for confusing you. I was talking about sensor drivers of a default supported sensor (implemented by nvidia).
For other custom sensors, you still need to follow DriveWorks SDK Reference: Integrating with Custom Sensors.

Thanks for clarifying @VickNV.

Would it be correct to use dwSensor_readRawData() on a dwSensorIMUPlugin and then re-use the same data and size on a dwSensorGPSPlugin?

This way, the same data and size would be used by dwSensorIMU_processRawData and dwSensorGPS_processRawData. Is that how the Plugin Framework should be used?

Please help to create another topic (linked to this topic) for this. Thanks.