Pages: [1]   Go Down
Author Topic: Sending a signal through a cable  (Read 318 times)
0 Members and 1 Guest are viewing this topic.
South Carolina
Offline Offline
Full Member
***
Karma: 1
Posts: 108
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

If I wanted to send a signal straight from an Arduino through a cable roughly, 5-6ft long to some LED drivers, should I do anything to the signal on the Arduino end to ensure the signal gets that far or should it be fine? I'm designing a PCB and curious if I should put something there before ordering them and realizing they're not going to work.
Logged

Offline Offline
Edison Member
*
Karma: 45
Posts: 1585
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

That is less than 2 meters, that is a short distance. The cable you are going to use can make a big difference (a difference of maybe 10 times).
What kind of signal, just on/off, or pwm, or I2C ?
Logged

Doctor, I see Arduino boards everywhere, what can I do ? - Well, I suggest you connect them with I2C.

South Carolina
Offline Offline
Full Member
***
Karma: 1
Posts: 108
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I'm hoping to send some PWN signals, a mix of hardware and software PWN. 8 signals total.
Logged

Turku
Offline Offline
Full Member
***
Karma: 1
Posts: 229
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes, 5-6feet is not so long. A lot depends on the transfer speed you use. If you just wait everything to settle up or get stable, you can use very long cables. Don't forget the earth wire/wires. With high speed and long cables you get transmission lines.
Logged

Santiago de Chile
Offline Offline
Sr. Member
****
Karma: 13
Posts: 485
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The less resistance the wire has, the merrier. To decrease resistance use copper wire with bigger area. I'd do some test before running the final design, never used PWM on wire longer than 30 cm.
Logged

Work for what you love

South Carolina
Offline Offline
Full Member
***
Karma: 1
Posts: 108
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I guess it would probably not be a good idea to try and shoot a PWM signal 5ft. I'll have to find another way to get the signal from point A to point B.
Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 549
Posts: 27425
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

500 Hz PWM? That is slow. That would be fine. Are you send shiftOut( ) or SPI signals too?
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Ayer, Massachusetts, USA
Offline Offline
Edison Member
*
Karma: 54
Posts: 1857
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

One way to solve the problem for longer distances is put a microprocessor on the other end, and hook both up with RS485.  Then on the first processor, it just sends down requests (turn on PWM to this frequency, turn it off, turn on led, etc.).

I would use a microprocessor with serial support on each end, and not something like ATtiny85's.  That way, the RS485 handles error correction, etc. and you are not sending PWM signals down the line continuously.  You don't necessarily want an Arduino development system on each end.
« Last Edit: July 19, 2014, 01:02:06 am by MichaelMeissner » Logged

South Carolina
Offline Offline
Full Member
***
Karma: 1
Posts: 108
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

500 Hz PWM? That is slow. That would be fine. Are you send shiftOut( ) or SPI signals too?

I have to be honest in saying, I'm not fully sure. I haven't done a whole lot on the coding side, I just know that at some point, I need a PWM signal for 8 LED drivers. I figured a wired connection would be the easiest to set up, and eventually move on to more innovative methods, but in the past, at least with PWM signals, I've gotten spotty results (Some work, some don't, some flicker, etc), but I think it was due to poor soldering and poor board design.

One way to solve the problem for longer distances is put a microprocessor on the other end, and hook both up with RS485.  Then on the first processor, it just sends down requests (turn on PWM to this frequency, turn it off, turn on led, etc.).

I would use a microprocessor with serial support on each end, and not something like ATtiny85's.  That way, the RS485 handles error correction, etc. and you are not sending PWM signals down the line continuously.  You don't necessarily want an Arduino development system on each end.

Eventually, that's actually what I want to do. Eventually I want several "sub"controllers in charge of remedial tasks while the main controller fine tunes and acts as the user interface. I was trying to start simple first, at least get something that works before moving on to more complicated additions, though the more I think about it, going ahead and adding the second controller would probably make it easier... Eventually I want to make it all bluetooth, but that's another hurtle for another time.
Logged

Ayer, Massachusetts, USA
Offline Offline
Edison Member
*
Karma: 54
Posts: 1857
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Another thought if you were willing to live with i2c distances (something like 2m, but I don't actually recall), Adafruit sells a 16 channel i2c PWM controller that would off-load doing the PWM processing: https://www.adafruit.com/products/815
Logged

Shelby Township, Disco, Michigan
Offline Offline
God Member
*****
Karma: 26
Posts: 778
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Use RG-59 video/cctv cable. You can get well over 10'
Logged

South Carolina
Offline Offline
Full Member
***
Karma: 1
Posts: 108
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Another thought if you were willing to live with i2c distances (something like 2m, but I don't actually recall), Adafruit sells a 16 channel i2c PWM controller that would off-load doing the PWM processing: https://www.adafruit.com/products/815

That actually looks perfect. That chip can sit right next to the drivers if need be, and I can send the 2 data pins required to control it through a cable, maybe just a simple USB cable to include 5V and GND. the longest distance I think I need is 6ft, and even then, that's plenty long enough to get from the bottom to the top of most standard aquariums if not all. that will also allow the control of up to 16 drivers instead of the original 8 in case I ever want to extremely overkill my lighting control.

Thanks!
Logged

Ayer, Massachusetts, USA
Offline Offline
Edison Member
*
Karma: 54
Posts: 1857
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I would think using cat 5/6 ethernet cables would be better than using usb cables, since these cables are made for going distances and have 4 pair of stranded wires inside.  You can either cut up an existing 6foot/2m cable to solder individual wires or you can get breakout boards for cat 5 or 6, such as [ur]https://www.sparkfun.com/products/716[/url] + https://www.sparkfun.com/products/643.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 43
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

If you are driving led's you do not have to worry about line length.  You can figure about 20 mA per led and a 13 milliohms per meter for 16 gauge copper wire.  So if you have 100 led's at the end of a 2 meter wire you are only dropping 50 mV.  You certainly do not need coax.  Speed and bandwidth are not an issue since the eye cannot detect anything faster than around 10 Hz anyway.
Logged

Pages: [1]   Go Up
Jump to: