Go Down

Topic: Dmx module aansluiten (Read 546 times) previous topic - next topic

The_Specialist

Sep 03, 2019, 06:03 pm Last Edit: Sep 04, 2019, 09:59 am by The_Specialist
ik heb vma432 dmx Transmitting module

De pins van dmx module          
- GND
- VCC
- NC    
- SIG  

En ik zou een PWM DMX512 60A Dimmer Driver RGB Strip Controller for LED Strip,LED Module,LED Lamp DC12V-24V

Ingangssignaal: DMX512/1990

Uitgangssignaal: Constante PWM


ik zou dit willen verbinden met arduino uno r3 en weet niet welke pins hiervoor te gebruiken met welke libary?

Ik heb geprobeerd met pin 3 en dmx simple library, maar lukt maar niet. De led driver krijgt geen signaal.

Code: [Select]
/* Welcome to DmxSimple. This library allows you to control DMX stage and
** architectural lighting and visual effects easily from Arduino. DmxSimple
** is compatible with the Tinker.it! DMX shield and all known DIY Arduino
** DMX control circuits.
**
** DmxSimple is available from: http://code.google.com/p/tinkerit/
** Help and support: http://groups.google.com/group/dmxsimple       */

/* To use DmxSimple, you will need the following line. Arduino will
** auto-insert it if you select Sketch > Import Library > DmxSimple. */

#include <DmxSimple.h>
int Brightness;
int IntChannel;
int IntMaxChannel=7;
void setup() {
 //Serial.begin(9600);
 Serial.begin(115200);//for sonar
 ////Serial.setTimeout(0);
 while (!Serial);
 //Serial.println("Debuging begint");
 /* The most common pin for DMX output is pin 3, which DmxSimple
 ** uses by default. If you need to change that, do it here. */
 DmxSimple.usePin(3);

 /* DMX devices typically need to receive a complete set of channels
 ** even if you only need to adjust the first channel. You can
 ** easily change the number of channels sent here. If you don't
 ** do this, DmxSimple will set the maximum channel number to the
 ** highest channel you DmxSimple.write() to. */
 DmxSimple.maxChannel(IntMaxChannel);
 pinMode(LED_BUILTIN, OUTPUT); //Blinking led on board //voor led on shield te laten blinken als het programma 1keer geladen is
}

void loop() {

 /* Simple loop to ramp up brightness */
 //for (Brightness = 0; Brightness <= 255; Brightness++) {
 for (IntChannel = 0; IntChannel <= IntMaxChannel; IntChannel++){
 /* Update DMX channel 1 to new brightness */
 //DmxSimple.write(IntChannel, Brightness);
 DmxSimple.write(IntChannel, 255);
 //Serial.println("Channel Written");
 delay(10);
 }
 /* Small delay to slow down the ramping */
 delay(1000);
 //}

 //for (Brightness = 0; Brightness <= 255; Brightness++) {
 for (IntChannel = 0; IntChannel <= IntMaxChannel; IntChannel++){
 /* Update DMX channel 1 to new brightness */
 //DmxSimple.write(IntChannel, Brightness);
 DmxSimple.write(IntChannel, 0);
 //Serial.println("Channel Written");
 delay(10);
 }
 /* Small delay to slow down the ramping */
 delay(1000);
 //}
 //Serial.println("1 loop");
 digitalWrite(LED_BUILTIN, HIGH); //Blink led on board
 //waitTime = 100;
 //wait();
 delay(100);
 digitalWrite(LED_BUILTIN, LOW);
}

The_Specialist


Go Up