WXforum.net
May 21, 2013, 02:39:29 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
Members: 6616  •  Posts: 178486  •  Topics: 18113
Please welcome TheMOX, our newest member.
Welcome to the the new hosting for WXforum.net.
 
   Home   Help Search Login Register  
Pages: [1]   Go Down
  Print  
Author Topic: Erratic One-Wire Counter issue  (Read 1542 times)
0 Members and 1 Guest are viewing this topic.
miraculon
Senior Contributor
****
Offline Offline

Posts: 290



WWW
« on: August 14, 2011, 08:42:23 AM »

I was experiencing bizarre counter behavior on my Hobby-Boards lightning detector. When I started posting my station data to PWS Weather, I could see that my rain gauge was also showing huge counts in the precipitation chart.

The tip-off was the frequent lightning detector counts of 4294967295 which corresponds to xFFFFFFFF. This is the blank page in the DS2423 counter used in the rain gauge and lightning detector. I also found from various application information on One-Wire that negative voltage transients on the One-Wire bus can cause disruption to the chips via the substrate.

The DS2423 data sheet says:
When applying the Read Memory + Counter command to a page that does
not have a counter associated, the master will read FFFFFFFFH instead of a valid count.


There were several recommendations in the application notes, including using a hub (already was doing that) and various ramp rates. The one that caught my eye was the recommendation to add a Schottky diode to the most distant node of the One-Wire bus. This clamps the negative transient to -0.3V.

I placed the diode at my hub just to test it because if it was the wrong polarity it would short out the bus. Immediately, I started seeing massive continuous errors on the lightning detector. Since the diode was at the opposite end of where it is supposed to be, I wasn't surprised that this could make it worse.

I installed the Schottky diode a few days ago and it seems to have cured the problem. I went through a major lightning storm last night without any false counts. Time will tell, but so far so good.

I read about this in "Springbok Diagnostics 1-Wire Design Guide v1.0" (pg. 36) and the "OneWire Design App Note" from Dallas Semiconductor (Maxim).

The Springbok paper is at www.1wire.org/Files/Articles/1-Wire-Design%20Guide%20v1.0.pdf

It is critical that the diode be placed at the far end of the One-Wire microLAN and that the cathode (banded end of a leaded device) is on the "data" line not the ground. Otherwise you will have a shorted bus. (it doesn't hurt anything permanently, it just won't work).

Springbok recommends a 1N5817 or BAT54S. A standard rectifier diode will be slower and allow 0.6V reverse voltage, so they are not suitable.

Greg

---------------------------
Update: I did get a count indicating a read error late this morning. It still seems much better behaved now.


Hmmm... I see in the schematic for the lightning detector that there is already a BAT54S Schottky diode. Not sure if this means that it was open circuit, or something else is going on now.
----------------------------
OK, the xFFFFFFFF count happened only twice since I put the Schottky diode at the end of the net (about a week). I now think that the first one was a power transient. The other one was at start-up OWW after a power-off (power failure). Otherwise, both the xFFFFFFFF and the crazy count issue seems to be gone.

The explanation I believe lies in the datasheet for the BAT54S and the 1N5819 that I used.

The 1N5819 is 400mV @100mA.
The BAT54S is 800mV @100mA.

Hence, the BAT54S, while being a Schottky diode, isn't as effective as a clamp as the 1N5819. The BAT54S could allow enough negative voltage below -0.3V that the substrate issue could occur, whereas the 1N5819 has a better chance of clamping it. It all depends on the current that the diode is absorbing during the negative transient.

« Last Edit: August 20, 2011, 09:29:14 AM by miraculon » Logged

Pages: [1]   Go Up
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.094 seconds with 19 queries.
anything