Mind-Controlled Microcontroller
Your Mind-Controlled Light Switch, on a Raspberry Pi Pico 2 W.
On the Mind-Controlled Light Switch demo you teach a custom AI head two states, resting and a thought you hold, and install it on your IntoMind One, which runs it on its own chip. One small program lets a Raspberry Pi Pico 2 W, a microcontroller board with Bluetooth and an LED, connect to your IntoMind One by itself and turn its LED on while your custom AI head reads On. No computer in the room.
You need
A Raspberry Pi Pico 2 W. The Pico 2 without the W has no Bluetooth.
A micro USB cable that carries data. Some cables only charge.
A computer with a USB port.
Your IntoMind One, with a custom AI head installed from the Mind-Controlled Light Switch demo.
Steps
01Teach your custom AI head
On the Mind-Controlled Light Switch demo, teach your two states, then press Run it on your IntoMind One. Your custom AI head, the small model that tells your two states apart, is now installed on your IntoMind One.
You should seeThe board drawn on the demo lighting up while you hold your On thought.
02Download the program
One file holds the whole program for the board, ready to run. Its source is on this site for anyone who wants to change it.
Download the programYou should seeA file named light-switch-pico-2-w.uf2.
03Put it on the board
Hold the white BOOTSEL button while you plug the board into your computer, then let go. Drag the file onto the drive that appears.
You should seeA drive named RP2350 that closes by itself once the file is on it, then the LED blinking once a second. A Mac may warn that the disk was not ejected properly. That is expected.
04Turn on your IntoMind One
Take it off its charger and put it on, and close any tab connected to it. The first time, the board pairs with it, and from then on it remembers it.
You should seeThe LED stops blinking, then comes on while you hold your On thought.
05Put the board anywhere
Unplug the board from the computer and power it from any USB charger. It finds your IntoMind One by itself whenever it has power.
You should seeThe LED, saying one of the six things shown beside the board.
If it does not work
Build on it
The program is plain C on Raspberry Pi's own toolkit for the board, and it marks where your own code goes. The code to switch a pin is already there, commented out: pin GP15, the board's pin 20, with ground on pin 18. Uncomment it and rebuild, and the pin goes high, to 3.3 volts, while your custom AI head reads On: a signal any circuit, robot or project of your own can act on.
The source is board/main.c, and the build steps are in board/README.md.