I have a main PCB with a microcontroller on it with lots of connectors on it to connect to many other (peripheral) PCBs which have sensors and report data to the MCU on the main PCB.
I wanted to detect using just code if one of the external (peripheral) PCBs is connected to the main PCB, and I want to light an LED via an I2C RGB LED driver using the MCU (say "yellow" if PCB detected.)