Andy2778:
If I am not wrong, shift register is shift the output state across the output pin which I don't think suitable for my case because I need to switch on the relay individually. Correct me if I am wrong.
You're wrong.
This is basically how a shift register works:
-
micro shifts a byte in a shift register, or a string of bytes into a string of shift resisters.
Every bit of the byte(s) represents a shift register output. -
micro generates a latch pulse, and the data/byte is moved to the outputs of the shift registers (and stays there).
-
micro is not needed anymore, until a different relay pattern is needed.
Andy2778:
Basically we just need a device that can control multiple output individually with latch function, it must be low cost and finished products, like Arduino which we can buy and use it immediately.
A common Arduino (Uno, Nano) has enough I/O to control two common/cheap 8-channel relay boards.
An Arduino output pin does not change it's state until you tell it to.
Leo..