PDA

View Full Version : timing for dmx??



oscar
- 7th May 2005, 16:44
hello to you all. my name is oscar and i am for want of a better word "newbie"..lol.

i reciently purchased pbp in the hope of making a dmx512 reciever to control 3 pins that run some leds.. i have failed totally !! ..... i have tryed several commands such as serin , hserin , shiftin etc but to no avail... i think that maybe the commands take to much time to run hence the data i have tryed to recieved has long gone by the time the instruction has been completed.!!!

is there any way that this can be done in pbp? asm is just to much for me to get my head around.!!!!!!!!!!!!
i am using a pic 16f876a at 16mhz to set the baud rate of the usart to 250000 but i cant figure out how to decode the data stream?????

is anyone out there genius enough lol to help me out on this pleaseeeee..

im loosing hair at this stage.

thank you

oscar.

mister_e
- 7th May 2005, 17:11
Baudrate= 250 000 Bauds sure of it?

If so, you'll have to use the HSERIN,HSEROUT statement of PBP.

Setting for 16MHZ crystal.
DEFINE HSER_TXSTA 24h
DEFINE HSER_RCSTA 90h
DEFINE HSER_SPBRG 3

by using a 20MHZ crystal
DEFINE HSER_TXSTA 24h
DEFINE HSER_RCSTA 90h
DEFINE HSER_SPBRG 4

Once you're able to grab data from your DMX stuff, use SERIN/SEROUT on other pins to send that data to your PC.

mister_e
- 7th May 2005, 17:14
have a look this link (http://www.proav.de/index.html?http&&&www.proav.de/lighting/DMX512.html)

Here (http://www.dmx512-online.com/dloads.html)

oscar
- 7th May 2005, 17:22
just wanted to say thanks steve for your quick responce to my post......

it seems like the usart is the only wat to go if i want to decode the dmx stream at 250000 hm pretty quick ...lol.. i shall start again !!!!!!!