0
\$\begingroup\$

I've build a 1-wire network using a star topology (networking done trough my home's ethernet cables).

At the begining I didn't own a 4.7k resistor but some 1.2k resistor so I lined them to achieve 1.2k*3= 3.6k "virtual resistor".

This first version of my bus was working fine.

Today I tried to replace those 3 resistor by a single 4.7k and the bus stopped working.

==> Why ? :)


[EDIT] second question added below

Following maxim's guide I think I understand that, with a star topology, one should rather use a switched network or a Distributed Impedance Matching.

I'm more keen to try this second option but how can I compute the optimal resistor to add to each branch given their length ?


Star topology metrics are : 4 branches diverging at the master

  • 1st branch = 18.5m
  • 2nd branch = 26.5m
  • 3rd branch = 25m
  • 4th branch = "1cm" (direct connection to my 3.6k resistor)

Thus the radius of the longest branch is ~27m and the radius of the shortest is 0cm and the total weigth is 71m

\$\endgroup\$
7
  • \$\begingroup\$ how long are the cables? Did you try to use a smaller resistor back again? \$\endgroup\$
    – Wesley Lee
    Nov 24, 2015 at 8:35
  • \$\begingroup\$ Are you able to look at the signal levels with an oscilloscope? \$\endgroup\$
    – Icy
    Nov 24, 2015 at 9:20
  • \$\begingroup\$ @WesleyLee I don't know yet. I'll borrow a device on thursday to get the real value. Yet I'd bet on 15m + 20m + 25m + 0cm ;) \$\endgroup\$
    – Cerber
    Nov 24, 2015 at 9:47
  • \$\begingroup\$ @Icy no, I don't own one, nor my friends. Yet I hope that my friend's device will show me resistive values of the cables \$\endgroup\$
    – Cerber
    Nov 24, 2015 at 9:48
  • \$\begingroup\$ @Icy I've updated the question with the length metrics but, unfortunately, my friends device didin't show the resistive values (but I think it uses it to measure the length of the cable. Settings were on 49 PF.m) \$\endgroup\$
    – Cerber
    Dec 4, 2015 at 10:33

1 Answer 1

1
\$\begingroup\$

From my memory of the Dallas guide, which should be similar, star layout should be avoided as the various reflections can cause interference. Without an oscilloscope it will be difficult to debug.

Assuming that you don't want to rewire, your most robust solution would be to put each cable on a separate pin of your micro and poll each individually.

You don't specify whether you are transmitting power on the data line or separately. The separate power line makes the resistor value less critical.

By the way, your 3.6k resistor isn't 'virtual'. It's real!

\$\endgroup\$
4
  • \$\begingroup\$ Thanks for your kind answer. I forgot to say that I can't rewire because I'm using in-wall ethernet cables that all ends in the same place (thus the star topology). I did separate power from data on different cables. Concerning my "virtual" resistor, it was just to highlight the fact that it's not A 3.6k Gold (+-5) but 3*1.2k (Gold +-5%) thus a 3.6k +-15% ;). Could you Point me out a tuto on how to poll each individually ? \$\endgroup\$
    – Cerber
    Dec 4, 2015 at 11:55
  • \$\begingroup\$ What I meant there was that you treat each cable as a separate network and connect each to a separate pin on your micro. Your code would then poll each cable. Whether this is feasible in your application depends on 1) whether all the cables terminate at the 1-wire master or do they star at some point elsewhere and 2) if you have the option to, effectively, connect several networks to individual IO pins on your micro. We'd need more info on your setup. By the way, you may need to be careful that a POE (power over Ethernet) router isn't connected into your network! \$\endgroup\$
    – Transistor
    Dec 4, 2015 at 12:05
  • \$\begingroup\$ Thoses cables are pulled out of the network, so POE won't be a concern. I'm using a PI as 1Wire master and all the nodes are directly attached to it. I'm not at ease with the PI's GPIO since I figured out there was only a single UART slot allowed within the 40GPIO. Is it the same with 1W or can I use several pins? \$\endgroup\$
    – Cerber
    Dec 4, 2015 at 13:39
  • \$\begingroup\$ It's about 18 months since I set up my OpenHAB on a Pi to control my home heating. I found this 1-wire-Pi and decided it was worth the investment if it saved me some trouble as it buffers the data electrically and should help with timing accuracy. It might help with your troubles but I suspect you can only use one per Pi as the header connections are fixed. I used dedicated CAT5 cable to RJ11 phone sockets and soldered my 1-wire sensors onto RJ11 cords. Sockets and cords available from a discount store at very low cost. \$\endgroup\$
    – Transistor
    Dec 4, 2015 at 17:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.