1-wire resistor choice and wire size Topic is solved

Post Reply
n1c0l45
Posts: 32
Joined: Monday 25 April 2016 9:45
Target OS: Raspberry Pi
Domoticz version: V3.4834
Location: France
Contact:

1-wire resistor choice and wire size

Post by n1c0l45 » Monday 25 April 2016 19:59

Hi

I plan to replace most of my temp RF sensors with wired ones. I would like to do this bus
Image

The orange part is optional... i would like to do it (freezer & fridge sensors) but they may get things too complcated?

So the bus has a lenght of 14,1m and a weight of 22.9m (optional version) or 18.9m (short version). I also plan to use 3 wires (not a parasite setup)
My three questions:
1- What wire size should be best for this? (I can get nearly all type of cable for free at work, so if there is something better than network cable...) :lol: :lol:
2- Is there formula or else to calculate the good size of the resistors (& capactiors?) and where it should be best to put them?
3- Is there a test that i can do with an oscilloscope to test my setup to be sure to get things working nicely?

thank you guys for your help and sorry for my english

Nicolas

n1c0l45
Posts: 32
Joined: Monday 25 April 2016 9:45
Target OS: Raspberry Pi
Domoticz version: V3.4834
Location: France
Contact:

Re: 1-wire resistor choice and wire size

Post by n1c0l45 » Tuesday 26 April 2016 14:38

No ideas?

User avatar
Marci
Posts: 463
Joined: Friday 22 January 2016 19:00
Target OS: Raspberry Pi
Domoticz version: 2.3530
Location: Wakefield, West Yorkshire UK
Contact:

Re: 1-wire resistor choice and wire size

Post by Marci » Tuesday 26 April 2016 19:20

Dunno about electronically correct but I've done the above on cat5 with 4.7k resistors... all works fine.
Extended Domoticz homebridge-plugin for latest Homebridge - adds temp/humidity/pressure sensors, power consumption sensors, DarkSkies virtual weather station support, YouLess Meter support, general % usage support & switch/lamp status checking!

n1c0l45
Posts: 32
Joined: Monday 25 April 2016 9:45
Target OS: Raspberry Pi
Domoticz version: V3.4834
Location: France
Contact:

Re: 1-wire resistor choice and wire size

Post by n1c0l45 » Tuesday 26 April 2016 20:24

Thanks for your answer!
How many sensors have you got? And what length?
Thanks

cul8r
Posts: 14
Joined: Wednesday 06 January 2016 0:03
Target OS: Raspberry Pi
Domoticz version: Beta
Contact:

Re: 1-wire resistor choice and wire size

Post by cul8r » Tuesday 26 April 2016 20:56

I have 9 sensors, length appr.15 m and weigth appr. 35 m with 4.7 kOhm pull-up and in parasitic mode with no problems. (Using Raspberry GPIO and kernel support). I have a second installation close to a compressor and in that case it is only 4 m length and 2 sensor, was force to go to 1.2 kOhm pull-up.

Maxim recommends max length/weigth 200 m with pull-up of 1 kOhm, also if you have many stubs (branches) they could cause problem due to impedance mismatch and solution is to have 100-150 Ohm in serie where the data line where the branch begins.

For cables in the range 0-30 m it is not critical, but using a CAT5 cable is to be in the very safe side. I am using a mixture of of telephone cables (0.15 mm2) and even using 2 spare pair of the alarm installation! (20 pairs, 0.2 mm2 cable).

There is a very good application note at Maxim:
https://www.maximintegrated.com/en/app- ... mvp/id/148

/C

n1c0l45
Posts: 32
Joined: Monday 25 April 2016 9:45
Target OS: Raspberry Pi
Domoticz version: V3.4834
Location: France
Contact:

Re: 1-wire resistor choice and wire size

Post by n1c0l45 » Tuesday 26 April 2016 21:25

Thanks for the answer!
I have already red the maxim note but there is no informations on resistors values

n1c0l45
Posts: 32
Joined: Monday 25 April 2016 9:45
Target OS: Raspberry Pi
Domoticz version: V3.4834
Location: France
Contact:

Re: 1-wire resistor choice and wire size

Post by n1c0l45 » Tuesday 26 April 2016 21:37

cul8r wrote:I have 9 sensors, length appr.15 m and weigth appr. 35 m with 4.7 kOhm pull-up and in parasitic mode with no problems. (Using Raspberry GPIO and kernel support). I have a second installation close to a compressor and in that case it is only 4 m length and 2 sensor, was force to go to 1.2 kOhm pull-up.

Maxim recommends max length/weigth 200 m with pull-up of 1 kOhm, also if you have many stubs (branches) they could cause problem due to impedance mismatch and solution is to have 100-150 Ohm in serie where the data line where the branch begins.

For cables in the range 0-30 m it is not critical, but using a CAT5 cable is to be in the very safe side. I am using a mixture of of telephone cables (0.15 mm2) and even using 2 spare pair of the alarm installation! (20 pairs, 0.2 mm2 cable).

There is a very good application note at Maxim:
https://www.maximintegrated.com/en/app- ... mvp/id/148

/C
Do you have just one 4.7k resistor?
So if I understand well, I use a 4.7k between 3.3v and data line near the gpio, and a 100ohm resistors on the data line of each branch?

cul8r
Posts: 14
Joined: Wednesday 06 January 2016 0:03
Target OS: Raspberry Pi
Domoticz version: Beta
Contact:

Re: 1-wire resistor choice and wire size

Post by cul8r » Tuesday 26 April 2016 22:06

Yes, only one 4.7 kOhm from 3.3 to GPIO/dataline at the Rasberry connector.

The 100 Ohm is only if you have problems with impedance mismatch, and in your case should not be a problem with that. With your topography but with much longer cables and having problem, I would try 100 Ohm at the start of the "3 m" branch.

The application note states that a FET driver and 1 kOhm pull-up is good for 200 m length/weigth, the 4.7 kOhm value is a standard value recommended in Raspberry 1-wire applications.

cul8r
Posts: 14
Joined: Wednesday 06 January 2016 0:03
Target OS: Raspberry Pi
Domoticz version: Beta
Contact:

Re: 1-wire resistor choice and wire size

Post by cul8r » Tuesday 26 April 2016 22:17

By the way, this is the board I made for my application!

/C
Attachments
GPIO_2-O-4-IN_1-WIRE E.pdf
(47.85 KiB) Downloaded 125 times

n1c0l45
Posts: 32
Joined: Monday 25 April 2016 9:45
Target OS: Raspberry Pi
Domoticz version: V3.4834
Location: France
Contact:

Re: 1-wire resistor choice and wire size

Post by n1c0l45 » Tuesday 26 April 2016 23:24

Thank you for all of that!

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests