I am wiring this up, and I would like to limit the current being drawn from 18v DC/DC converter.
What would be the simplest way of doing this?
Submitted 1 week ago by boojumliussnark@lemmy.world to askelectronics@discuss.tchncs.de
https://lemmy.world/pictrs/image/85954ada-6138-4bb6-a86b-8f37915b45c2.png
I am wiring this up, and I would like to limit the current being drawn from 18v DC/DC converter.
What would be the simplest way of doing this?
Turning a voltage sensing relay into a current sensing relay is basically just putting a small resistor in parallel with the sensing pins and setting the cutoff accordingly. Or like the other poster said, using the pico to do the same thing with pwm control, or just driving a FET on the power feed if you want to avoid writing pwm control code.
litchralee@sh.itjust.works 1 week ago
I don’t think there’s a good way to adapt this circuit to provide current limiting on the 18v rail. Supposing that it was possible, what behavior do you want to happen when reaching the current limit? Should the motor reduce its output torque when at the limit? Should the 18v rail completely shut down? Should the microcontroller be notified of the current limit so that software can deal with it? Would a simple fuse be sufficient?
All of these are possible options, but with various tradeoffs. But depending on your application, I would think the easiest design is to build sufficient capacity on the 18v rail so that the motor and 5v converter inherently never draw more current than can be provided.
boojumliussnark@lemmy.world 1 week ago
Thanks for taking time to look at this! :)
The issue is that if something is blocking the motor, or the limit sensor is not working, the motor should stop before burning itself out or breaking stuff.
I did buy a hall effect current sensor (www.aliexpress.com/item/1005006222090940.html) that I was thinking of connecting to the pi pico on an interrupt enabled pin, so I could cut off the engine output at the source, and alert my upstream controller. But I just couldn’t wrap my head around how to implement it.
Another option that I considered was putting some kind of fuse on the 18v rail and try to figure out how to detect if the 18v rail was dead and feed that to the pico - but then I’m not really sure how much simpler (if at all) that would be.
The picos inputs are 3.3v btw.
litchralee@sh.itjust.works 1 week ago
In that case, I would suggest looking at a different motor driver. The driver you’ve specified doesn’t seem to have any provisions to detect a motor stall, which is something that other drivers can potentially do. Ideally, the driver would detect the back EMF from the stall and inform the microcontroller, which would then decide to stop movement.
An external current sensor might work, but that’s adding to the part count and might not be as capable as built-in functionality within the motor driver. Plus, fancier motor drivers have some neat features that you could take advantage of as well. I think it would be more prudent to consider a different driver before adding additional parts.