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

Fail on first access to i2c (SOLVED)
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
oxo



Joined: 13 Nov 2012
Posts: 219
Location: France

View user's profile Send private message

PostPosted: Mon Jun 06, 2016 1:43 am     Reply with quote

Not hot or cold.

I am screwed now, because it's been working since friday morning, and I can't get it to fail again.
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Mon Jun 06, 2016 2:07 am     Reply with quote

That actually is helpful. It likely means that your lab conditions are
different than field conditions in some way. Try to imagine what
the differences are, and try to duplicate them in your lab. Visit the
field location and look around.

1. Temperature
2. Humidity
3. Static electricity (carpet, humidity, people, etc).
4. Power source stability and cleanness.
5. Shielding of the circuit board from nearby EMI pulses.
6. Human intervention
7. Animal or insect intervention
temtronic



Joined: 01 Jul 2010
Posts: 9136
Location: Greensville,Ontario

View user's profile Send private message

PostPosted: Mon Jun 06, 2016 4:59 am     Reply with quote

If this is just ONE board that now works, check the PCB for connections and solder joints. I had some PCBs that failed in the field,on very cold days.Turned out one of the hand sldered joints was never done. The trim pot wiper was just in contact and NOT soldered to the PCB.Once it got into the Real World and got real cold, PCB contracted and wiper was no longer in he circuit. This of course had to happen in the middle of the night, middle of Winter in a cast iron foundry.
Since you've isoloated it to just 2 chips( the PIC and the gas gauge),use a high powered magnifier and a dental pick to confirm they are soldered properly.
As it's now working, as Mr. T say 'something' has changed which is good, it's a matter of finding out what now.

Be systematic, make a list, check off items as you go.

Jay
newguy



Joined: 24 Jun 2004
Posts: 1903

View user's profile Send private message

PostPosted: Mon Jun 06, 2016 6:48 am     Reply with quote

Since no one else has mentioned it, this could also be caused by a cold solder joint(s).

In my first real job the quality guy gave us the standard spiel regarding common failure modes and cold solder was number one closely followed by ESD damage.
oxo



Joined: 13 Nov 2012
Posts: 219
Location: France

View user's profile Send private message

PostPosted: Tue Aug 02, 2016 3:50 am     Reply with quote

Here's an update..

Problem is solved.

It turned out to be caused by the charger not bringing the flat battery up above the minimum supply voltage for the gas gauge chip.

If the code writes to the gas gauge chip before the minimum voltage is achieved, the chip locks up, and the only way to get it back is to remove the battery power.

So now I have a 50 second delay after applying the power before initialising the gas gauge.

Thanks to all for helpful suggestions Smile
Ttelmah



Joined: 11 Mar 2010
Posts: 19267

View user's profile Send private message

PostPosted: Tue Aug 02, 2016 4:35 am     Reply with quote

Well done.
PCM's 4th suggestion. Smile

Mark the thread as 'solved' (edit the title).

It's more common than you might think. The PIC generally wakes at quite low supply voltages, and a lot of chips need significant time to actually get started properly.
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