If I define VNH2SP30 in the latest motor.ino from github, the measured controller voltage goes down by a factor 4.7 (resulting in BAD VOLTAGE), but the controller temp goes up by a factor 2.6. If I undefine VNH2SP30, I get correct readings for both measures. My question: how can I use the pwm_style=2 modus without messing up or disabling my readings? Thx!
Background:
D4/shunt_sense is pulled low, D5/low_current and D12/voltage_sense are left open.
When I switched to the new motor.ino I had to set DIV_BOARD to 1 otherwise I would get a NO MOTOR CONTROLLER message (I could see RxD light but no TxD light on the nano). I don't think this is relevant but it might be anyway.
EDIT: as per 09-APR-2020 this is no longer a variable that needs to be set.
It also occurred to me that D10/enable_pin, while giving an output signal, was high-impedance when engaged. Changing line 627 of motor.ino to pinMode(enable_pin, OUTPUT); now gives me a nice 5V signal when engaged, not depending on the load. I think you might want to change this one.
Background:
D4/shunt_sense is pulled low, D5/low_current and D12/voltage_sense are left open.
When I switched to the new motor.ino I had to set DIV_BOARD to 1 otherwise I would get a NO MOTOR CONTROLLER message (I could see RxD light but no TxD light on the nano). I don't think this is relevant but it might be anyway.
EDIT: as per 09-APR-2020 this is no longer a variable that needs to be set.
It also occurred to me that D10/enable_pin, while giving an output signal, was high-impedance when engaged. Changing line 627 of motor.ino to pinMode(enable_pin, OUTPUT); now gives me a nice 5V signal when engaged, not depending on the load. I think you might want to change this one.