Hi, I am hooking up a basic esc (the latest one, just bought it) to an Arduino Leonardo connected to my Raspberry Pi. I am running Pyfirmata on the Pi, which talks to the Arduino. I was able to run another ESC I had (Castle Creations Phoenix 25) this way but I have not been able to get the basic ESC to drive a T100 thruster. Here is the relevant code:
esc_l = board.get_pin(‘d:3:s’)
board.servo_config(3,1100,1900,90)
(wait)
esc_l.write(120)
What I am trying to do here with the servo_config statement is set the min and max pulsewidth to 1100 and 1900, respectively, then set the initial “angle” (since I am using servo mode) to 90 degrees, since this should be the middle of the range corresponding to a pulsewidth of 1500 required for arming. However, the ESC does not arm. If I send esc_l.write(0) it does arm (as indicated by the 2 tones, repeating every few seconds), but this does not make sense to me since for 0 degrees it should be sending 1100, and if I then send (say) esc_l.write(60), the thruster still does not move. I’m going to keep fiddling with it but if anyone can help me I would appreciate it. The Pyfirmata documentation has been charitably described elsewhere as ‘sparse’ (pyFirmata — pyFirmata 1.0.0 documentation), and the PWM mode is even less well documented than the servo mode, so I haven’t been able to find the answer there. Thanks! Chris