I’m doing a new bike under-light build with some 12v strips.

I’m doing a new bike under-light build with some 12v strips. Part of the concept is the driver board will automatically cut power to the LEDs when the bike stops, by way of a p-channel MOSFET on the 12v line feeding the strips.

Do I also need to switch off the data line? I vaguely remember tales of fried microcontrollers due to LEDs attempting to pull power through the data line.

From adafruit best practices:
"
Avoid connecting NeoPixels to a live circuit. If you simply must, always connect ground first, then +5V, then data. Disconnect in the reverse order.

If powering the pixels with a separate supply, apply power to the pixels before applying power to the microcontroller.
"

So sounds like you will want to disconnect data, then cut 12v power when stopping. And apply 12v power and then connect data when lighting back up.

This also reminded me of a post by @Juergen_Bruegl

@Robert_Atkins if you have the chance always switch off the data line.
There are strange things happening in this universe. Check this out:


Cheers!

Aha, thanks @marmil . I am using a pre-built soft power switch of what I imagine to be a very similar design from adafruit (https://www.adafruit.com/product/1400) to power the Arduino (actually RFduino), and since there’s now two lines I need to cut depending on whether it thinks the bike is moving, I will probably drive the MOSFETs with one of these little guys: https://www.intersil.com/content/dam/Intersil/documents/icl7/icl7667.pdf