vedderb / vesc_wand

This is the firmware for the VESC Wand remote control
GNU General Public License v3.0
18 stars 16 forks source link

Wand starts up with a current command #1

Open Peemouse opened 4 years ago

Peemouse commented 4 years ago

Hi @vedderb

I updated the WAND FW with the latest version (v1.2). Since then, when I switch the remote up, a light current is applied on the motors until I touched the throttle (accel or brake, it doesn't matter).

I shot a video for showing the behaviour : https://youtu.be/UUmjYL7CW8k

And a plot on VESC Tool : https://esk8-news-objects.s3.dualstack.us-east-1.amazonaws.com/uploads/optimized/3X/5/1/5150426db8b0ce13029ab614e34553e8b3723dd6_2_690x315.png

Also, could you push the latest version on Github ? That would ease the debugging process.

Thanks Sir !

EDIT : also notice the difference of deadband between acceleration and brake on the throttle. Accel. deadband is really tight although the brake only is pretty long. RT App on VESC Tool indicates -1,6% when in neutral position.

Peemouse commented 4 years ago

The issue is spotted. Waking the WAND up with the left button put it immediately in CC mode.

Please, consider 2 fixes :

  1. Ignore the buttons action at WAND start-up (using the right one makes switch the display)
  2. Add a minimum ERPM for engaging CC (VESC FW side)
vedderb commented 4 years ago

The intention with the latest update was to make the wand handle a reset without changing behavior. This means that the buttons behave the same regardless whether it was running before, or just started. As you can hold cruise control to take off, you can now do this from boot as well, which is what you are seeing here. The old firmware would ignore the buttons and joystick after boot for a while, and that would cause it to be ùnresponsive after a watchdog reset (which should not happen) or after a reset due to the batteries sitting a bit loose (I think this happened to someone).

Maybe a good compromise is to always react to the joystick, but ignore the buttons after boot until both have been released. What do you think?

Peemouse commented 4 years ago

The intention with the latest update was to make the wand handle a reset without changing behavior.

That makes sense.

Maybe a good compromise is to always react to the joystick, but ignore the buttons after boot until both have been released. What do you think?

Yes, I'm agree this that compromise. Regarding the frequency over severity ratio, it makes more sense to not have the "starting issue" than the "not keeping CC mode activated in case of reboot".

I'll create an issue on the FW repo for the CC activation at 0 ERPM. I already thought at a fix but for a perfectly clear UI/UX, that would need to display "CC" on screen on VESC FW request. Example : you activate CC though the button but conditions are not met VESC FW side. In the current way it's coded, "CC" is displayed though. This would need to come from a variable from the VESC.

What are your thoughts about this ?