I am currently making a current sensing board for my DC brushed motor driver.
The driver I a using just has a fixed OverCurrent protection (1.5 Amps) but I would like to adjust the current level of the protection to 1 amp.
I am using a shunt resistor instead of a hall effect based current sensor because I have no I/O left to drive this sensor.
Then the process is simple :
- Compare the voltage of the Shunt to a reference voltage using an op-amp comparator design
- Adjust the level of the OP-AMP output (5V) to triger an interrupt on the arduino input(3.3V).
- Brake the motor during the interrupt handle.
I have no problem developping the points 1 and 3 but I need advices on the best method for 2.
I could use a voltage divider or unidirectionnal logic level controller (5volts to 3.3Volts).
Do you have any idea on what is the best solution ?
Also, would a pull-up resistor would be enough and if not why ?
Thank you all for your help,