View previous topic :: View next topic |
Author |
Message |
Gabriel
Joined: 03 Aug 2009 Posts: 1067 Location: Panama
|
changing power supply levels |
Posted: Mon Feb 22, 2010 11:52 am |
|
|
hello all,
... to the point:
I will be powering a circuit by a 3.6V Ni-Mh pack and a MAX756 booster IC.
My PIC sleeps and upon wake up from a RTC, it starts the booster so that it can run at 5V while reading some sensors and processing some data, upon finishing reading all sensors, it goes back to sleep, and the booster chip is turned off.
So basically PICs Vcc will go from ~3.3V to 5v and back to ~3.3V.
Sleeping at 3.3v and working at 5V...
Does anyone know if this is acceptable? (16F87XA)
Is there any fuse I should be keeping my eye on for this type of power scheme?.... I know brown-out is out of the question.... but is there anything else?
Thanks. _________________ CCS PCM 5.078 & CCS PCH 5.093 |
|
![](templates/subSilver/images/spacer.gif) |
Gabriel
Joined: 03 Aug 2009 Posts: 1067 Location: Panama
|
|
Posted: Mon Feb 22, 2010 4:15 pm |
|
|
Anyone?, I'll be more specific
The MAX756 has a low battery output... (open drain) it sinks when a low battery condition is met.
I'm thinking of using this pin to hold the PIC in reset (as in use it to bring the MCLR line low) because of the low battery conditions to prevent any malfunction because of low voltage, until voltage is restored to a usable voltage... thus preventing the pic to even start running when it gets an interrupt from a RTC.
(The battery which the boost chip sources its power from is trickle charged by solar panels....)
I think it would be wise to use the PWRT when coming out of the reset (as in when the Vcc is restored to an appropriate value).
But I read/understand that the PWRT is only used with the POR.
How can I set up the POR? Does POR even apply for this set up?
Also, I might have not understood the BOR concept/set up well enough
and it is in fact the solution I want.
Anything?
g _________________ CCS PCM 5.078 & CCS PCH 5.093 |
|
![](templates/subSilver/images/spacer.gif) |
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Mon Feb 22, 2010 6:06 pm |
|
|
Your overall question is "what's the best way to do a power supply for a data logger" ? |
|
![](templates/subSilver/images/spacer.gif) |
Gabriel
Joined: 03 Aug 2009 Posts: 1067 Location: Panama
|
|
Posted: Tue Feb 23, 2010 5:58 am |
|
|
hmmm .... NO.... its what I'm working on but, I already built the power supply, made the PCB, etc. I'm concerned in how to handle the voltage changes the PIC will go through. My voltages are within the PICs Range, but I don't know if I can just swing the voltage within the limits of that range at my will.
I'm not asking for a supply... I made one... and I can play with some of its features/options. I am considering a particular setup in which I would like to know if:
Can I swing the voltage from 3.3 to 5v while the pic is running/sleeping?
Fuse settings to avoid unwanted resets, or allow the vcc to swing? More
specifically I'm a bit fuzzy as to what can be done with the BOR.
Can I make the pic start X number of cycles or X msec after the reset pin goes high? (the PSU controls the reset pin, so I don't know if POR applies, if so, how?)
Can I hold my PIC in reset for extended amounts of time?
Does a PIC consume any power when held in reset?
Thanks
g _________________ CCS PCM 5.078 & CCS PCH 5.093 |
|
![](templates/subSilver/images/spacer.gif) |
Guest
|
|
Posted: Fri Feb 26, 2010 9:30 am |
|
|
>>>Can I swing the voltage from 3.3 to 5v while the pic is running/sleeping?
Yes - However charging your decoupling capacitors does consume power - that's why most folks don't have dynamic power rails - it's not worth it in the long run. Plus the current consumption of your extra power supply circuitry, etc... My opinion naturally, your mileage may vary.
>>>Fuse settings to avoid unwanted resets, or allow the vcc to swing?
>>>More specifically I'm a bit fuzzy as to what can be done with the BOR.
Make sure on the low swing that you never, ever get to the BOR - or disable the BOR.
>>> Can I make the pic start X number of cycles or X msec after the reset pin goes high?
>>>(the PSU controls the reset pin, so I don't know if POR applies, if so, how?)
You just have the POR to play with - this is covered on the data sheet.
>>>> Can I hold my PIC in reset for extended amounts of time?
Yes - it can be in reset forever.
>>> Does a PIC consume any power when held in reset?
Yes.
HTH - Steve H. |
|
![](templates/subSilver/images/spacer.gif) |
Rohit de Sa
Joined: 09 Nov 2007 Posts: 282 Location: India
|
|
Posted: Fri Feb 26, 2010 12:10 pm |
|
|
Gabriel wrote: | Can I make the pic start X number of cycles or X msec after the reset pin goes high? | On most PICs (16Fs), doing a soft reset does _not_ wipe out the RAM contents. By 'soft reset' I mean using the instruction:
Note that this is not true of all registers - you need to be careful and read the data sheet, because some registers lose data on a restart.
But anyway, the idea is that you could have the following code at the beginning:
Code: | int8 cause=0;
a=restart_cause();
If ( (a==normal_power_up)|(a==brownout_restart)
{
delay_ms(1000);
} |
Rohit |
|
![](templates/subSilver/images/spacer.gif) |
|