View previous topic :: View next topic |
Author |
Message |
njepsen
Joined: 13 Aug 2007 Posts: 469
|
Posted: Thu Jul 12, 2012 9:10 am Post subject: Intermittant RS232 and watchdog |
|
|
For several, no make that many many months, I have been working ( with the help of Adrien and several others) on a rather long code block for the Atmega 1284P, which involves 2 hardware and 2 sw RS232 ports, handling about 5000 bytes of serial data every now & again. Today I loaded the sw version that has been working faultlessly for about 3 weeks, 24/7, into a new board and got a whole load of intermitant flaky errors. Of course I immediately blamed my code, and spent 2 hours debugging.
** Hyperterminal on the debug port was outputting odd wrong chars from time to time
** 2 remote serial devices on the h/ware ports were sluggish and unreliable
** The uP kept on watchdogging in silly places, which had never happened before
** a couple of defaults in EEPROM got corrupted
To cut a long story short - it turned out that a batch of 50x 18.432mHz crystals purchased recently had a half dozen 18.400 mHz crystal mixed in with them. !!!!
lesson learned. _________________ Neil |
|
Back to top |
|
|
nil_orally
Joined: 07 Jun 2010 Posts: 18
|
Posted: Thu Jul 12, 2012 12:00 pm Post subject: |
|
|
Been there, but with 12.000 instead of 12.288MHz.
Then there were the diodes on a bandolier that were marked with the wrong end as the cathode. Not all of them..... |
|
Back to top |
|
|
Paulvk
Joined: 28 Jul 2006 Posts: 1257 Location: SYDNEY
|
Posted: Thu Jul 12, 2012 12:20 pm Post subject: |
|
|
Whats a couple of hundred MHz between friends
Regards Paul |
|
Back to top |
|
|
albertsm
Joined: 09 Apr 2004 Posts: 5913 Location: Holland
|
Posted: Thu Jul 12, 2012 2:14 pm Post subject: |
|
|
were these parts in tape? or was it TH?
diodes with wrong marking, go figure.
But good you found it! _________________ Mark |
|
Back to top |
|
|
njepsen
Joined: 13 Aug 2007 Posts: 469
|
Posted: Thu Jul 12, 2012 10:12 pm Post subject: |
|
|
The crystals were loose in a plastic bag, from a supply house in Asia. _________________ Neil |
|
Back to top |
|
|
AdrianJ
Joined: 16 Jan 2006 Posts: 2483 Location: Queensland
|
Posted: Fri Jul 13, 2012 12:05 am Post subject: |
|
|
The frequencies you quoted are less than 0.2% different. I very much doubt that would cause baud rate errors. You might have crystal problems worse than the markings indicate.
I too have been bitten by bad parts. Like several rails of LM324 quad opamps, with the internal chip backwards in the leadframe at random. Same symptoms as inserting the chip wrong way around in the board. Devilish hard to trace when you have 8 or so on the same board. _________________ Adrian Jansen
Computer language is a framework for creativity |
|
Back to top |
|
|
|