I put this under the Prop-SX header because from what I understand, if i want to do DMX control of anything, it would require an SX.
I am new to DMX, but a customer of mine wants to do a large que area show, which includes a DMX pan/tilt spot light that needs to be controlled. Everything else in the show is prop-1's and prop-2's that I would like to trigger from the prop-sx as well.
So, the prop-sx could only be a slave to a computer running VSA or Vixen?
Am I even on the right track or am I completely wrong?
Brain,
I have this question for you. Is this consumer looking for a stand alond system that will be trigger by PropS/X?
DMX is a RS485 based system that is daisy chain to each light or device. Each device has it own address and is maximum of 255 addresses.
Quote from: bsnut on December 16, 2010, 03:09:20 AM
Brain,
I have this question for you. Is this consumer looking for a stand alond system that will be trigger by PropS/X?
DMX is a RS485 based system that is daisy chain to each light or device. Each device has it own address and is maximum of 255 addresses.
I am not that uninformed. I do know what DMX is.
My hope is that I could use a Prop-SX as a stand alone unit to send DMX signals to 1 DMX device. Just the single DMX controlled pan/tilt spotlight. In addition to the light, I would have approximately 5 prop-1s in the same room, each responsible for controlling an animatronic or air cannon. I would want to trigger each of the prop-1's in a particular sequence. From what I gather from the other DMX posts, I could do this, but the Prop-SX would just be a slave to a computer running VSA or Vixen.
DMX is a simple serial show control protocol that runs at a very fast baud rate (250K, hence the requirement of the SX). The transmission hardware is RS-485. It is possible to implement a DMX transmitter on the SX that will handle up to 16 channels -- I've done it, though I'm having a hard time finding that code at the moment.
The HC-8+ will be a good platform for this application as it is very simply to implement a full-featured DMX device (512 channels) that runs in its own processor, this means you only have to put your valus in a buffer, they'll get transmitted without any further action on your part.. Even using DMX, you get eight inputs and eight high current outputs on the HC-8+.
I'm heading out of the office in a few minutes; when I return this afternoon I'll find that DMX transmitter project for the Prop-SX.
Brain,
You may want to look at this post that Jon did on DMX-512 Relay Control.
http://www.efx-tek.com/php/smf/index.php?topic=465.msg2328#msg2328
Here is another post that Jon did on RS485/DMX Board for the January2008 issue of Nuts & Volts
http://www.efx-tek.com/php/smf/index.php?topic=468.msg2344#msg2344
This will give you some idea how DMX is done on the Prop-SX.
Quote from: bsnut on December 16, 2010, 09:14:30 AM
Brain,
You may want to look at this post that Jon did on DMX-512 Relay Control.
http://www.efx-tek.com/php/smf/index.php?topic=465.msg2328#msg2328
Here is another post that Jon did on RS485/DMX Board for the January2008 issue of Nuts & Volts
http://www.efx-tek.com/php/smf/index.php?topic=468.msg2344#msg2344
This will give you some idea how DMX is done on the Prop-SX.
Thanks, but I have read both of those already.
Below is a framework for sending a 16-byte DMX packet using the RS-485 add-on module. It works, but you have to call the DMX_OUT subroutine periodically. Normally, DMX packets go out every 23 milliseconds, that is not the case here where everything is done manually. The bandwidth requirements for DMX are tough and I'm not sure I can cleanly code this (so that it's easy for others to use) so that the updates are automatic.
' =========================================================================
'
' File...... DMX-16_EZ.SXB
' Purpose...
' Author.... Jon Williams, EFX-TEK
' Copyright (c) 2009 EFX-TEK
' Some Rights Reserved
' -- see http://creativecommons.org/licenses/by/3.0/
' E-mail.... jwilliams@efx-tek.com
' Started...
' Updated... 08 MAR 2009
'
' =========================================================================
' -------------------------------------------------------------------------
' Program Description
' -------------------------------------------------------------------------
' -------------------------------------------------------------------------
' Conditional Compilation Symbols
' -------------------------------------------------------------------------
' -------------------------------------------------------------------------
' Device Settings
' -------------------------------------------------------------------------
ID "DMX-16ez"
DEVICE SX28, OSCHS2, BOR42
FREQ 50_000_000
' -------------------------------------------------------------------------
' I/O Pins
' -------------------------------------------------------------------------
RS485 PIN RB ' for DMX/RS-485 board
Aux PIN RB.7 INPUT PULLUP ' auxilliary input
RX PIN RB.6 INPUT PULLUP ' serial in
TX PIN RB.5 OUTPUT ' serial out
TxEnable PIN RB.4 OUTPUT ' tx control (0 = off)
Addr8 PIN RB.3 INPUT ' bit 8 of address
Clock PIN RB.2 OUTPUT ' to 74x165.2 (CLK)
Din PIN RB.1 INPUT ' to 74x165.9 (QH)
ShLoad PIN RB.0 OUTPUT ' to 74x165.1 (S/LD)
' -------------------------------------------------------------------------
' Constants
' -------------------------------------------------------------------------
Baud CON "T250000" ' for DMX-512
' -------------------------------------------------------------------------
' Variables
' -------------------------------------------------------------------------
tmpB1 VAR Byte
tmpB2 VAR Byte
tmpW1 VAR Word
dmx VAR Byte (16)
' =========================================================================
' Subroutine / Function Declarations
' =========================================================================
DMX_OUT SUB 0 ' transmit DMX-16 packet
TX_BYTE SUB 1 ' tx one byte
DELAY_MS SUB 2, 2, Word ' shell for PAUSE
DELAY_US SUB 2, 2, Word ' shell for PAUSEUS
' =========================================================================
PROGRAM Start
' =========================================================================
Start:
PLP_A = %0000
PLP_C = %0000_0000
TX = 1
DELAY_MS 50 ' clear for full DMX frame
Main:
' your code here
' DMX channel 1 value is in dmx(0), channel 16 is in dmx(15)
GOTO Main
' -------------------------------------------------------------------------
' Subroutine / Function Code
' -------------------------------------------------------------------------
' Use: DMX_OUT
' -- sends 88us break, 8us mark, start byte ($00), 16 DMX channel values
' -- takes about ~844us (0.844ms)
SUB DMX_OUT
dmxIdx VAR tmpB1
TX = 0 ' break
DELAY_US 88
TX = 1 ' mark
DELAY_US 8
TX_BYTE $00 ' start byte (not used)
FOR dmxIdx = 0 TO 15 ' send channels
TX_BYTE dmx(dmxIdx)
NEXT
ENDSUB
' -------------------------------------------------------------------------
' Use: TX_BYTE bVal
' -- adds 4us pad (to give each byte two stop bits per DMX spec)
SUB TX_BYTE
SEROUT TX, Baud, __PARAM1
DELAY_US 4 ' extra stop bit
ENDSUB
' -------------------------------------------------------------------------
' Use: DELAY_MS duration
' -- duration in milliseconds
' -- shell for PAUSE
SUB DELAY_MS
msDuration VAR __WPARAM12
PAUSE msDuration
ENDSUB
' -------------------------------------------------------------------------
' Use: DELAY_US duration
' -- duration in microseconds
' -- shell for PAUSEUS
SUB DELAY_US
usDuration VAR __WPARAM12
PAUSEUS usDuration
ENDSUB
' =========================================================================
' User Data
' =========================================================================
Quote from: gadget-evilusions on December 15, 2010, 01:11:07 PM
I am new to DMX, but a customer of mine wants to do a large que area show, which includes a DMX pan/tilt spot light that needs to be controlled. Everything else in the show is prop-1's and prop-2's that I would like to trigger from the prop-sx as well.
hehe, I wonder who that customer could have been...
Let me make it clear: DMX is hard, even in the Prop-SX, and the Prop-SX is limitied in what it can do vis-a-vis DMX. The HC-8+ on the other hand, with eight 32-bit processors and built-in RS-485 networking is just the ticket.