I'm trying to create a simple DMX controller. I have all the hardware sorted out, but I'm stuck on the DMX output side.
I tried to send just a single channel, but it wouldn't work, I think it's the hardware.
I'm using a Nano compatible board, and a RS485 board (not a single chip, but one of these user ready boards.
RI is not connected
RE is high (+5v)
DE is high (+5v)
DI is connected to pin 2 (and specified in the code)
Ground is ground on the xlr
A is data + on the xlr
B is data - on the xlr
Vcc is +5v
If the LED light address is 1, then I don't see any reason why it should not work.
You might try a different output pin.
Do you have another RS485 board you could try?
If it's not to much trouble, can you show a picture of how you have thing connected.
There is a 120R resistor on those boards that should be removed, usually named R7, still that shouldn't be the issue.
you may have A & B inverted. XLR pins have numbers (1, 2 & 3)
1 - GND
2 - B (or pin 7 of the MAX485 transceiver)
3 - A (or pin 6 of the MAX485 transceiver)
That may indicate that the A & B lines are swapped.
I use Conceptinetics.h for DMX transmission, that uses the UART which is a lot less CPU intensive than the DmxSimple bit-bang method.
Still DmxSimple should work,
You may want to increase the amount of channels to at least 128. Although DMX protocol allows for incomplete frames, some fixtures require a minimum of 128 channels. (i'd go for the full 512 channels really)
I'll try and answer as many questions at once, but before I do, for some reason the fixtures does show dmx connection, but still it won't turn on. the dmx settings are correct (right number of channels and start adres)
I've changed the maxChannel to 64, 512 and 256, but that didn't help.
I'm sending 255 to channels 1, 2 and 3 now.
I have tried another usb port and cable, but the voltage is still at 4,6V.
Double checked the output pins on the MAX485, they are correct. (A and B is not reversed)
should I remove the resistor?
I'm looking into another dmx library, but I found if I use the regular Tx and Rx on the board, I no cant upload any code or use the serial monitor, which makes trouble shooting a lot harder.
Not on DMX it's not ! You never put a terminator on the master. But as stated, it is not the cause.
Have you actually swapped them over to try (there is no harm in trying that)
You can upload code if you remove the shield, but as far as i remember on the Nano's i've had, uploading actually still worked.
As for debug messages on the Serial monitor, that is all they really are.
Still, DmxSimple.h does work.
If you plan to put the whole thing in a box, you should just power the Arduino with 5v (on Vin) and power the module with 5v.
I am assuming that you are actually using a 5v (16Mhz) Nano, but i think it is important to check. DmxSimple is, well simple, it should check, but bit-banging 250Kbps from an 8MHz MCU is a bit more problematic.
Well that is a first ! Anyway for all permanently 1 way streets it just shouldn't be. You understand my issue with these modules is that people put multiple modules in a chain, all with a terminator on there, that is bound to cause issues. One doesn't. Mind you, the DMX fixture the OP is using, being the last Fixture in the chain, should actually have a terminator, and probably doesn't. A male XLR plug with a 120R resistor between pins 2 & 3 is specified. (some fixture have switches that enable the terminator, and well those switches get flicked incorrectly as well ) Again in most cases, issues don't show up on short leads, but any DMX chain should be properly terminated or the cables, even though shielded, will start to act as antenna, and may (and i have seen this only once) and will start to pick up stuff. At 10 meter chain length you becomes susceptible to 5G signal.
I switched from dmxSimple to Conceptinetics (no luck) and now to ArduinoRS485.h/ArduinoDMX.h.
I use the TX pin to DI on the 485 board. the TX LED on the Nano lights up, the Fixture (1) indicates DMX signal, but still no lights come on.
I checked the cable, all the way from the board to the end of the cable, the connection is good.
I've tried different DMX addresses, different universeSizes (from 4 to 16 and even 100) still nothing.