CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to support@ccsinfo.com

PIC18F6722 stuck in i2c call
Goto page Previous  1, 2
 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
Ttelmah



Joined: 11 Mar 2010
Posts: 19195

View user's profile Send private message

PostPosted: Fri Feb 26, 2021 11:05 am     Reply with quote

If you think about it a 'brownout', is a very nasty failure for the chip.
Depending on luck, some memory cells can hold their values, while others
lose theirs. If the chip then keeps running, almost anything can happen.
You can end up with the wrong PC value, or the wrong data contents,
or a combination of both. Garbage.

Running without the brownout fuse is basically idiocy. That is what it is
there for, to ensure that when the voltage drops into this danger area, the
chip will restart sensibly.
Why anyone would want to run without this fuse enabled is almost
inexplicable (actually, there are a couple of PIC's where the selectable
brownout voltages are not useable on certain chip versions, so on these
not using it makes sense, but on all other chips it really is a feature that
should be enabled). In this particular case is seems that the brownout may
result in something like a jump to perhaps an address like 0x100 or 0x200,
which if a bootloader is present can result in disaster.
asmallri



Joined: 12 Aug 2004
Posts: 1630
Location: Perth, Australia

View user's profile Send private message Send e-mail Visit poster's website

PostPosted: Sat Feb 27, 2021 6:01 pm     Reply with quote

Ttelmah wrote:
If you think about it a 'brownout', is a very nasty failure for the chip.
Depending on luck, some memory cells can hold their values, while others
lose theirs. If the chip then keeps running, almost anything can happen.
You can end up with the wrong PC value, or the wrong data contents,
or a combination of both. Garbage.

Running without the brownout fuse is basically idiocy. That is what it is
there for, to ensure that when the voltage drops into this danger area, the
chip will restart sensibly.
Why anyone would want to run without this fuse enabled is almost
inexplicable (actually, there are a couple of PIC's where the selectable
brownout voltages are not useable on certain chip versions, so on these
not using it makes sense, but on all other chips it really is a feature that
should be enabled). In this particular case is seems that the brownout may
result in something like a jump to perhaps an address like 0x100 or 0x200,
which if a bootloader is present can result in disaster.


To add to this, it is obvious when you think about it, that a PIC that includes a bootloader but does not have brownout enabled and correctly set is very likely to corrupt the contents of Program Memory as the bootloader contains code specifically to modify program memory. So, if a brownout occurs it is not surprising that part of the bootloader code could be executed.
_________________
Regards, Andrew

http://www.brushelectronics.com/software
Home of Ethernet, SD card and Encrypted Serial Bootloaders for PICs!!
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group