-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathArduino_ArtNetNode_DMX.ino
More file actions
38 lines (27 loc) · 865 Bytes
/
Copy pathArduino_ArtNetNode_DMX.ino
File metadata and controls
38 lines (27 loc) · 865 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#include "src/Artnet/Artnet.h"
#include "src/Artnet/Packets.h"
#include "src/Conceptinetics/Conceptinetics.h"
#define WEBDUINO_FAVICON_DATA ""
#include <WebServer.h>
#include <EEPROM.h>
#include "globals.h"
void softwareReset() {
asm volatile (" jmp 0");
}
void setup() {
// disable the SD card by switching pin 4 high
// not using the SD card in this program, but if an SD card is left in the socket,
// it may cause a problem with accessing the Ethernet chip, unless disabled
pinMode(4, OUTPUT);
digitalWrite(4, HIGH);
loadSettings();
Artnet.begin(mac, ip, subnetMask, artnetNet, artnetSubnet, artnetUniverse, longName, shortName);
Artnet.sendArtPollReply();
DMXMaster.enable();
startWebserver();
}
void loop() {
uint8_t * data = DMXMaster.getBuffer().getPointer();
Artnet.read(data);
webserver.processConnection();
}