I had a quick question after running some initial test.
It looks like the Navio2 PWM output is limited at 400Hz regardless of setting the ESC frequency above 400Hz.
As you can see below, I have captured the PWM (for a hexa) at several different frequencies and they seem to match pretty well from 50Hz up to 400Hz by adjusting the APM RC-SPEED setting
This is a known limitation at the moment, we are working on an updated firmware. PWM examples are in the navio2 repo. Code will be released eventually, but I do not have an exact date.
Actually after looking through the APM repo, I noticed that the INS (IMU sampling) as well as the rc-output are on 400Hz loops, so even a firmware update will not add any benefit unless the loops are also sped up.
I’m working on a small indoor rover and wish to drive four motors with drivers using NAVIO’s PWM.
I’m using 400Hz currently, but ideally I’d like to have supersonic frequencies (e.g. >20kHz). I’ve seen this thread, according to which it seems possible.
Hi. I’m working on a rover project and planning to modulate DC motors by Navio2’s PWM outputs.
To avoid the PWM noise, I’d like to use ultrasonic frequency (like > 20 kHz) as well.
I observe 400 Hz limit for PWM frequency even on the latest version (20170323) of Emlid Raspbian.
I suppose supporting higher PWM frequency is not very difficult task because Navio2 have a nice processor chip to do PWM.
Could you update the firmware in the near future?
Don’t know if they fixed this. I have moved on to another controller.
The 400 Hz update had nothing to do with driving servos, to suggest that is just crazy. The PWM out is to drive ESC and the > 400 Hz is so they can have a fast update to adjust the motors at a high cyclical rate
Is there any update on maximum PWM frequency? I’d like to control BrushedWithRelay motors but it seems like it is not possible with Navio2 as the minimum PWM frequency there is 1kHz (normal 20kHz)?
Could you make a note somewhere in documentation please that BrushedWIthRelay and BrushedBiPolar motor modes are not supported? I’ve spent quite some time trying to investigate this issue…
Also is the motor driver firmware available as Open Source? Maybe I could fix this issue myself and submit a patch?
The STM controller uses the RCIO code for generating PWM impulses. RCIO code is not open-source so there’s no possibility to edit it.
Navio2 output mostly used to directly maintain servos or ESC. Is there any specific reason that you don’t want to use ESC controller for your motors?
Assumed it is a standard feature of ArduPilot, 400Hz limitation for a hardware PWM came a bit unexpected, had even to purchase an oscilloscope to understand what’s going on
Well, it wasn’t really sorted - I just had to spend significant time debugging the issue because of poor documentation and invest in new hardware again because the standard ArduPilot functionality is not supported.
And given that the problem was raised a few years ago - I don’t have much faith in Navio2 now.
Duty cycle controlled H bridge motor drivers are reasonably priced and they suit well for running electric outboard motors which can be used for powering large scale autonomous boats.