mirror of
https://github.com/HendrikRauh/dmx-interface.git
synced 2025-07-09 23:25:45 +00:00
finished modification of lob
This commit is contained in:
parent
4157c8a21d
commit
ab377defb5
3 changed files with 38 additions and 52 deletions
28
src/ESPDMX.h
28
src/ESPDMX.h
|
@ -12,19 +12,29 @@
|
|||
|
||||
#include <inttypes.h>
|
||||
|
||||
|
||||
#ifndef ESPDMX_h
|
||||
#define ESPDMX_h
|
||||
|
||||
// ---- Methods ----
|
||||
#define DMXSPEED 250000
|
||||
#define DMXFORMAT SERIAL_8N2
|
||||
#define BREAKSPEED 83333
|
||||
#define BREAKFORMAT SERIAL_8N1
|
||||
#define SERIALPORT Serial0
|
||||
#define DMXCHANNELS 512
|
||||
|
||||
class DMXESPSerial {
|
||||
public:
|
||||
void init(int id, int pinSend, int pinRecv);
|
||||
uint8_t read(int id, int Channel);
|
||||
void write(int id, int channel, uint8_t value);void update();
|
||||
void end();
|
||||
void update(int id);
|
||||
class DMXESPSerial
|
||||
{
|
||||
public:
|
||||
int sendPin;
|
||||
int recvPin;
|
||||
bool started;
|
||||
uint8_t dmxDataStore[DMXCHANNELS + 1];
|
||||
|
||||
void init(int pinSend, int pinRecv);
|
||||
uint8_t read(int Channel);
|
||||
void write(int channel, uint8_t value);
|
||||
void update();
|
||||
void end();
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue