I'm no electrical engineer, but I recall something about "debouncing" switches.
A poor switch may make many micro-contacts before actually settling into the
contact state. There are many circuit designs for filtering the contact.

Paul Alfille

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Gene
Dio
Sent: Thursday, January 18, 2007 9:25 AM
To: [email protected]
Subject: [Owfs-developers] Interpreting counter values from ds2423


I'm on my first go around with OWFS, and so far I'm very impressed.  What a 
sweet package.

I have a ds2423 dual counter board (hobby-boards model) sitting on my 1wire 
bus.  OWFS is reading the counters like a champ, but I'm having trouble 
interpreting what I get.

I am in pure testing mode with this, so I am triggering the counters with a 
pair of simple momentary contact switches (interpet that to mean a pair of $2 
doorbell switches from the local hardware store).  The final use for this will 
be much more complex, but I am using this approach to get my system setup and 
test my code.

The problem is that the raw number I get out of OWFS increments violently with 
every single click.  One click of the switch causes the value I read from OWFS 
to increment by 12, 27, 30 or some other variable number but not by 1.  So, 
I'm guessing there is a checksum digit involved or some routine I must run on 
the raw data in order to get a nice clean unsigned integer value?

Thanks for any advice.

Set-UP:   ds9490r USB 1wire adapter, ds2423 counter (hobby-boards counter 
module) is the only device on the bus right now, Ubuntu Linux kernel 2.6, No 
external voltage applied to the counter inputs  . .  just a raw switch closure 
to trigger a counter event.


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Owfs-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/owfs-developers




THE INFORMATION TRANSMITTED IN THIS ELECTRONIC COMMUNICATION IS INTENDED ONLY 
FOR THE PERSON OR ENTITY TO WHOM IT IS ADDRESSED AND MAY CONTAIN CONFIDENTIAL 
AND/OR PRIVILEGED MATERIAL.  ANY REVIEW, RETRANSMISSION, DISSEMINATION OR OTHER 
USE OF OR TAKING OF ANY ACTION IN RELIANCE UPON, THIS INFORMATION BY PERSONS OR 
ENTITIES OTHER THAN THE INTENDED RECIPIENT IS PROHIBITED.  IF YOU RECEIVED THIS 
INFORMATION IN ERROR, PLEASE CONTACT THE SENDER AND THE PRIVACY OFFICER, AND 
PROPERLY DISPOSE OF THIS INFORMATION.



-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Owfs-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/owfs-developers

Reply via email to