Jetson Nano + Arduino due

Hello, i am trying to build a mobile 4 wheeled rover with 4 quadrature encoders
i use an arduino due to read the encoder counts and then later publish them as ros topics.

I know that my arduino code is correct since i have got it working with my pc running ros kinetic,
however jetson nano uses ros melodic but the python scripts working as drivers should’t be affected

When i connect the arduino due to the Nano through usb, it returns wrong encoder count values back to the Nano although the communication bewteen them is succesfull.

I’m a little lost, what advice you give me to connect arduino boards with the nano specifically (due with ros), should i use I2C instead of the usb?

Are there any easy ways to read 4 quadrature encoders directly to the nano and sent pwm pulses?

Thank you, sorry for the ambiquity of my question

You may check other users’ experience:

You might want to have a look at what this individual did.


Why must we use the arduino, Teensy… to read quadrature encoders?

I have configured Jetson nano GPIO to read pulses of quadrature encoders, and I have use interrupts and it has a big problem to attended the request and it never count well the pulses, nither higth speed nither low speed.

Hi i have fixed that problem, i think the easiest way is with rosserial + an arduino due so it will have the compute to read the 4 encoders directly + pid + publish encoder ticks for odometry, #defive USE_USBCON in order for rosserial to work with arduino due, check this
or my project

1 Like