Quantity   Component name
1 × DPDT relay, 5V coil. Opto-isolated to protect the µC.
1 × Arduino Nano Or your favourite µC module