RRF3 and servo
-
@fma I don't use any servos so may not be able to help. But just looking at the example here https://duet3d.dozuki.com/Wiki/RepRapFirmware_3_overview#Section_M280 shows:
M280 P0 S80 ; set 80deg servo position on GPIO port 0
So going by that, your M280 P0 S1500 would be setting the servo position to 1500 degrees, which doesn't make any sense to me.
-
Nope, values above 200 are taken as µs, and below are taken as degrees.
Anyway, I tried with values in degrees, like 0, 90 and 180, and I get the same (non) result.
-
hi @fma what was our old M280 code on RRF2. have you tried without inverting the pin just to check?
-
The old M280 code has the I1 parameter, that's all. I'll try without inverting the pin; maybe using S in M950 already does that...
-
@fma said in RRF3 and servo:
M950 S0 C"!fan0" ; Servo 0 connected to 'fan0' pin (inverted)
Does that command return an error message if you send it from the command line?
What does M950 S0 with no other parameters return?
-
@dc42 said in RRF3 and servo:
Does that command return an error message if you send it from the command line?
No, no error.
What does M950 S0 with no other parameters return?
I checked that, and it looks ok:
GPIO/servo port 0 pin !fan0 frequency 50Hz
I tried without inverting, and I get the same result.
-
I also checked on fan1 output: same result.
-
I had the same issue driving a servo on the fan output (Duet Maestro)
Connect a pullup resistor of around 1K between the servo control (Fan PWM) and +5V.
-
You mean a pullup, according to your drawing.
I'll try that...
-
Bingo! In fact, it makes sens, as the pwm output only pulls the signal to ground... So, it has to be pulled up in order to have a high state voltage value!
I think I had this resistor with RRF2, but as I didn't use the servo since several months, I forgot that
Thanks!
-