Hi Ben,
While standstill, if sensors are present and brake applied, is this possible to switch to PID_POS to apply kind of handbrake to the board ?
Could be very convenient when boots are strapped like on an eMTB and waiting for green light. Sometimes, the board still go slowly forward even with brake applied.
Let me know if it's an interesting fetaure to you or if it's already doable with some tweaks in VESC Tool.
Thanks for your work,
Clèment
YES PLEASE i have the same problem that would be great to have that fix !!!
I agree that this would be useful. Added to todo list:
http://vesc-project.com/node/110
Implementing it with an encoder such as the AS5047 should work well, but even better would be if it also works with hall sensors only. Best is probably to go to speed control mode and set a 0 speed goal and use the I part to get rid of slow rolling.
Would not to be possible to implement it in a non-sensored setup with an iterative approach? A current X is applied while the BEMF is monitored, if a voltage is detected the initial current X is increased until no voltage is measured, meaning that the motor has stopped. The board would first roll a bit until the VESC determines the current needed to remain stationary in given situation, but is better than nothing
Or the BEMF generate by such slow revolution is too small to be detectable?
Or the Handbrake current could be setup in VESC tool, full brake would apply a current set by the user. This would use more energy since in most situations more power than needed would be used, and maybe the motor would heat up too much
I would like to vote for this as well, Hall Sensor Mode.
As I wrote a while back, mine is a CableCam. At speed=0 (and with Speed Controller's Minimum ERPM set to 0) I would expect the Cablecam to stay put where it is, even if the rope is going uphill.
https://www.youtube.com/watch?v=VLPpT_wAVdM
A poor man's solution and one that would work in all modes would be to energize one phase with a default amount of amps. If you guessed it right it will hold the position, if the value is too high you waste energy. The better approach is of course to blend in the positional logic at speed=0 to hold the current position with the energy required at of this moment.
PS: Just bought a Vesc6 because of how nice it works with the 4.11 hardware. Good progress!
The VESC tool has something like a Handbrake current to play with. Isn't that exactly what I look for as poor man's solution?
So as soon as the requested speed falls below the minERP value, I set the Handbrake instead.
What does the handbrake actually do? As simple as I said to energize one phase? Or more advanced so it also checks if the motor is turning although handbrake is on? My fear is the transition from moving with minERPM. to standstill. If the handbrake current is not high enough to stop the motor immediately, it will turn. First decelerated by the magnetic field and once it went over the peak field level, it gets accelerated.
Any input?
@bejamin: Here as well the question of how you would impement the handbrake logic you have in your TODO list.
Goal is: when PID Speed = 0, the motor shall not move even when you are standing on a not-horizontal street.
An update on my current experiments and more questions....
For braking in general there are multiple options
My current implementation:
I use the PID speed control mode of the VESC, have configured the min-eRPM to 100. As any value below that is considered a zero speed and that means free wheeling, at speeds lower than that the only option I have is to switch to other commands and actively stop the motor.
You could send a handbrake command for example. The result of that will be a constant amount of power is applied to one winding, creating a strong magnetic field and thus locking the motor at that position. Unless the kinetic energy of the skate board, the person riding it and the speed at 100eRPMs is greater than the magnetic field of the motor. It usually is. In that case the effect is zero, because the magnetic field decelerating the one pole is accelerating the next. You get an uneven movement but the braking momentum in average is zero.
At minute 1:24 you can see that in action, handbrake with 10A. 4 pole motor and 1:5 gear.
Hence I have built in the following strategy:
This is obviously not perfect. For once the transition from PID mode to braking to handbrake is uneven. You can see that in above video. But if the PID mode would allow min-eRPMs of zero and implement a logic like the above, this would be solved.
My main concern however is the power consumption. As you see in above's video, the 10A is not soo much. If the rope/street is not horizontal but steep, it would certainly not be enough. But a constant application of 10A means a 5000mAh battery is drained after 30 minutes of standing still. That's a lot of power wasted for doing essentially nothing.
Position control should be the same as above because it essentially is. With finer resolution maybe and inbuilt adjustment of the amps but from a power consumption point of view it would suffer from the same problem.
My current thinking is, a PID=0 speed should result in an extremely slow movement, not a stand still. Slow enough so that it does not hurt. Enough hall sensor signals for the position control to work.
Do you have any insights that contradict my findings or better ideas?
PS: Is there a command to short circuit all three motor phases? Would like to see how much brake momentum that generates.
Any update on this enhancement request for Speed=0? I need to jump through a lot of hoops in order to workaround it.
Per my finding, the combination of tacho speed and handbrake is all you need. This would allow to set the minERPM to 0 and to get a decent brake force when setting s PID=0 speed.
Downsides of my current implementation are
@Benjamin
Can you tell me when the handbrake will be implemented?
We urgently need it for the Cablecam
@Benjamin
Any news about handbrake? It is very useful for many applications...
Handbrake mode PLEASE !!!!!!!!!!
@benjamin
please give us an answer.
We have been waiting for an answer for almost a year now.
If it should not work, no problem, but then at least I know about it.
Yes please I would really like the handbrake function for my trampa electric mountain board ! Me and everyone who has one needs it !
This feature works now with the Wand remote.
This is not really a handbrake but it may be enough for the most of us. :)
But in the case of Photokopter, I'm not sure it's satisfaying him.
The feature can be adjusted to very little RPM. You can find it in the APP settings. It is called smart reverse.