Shop OBEX P1 Docs P2 Docs Learn Events
DMX dimmer with an SX chip? — Parallax Forums

DMX dimmer with an SX chip?

motocycledogmotocycledog Posts: 1
edited 2006-08-27 06:31 in General Discussion
Has anyone ever made a DMX light dimmer with a Stamp? I've seen some work on Stamp DMX controllers but nothing on dimmers (the thing that receives the control information and actually turns the lights on and off). According to the research I've done the DMX baud rate is too high for a BS2 but should be possible with the SX.

Thanks!

Comments

  • jmevansjmevans Posts: 22
    edited 2006-08-24 16:54
    I also would like to see some code for using the SX with DMX

    Thanks
  • metron9metron9 Posts: 1,100
    edited 2006-08-24 17:41
    Looks like at 50 mhz 384,000 baud is doable I read this link
    http://www.euro-pa.be/dmx.html

    Looks like you need http://focus.ti.com/docs/prod/folders/print/sn75176b.html
    to take of the high speed data transmission.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Think outside the BOX!
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-08-24 18:17
    This thread is being moved from the·BASIC Stamp·Forum to the·SX Forum.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • PJMontyPJMonty Posts: 983
    edited 2006-08-24 23:55
    Metron9,

    The speed of DMX is 250 kHz, not 384 kHz. With the SX running at 50 MHz, you can execute 200 instructions between each bit coming in. As you say, it's definitely do-able.


    Thanks,
    PeterM
  • John CoutureJohn Couture Posts: 370
    edited 2006-08-25 02:54
    Some discussion about DMX stuff in the Propeller forum.

    http://forums.parallax.com/forums/default.aspx?f=25&m=132052

    I had asked the question if one could use an SN75176 chip, an MCU and a Quadrac as a DMX slave unit. It will be interesting to see if it could work.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    John J. Couture

    San Diego Miramar College
  • metron9metron9 Posts: 1,100
    edited 2006-08-25 13:40
    I have a question about RS485 voltage levels though, Can the same benifits of in phase noise be obtained using +5 and Ground levels on a chip to chip communication as an alternitive to just serial when longer lines connecting devices becomes a problem. I am still not sure in my mind if say +10 and Ground would be escentially the same operation as +5 and -5. I have a hunch though that with a -5V signal it can be regulated the same as the +5 side so you know you have a 10V potential difference. After clicking on the bottom link and reading the authors tutorial on DMX systems that he builds I realize this is the first time I have read anything about RS485. There should be 32 hours in a day so after work I have more time to learn about all this stuff and get some sleep.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Think outside the BOX!
  • John CoutureJohn Couture Posts: 370
    edited 2006-08-25 16:10
    RS485 is very kool stuff.

    To answer your question, I'm pretty sure that the way the RS485 protocol works is that it just checks the voltage difference between the two wires and each end has its own power supply and its own ground reference. This is why RS485 works for such great distances (at least that is the way I understand it ... not that it is right smile.gif

    The RS485 chips (SN75176) are cheap (i.e. Jameco $0.23 USD each) and you need one on each end. You can run a signal over twisted pair for a couple thousand feet in the kHz range. I have a few that I play around with and they are well explained in Jan Axelson's book "Serial Port Complete" (ISBN 0965081923 )

    Quadracs (about $1.20 USD) are a little more difficult to find information on. You see references to Triacs and SCR's but Quadracs aren't used in a lot of hobby projects that I've been able to find. They are a three pin TO-220 devices that can be, in theory, used as a variable motor controller. I've yet to get them to work with my surplus TLP630 (Darlington Optocoupler) to get a true ON/OFF for 120V fan motor with optical isolation. My ultimate goal is to try and build an inexpensive speed control for a ceiling fan that doesn't make noise (cheap ceiling fans, the kind I buy, are generally noisy at lower speeds .... tough to sleep under).

    Anyway, here are some reference materials if you are interested.

    Datasheets
    SN75176 (RS485 Transciever)
    http://focus.ti.com/lit/ds/symlink/sn75176b.pdf

    TLP 630 (DIP8 Darlington Optocoupler)
    http://rocky.digikey.com/WebLib/Toshiba/Web Data/TLP630.pdf

    Quadrac (A souped up Triac)
    http://www.jameco.com/wcsstore/Jameco/Products/ProdDS/160240.pdf

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    John J. Couture

    San Diego Miramar College
  • dkemppaidkemppai Posts: 315
    edited 2006-08-25 16:13
    metron9 said...
    I have a question about RS485 voltage levels though, Can the same benifits of in phase noise be obtained using +5 and Ground levels on a chip to chip communication as an alternitive to just serial when longer lines connecting devices becomes a problem. I am still not sure in my mind if say +10 and Ground would be escentially the same operation as +5 and -5. I have a hunch though that with a -5V signal it can be regulated the same as the +5 side so you know you have a 10V potential difference. After clicking on the bottom link and reading the authors tutorial on DMX systems that he builds I realize this is the first time I have read anything about RS485. There should be 32 hours in a day so after work I have more time to learn about all this stuff and get some sleep.

    RS485 is a differential signaling. It means that there is a + and - signal.
    The minus line does exactly the oppostie of what the positive line does.
    When the +signal is 5V volts, the -signal is 0V. When the +signal is 0Volts, the
    -signal·is 5 volts.·The reciever looks·at the DIFFERENCE between the two
    lines. The reason this is done, is that if you induce noise·on the wire between
    your RS485 devices, both the +signal and -signal·get the same noisevoltage,
    and the difference remains the same (This is key to noise immunity)
    Since the reciever·looks at the difference only, the·noise is ignored.
    This is what gives RS485 immunity to noise that RS232 doesn't have.

    Note that you are talking about RS485. There is also an RS422 specification.
    The·RS485 and RS422 use the same signaling (Voltage levels). However, One
    is specified as unidirectional, and the other is bidirectional. RS422 has a TX pair
    and RX pair of wires (5 wires total). On·RS485 line (3 wires total), data flows
    in both directions on the same wire. In reality it is a little more complex
    than that...· ...but this should give you the·rough idea.

    Check out: http://www.national.com/an/AN/AN-216.pdf
    National semiconductor also has some more info on the subject, but you will
    have to search for it...

    Hope this helps.
    -Dan


    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔

    "A saint-like quantity of patience is a help, if this is unavailable, a salty vocabulary works nearly as well." - A. S. Weaver
  • PJMontyPJMonty Posts: 983
    edited 2006-08-27 06:31
    RS-485 and RS-422 need to share a common ground - this is how they get rid of common mode noise and provide that cool noise immunity we all love. If they don't share a common ground, then it might work... it might not. It's a just a big crapshoot at that point.

    Thanks,
    PeterM
Sign In or Register to comment.