4 relay module not working test code?

I've been struggling for ages trying to get my 4 module relay board to work with the code I've written. I'm now certain either the Arduino UNO has a fault on the digital out pins or the 4 relay module is faulty. Can anyone give me a bit of test code they know works with the following relay board on an UNO, and also the wiring connections used to connect them. Also is there a simple way to test the Arduino digital pins outputs with a multi meter, what voltage am i looking for when the output is high and low.

What is the coil voltage of the relays that YOU HAVE? Post a photo of your relays.

That eBay page lists 13 different items, 3 of which have 4 relays. Which did you buy? How have you wired it? What voltage are you switching with the relay?

With a multimeter you should see 0V when the pin is LOW and 5V, or close to it, when the pin is HIGH. Of course, you also need to know how to use a multimeter. And a lot of newbies don't. You could also use an led and series resistor.

Can you post a picture of the actual relay board that you have?
The relay boards with opto-couplers typically connect the VCC to the 5v pin of the arduino, and the data inputs connect to arduino output pins. A separate power supply is used to power the relay coils, connected to GND and JD-VCC (a common labeling, but varies). There is no connection between the arduino GND and the relay board GND - this is very important for isolating the arduino from electrical noise generated by the relay board. The data inputs to the relays are active LOW, meaning a LOW output activates the relay, a HIGH output turns it off.

this is the actual board i have 5V, 12V or 24V 1-2-4-8-16 Channel Relay Module Arduino PI ARM AVR DSP PIC | eBay

OK so I've tested all 3 digital out pins 4, 5, and 6 which would normally be connected to the relay board IN1-3 and I get a oscillating voltage from 0.3V to -3.3V about every couple of seconds on all 3 pins. Just to make sure I've not missed something obvious. I've connected the ground wire from the multi meter to the ground on the arduino an the positive lead to the relevant digital out pin is this correct?

I've just disconnected all the wires from the board and re connected new wires in case something was wrong and i now get and oscillating 0.003V to 4.3V, which sounds correct, as the code is

digitalWrite(4,LOW);
digitalWrite(5,LOW);
digitalWrite(6,LOW);
delay(1000);
digitalWrite(4,HIGH);
digitalWrite(5,HIGH);
digitalWrite(6,HIGH);

I must have had a loose or broken wire.

But still when i reconnect the relay board it wont turn the relays on and off

(deleted)

jamesb123:
OK so I've tested all 3 digital out pins 4, 5, and 6 which would normally be connected to the relay board IN1-3 and I get a oscillating voltage from 0.3V to -3.3V about every couple of seconds on all 3 pins. Just to make sure I've not missed something obvious. I've connected the ground wire from the multi meter to the ground on the arduino an the positive lead to the relevant digital out pin is this correct?

Your multimeter connections sound correct, but those readings make no sense. What do you read if you connect positive probe to 5V pin?

jamesb123:
I've just disconnected all the wires from the board and re connected new wires in case something was wrong and i now get and oscillating 0.003V to 4.3V, which sounds correct, as the code is
I must have had a loose or broken wire.

But still when i reconnect the relay board it wont turn the relays on and off

So with the wires connected you get different multmeter readings than when the wires were not connected?

Does your code set the arduino pins to OUTPUT?

Have you connected the 12V power supply for the relays? I suspect without that, you won't hear any clicking and the leds on the relay boards will not light.

Did you try my led + resistor suggestion to test the arduino pins, without the relays connected?

Just to verify, do you have the 5v, 12v, or 24v version of the relay board?

If you have the 5v version, are you trying to power the relay board from the arduino? That would likely not work because the arduino cannot supply sufficient current to power four relays.

Do you have Vcc from the arduino connected to the relay board, on the same connector as the relay inputs, and has the yellow jumper on the relay board been removed (jumper may be another color on the board you have, it is yellow in the picture).

The relay board appears to have LED indicators, are those lighting when the digital input is set to LOW?