Confused with requirement for powering my uC with 12V supply and using ADC to read the value.

Thread Starter

electronicsLearner77

Joined May 26, 2012
127
I am bit confused, I know it is very hard for you to suggest without knowing the complete details. But please suggest me as per your experience. I am powering my micro controller with 12V supply and able to read this value using ADC. My requirement says if I detect the failure of 12V supply I should be in a position to smoothly stop the motor. How is it possible? If my 12V is lost my code will not be executing. What are the different methods i can approach this to solve it either software or hardware or both? Please advise.
 

Thread Starter

electronicsLearner77

Joined May 26, 2012
127
Is removing power feed to the motor the same as "smoothly" stopping the motor? In which case, the Power switch to the motor is a Relay or a FET activated by the 12 V supply.
Or do you mean something else...?
The supply to the micro controller is separate and supply to the motor is separate. There is a chance that the 12v power feed line gets disconnected then how do i control the motor? Do i need to keep some kind of on board cell or something else to execute the code?
 

Ramussons

Joined May 3, 2013
1,414
Do You want a power backup for the controller or just want power off the motor if the controller supply fails?

I thought it was the second option :D
 

ericgibbs

Joined Jan 29, 2010
18,872
hi 77,
As you are powering the MCU via a 5V reg, why not add a diode and buffer capacitor on the 5V supply and sense when the 12V source fails.
The MCU could then do a controlled motor shut down, before its 5V fails.
E
 

Thread Starter

electronicsLearner77

Joined May 26, 2012
127
Thank you very much for the circuit. I should design the circuit such that i have sufficient time to read the falling voltage?
Controlled motor shut down according to me is to slowly decrease the duty cycle to 0. Am i correct in this?
 

ericgibbs

Joined Jan 29, 2010
18,872
Hi 77,
A rough calculation suggests that the motor is ~1HP.
It may take some time to stop, especially if it driving a rotating mass ie: a flywheel
So the size of capacitor on the 7805 input will have to be chosen to keep the MCU controlling, over the motor stopping period.
Or you could consider dynamic braking of the motor, if the power driver for the motor can be configured to do that.?
E
 
Top