DMX data sending.

Hello All,
I do think I have landed in the right place. :) I have a DMX board that controls the Galvo Scanner. Galvo,Galvos, Galvanometer Scanners,laser show,laser projector at laserpic . It can be controlled using DMX512 input and I would like to build my own DMX512 transmitter using PIC Microcontroller. I also have SN75176 to generate the output. Can anyone please give me an example circuit and code snippet in CCS C Compiler and help me get started with it. CCS C forum has some snippets for receiving DMX, but only one for transmitting. Comments are in French and honestly I did not understand anything from it. Kindly advice.


Thank you.
 
Instead of writing your own interface for DMX, it may be more worth your time to pick up a USB-DMX interface (like the Enttec DMX USB Pro). There are many software based control programs that are free that will work with the Enttec interfaces (like MagicQ). This is the route that I would take as it is simple and I am not a programmer. I am sure that if you want to do your own programming there are members here who can help, but the question I usually ask people is: "Why reinvent the wheel?"
 
I, too, recommend shelling out the $60 for an Enttec adaptor, which has a very common and easy-to-use programming API. If you don't have enough cash for that you could try a cheaper Chinese one off of eBay, but there'll probably be way less software and SDK support.

I have done DMX IO with Arduino where it's actually quite well documented, but it was a pain to get working properly. Really, the indestructible metal Enttec brick will serve you much longer and more reliably than something hacked together on protoboard.
 
Instead of writing your own interface for DMX, it may be more worth your time to pick up a USB-DMX interface (like the Enttec DMX USB Pro). There are many software based control programs that are free that will work with the Enttec interfaces (like MagicQ). This is the route that I would take as it is simple and I am not a programmer. I am sure that if you want to do your own programming there are members here who can help, but the question I usually ask people is: "Why reinvent the wheel?"

There are several reasons to consider reinventing the wheel.
  • It's a lot of fun.
  • The wheel is lumpy and hard to use and does not work very well.

The state of the art in controlling conventional fixtures has not progressed much since the original Light Palette. Sure we have faster computers, touch screens, etc. We have incorporated controls for things we did not need to do when the palette came out ( like LED fixtures, CMY color wheels) - but the conceptual models of how to think about and control a large number of lights is still pretty primitive.

That's why I work on polishing that wheel - because I want to move the state of the art in lighting consoles just a bit further down the road - and because I am continually frustrated by the console getting in the way of what I want to do with the lights.
 
I know of some transmit code for AVR Microcontrollers, I'll find it and link it here if you think it might be of use. Don't know about the license though.

What are you trying to accomplish? I agree that the Enttec module may be easier, unless you want to take the computer out of the picture for some reason.
 
Hello.
I am using SN75176 to generate pulse for the DM512 and I am going to give the channel data from PIC controller. I have an assembly code that works well, but as I do not know assembly I am having difficulties in converting the same to C. Can you please help me with it.

Assembly code is here...

DMX 512 Pic 16F84 Printerport interface

and this is the code that I have been trying to write so far, still do not have luck. Please help

Code:
#include <16F876A.h>
#fuses XT,NOWDT,PUT,NOBROWNOUT,PROTECT
#use delay(clock=4000000)

#byte PORTA=0x05
#byte TRISA=0x85 
#bit DMXOUT=PORTA.0
#byte CH1=255
#byte CH2=150


int i;

void main()
{
set_tris_a(0x00);
PORTA=0xFF;

	while(1){
		DMXOUT=1;
		delay_us(3);		
		DMXOUT=1;
		delay_us(3);
		DMXOUT=0;
		delay_us(101);
		DMXOUT=1;
		delay_us(3);
		DMXOUT=1;
		delay_us(3);
		DMXOUT=0;
		delay_us(3);
		delay_us(35);
		DMXOUT=1;
		delay_us(3);
		DMXOUT=1;
		delay_us(3);
		DMXOUT=1;
		delay_us(3);
		DMXOUT=0;
		delay_us(3);
		for(i=0; i<=7; i++)
		{
			DMXOUT=1;
			delay_us(1);
			DMXOUT=0;
			delay_us(1);
		}
		DMXOUT=1;
		delay_us(3);	
		DMXOUT=1;
		delay_us(3);
		DMXOUT=1;
		delay_us(3);
		delay_us(3);

		
	
}
}
 
Hello all,
I have a scanner that can be controlled using DMX. You can find the manual for the DMX table here. http://www.laserpic.com/Product_galvo/LP30K_ch25D_TC_manual.pdf
I am using PIC Controller to send the DMX data to the board. Now the question is...

1) As stated in the manual it has 25 channels. (What is the difference between Pattern A and Pattern B) ?

2) Suppose, if I should make a Veritlcal / Hotizontal movement with will be the channel data that has to be sent ?

3) In the DIP switch I have turned ON SWITCH - 10 and SWITCH - 1. Is that correct ?

4) What will be the output if I send the following data ?
255,6,0,0,0,
255,6,0,0,0,
255,6,0,0,0,
255,6,0,0,0,
255,6,0,0,0,


Many Thanks for your time.
 
Bitbanging a UART is really the wrong way to do it. The 16F876 has a perfectly good hardware UART.

The documentation for that scanner is very poorly written; you will have to do some experimenting to figure it out. Your dipswitch setting looks correct for a DMX start channel of 1. It's not clear what pattern A and B are; perhaps the unit can display two images simultaneously.

No idea what will happen if you send those 25 bytes, but based on the channel chart in the document, they make no sense.

You will be much better off going over to Microchip's forum or another forum geared to embedded development.

/mike
 

Users who are viewing this thread

Back