Hello everyone,
First of all I'm very new to arduino and everything coding but I thought of a project that I could maybe figure out by myself but I keep getting stuck.
What I'm trying to do is send a dmx signal from my lighting console to my dmx shield and with that signal I want to control a motor on my L293D motor shield, I've got a stepper motor connected to M3 an M4 but I can't figure out what to do to set a dmx channel to M3 and M4 on the motor shield.
After quite a while of research I came this code but it keeps spitting out an error that it can't convert AF_Stepper to uint8_t.
I'm hoping anyone can point me in the right direction.
Arduino uno R3
DMX Shield: ctc-dra-10-r2
Motorshield: L293D motor shield
#include <AFMotor.h>
// Connect a stepper motor with 400 steps per revolution
// to motor port #2 (M3 and M4)
AF_Stepper motor(400, 2);
#include <DMXSerial.h>
#define MAX_ANGLE 360
#define STEPS_FOR360 400
#include <DMXSerial_avr.h>
#include <DMXSerial_megaavr.h>
void setup() {
DMXSerial.init(DMXReceiver);
pinMode(motor, OUTPUT);
}
void loop() {
analogWrite(motor, DMXSerial.read(1))
}