PDA

View Full Version : One-Wire Communications



Dunsmuir
- 23rd March 2007, 19:31
I am using a PIC 16F870 controller and two Dallas/Maxim DS18S20 High Precision 1-wire digital thermometers but am having problems getting data from the DS18S20 devices. If I only use one device I there is no problem, but the minute I add the other one problems start. I tried to modify the PIC Basic program that was used for the X1 Lab by using the DS18S20 data sheets, but have been unsuccessful. I know there must be a buss contention problem and have tried all of the options I can think about. If I use the original one-wire program and put the second device on a separate port, it works well but that is certainly not a one-wire system.
The other concern I have has to do with addressing the DS18S20 devices. According to the data sheet each device has separate addressing capabilities, but from what I can see, you can't find out what they are.
Any ideas of where I have gone wrong?

Martin

skimask
- 23rd March 2007, 22:33
I am using a PIC 16F870 controller and two Dallas/Maxim DS18S20 High Precision 1-wire digital thermometers but am having problems getting data from the DS18S20 devices. If I only use one device I there is no problem, but the minute I add the other one problems start. I tried to modify the PIC Basic program that was used for the X1 Lab by using the DS18S20 data sheets, but have been unsuccessful. I know there must be a buss contention problem and have tried all of the options I can think about. If I use the original one-wire program and put the second device on a separate port, it works well but that is certainly not a one-wire system.
The other concern I have has to do with addressing the DS18S20 devices. According to the data sheet each device has separate addressing capabilities, but from what I can see, you can't find out what they are.
Any ideas of where I have gone wrong?

Martin

You're answer is right there on page 9 and page 17 of the DS18S20 datasheet.