When we disconnect the XRP from the USB cable to our computer, we lose the ability to communicate with it.
Most robot platforms include some way to wirelessly communicate with a computer, smartphone, remote control device, etc.
The XRP controller includes the Raspberry Pi Pico W microcontroller, which includes hardware support for Bluetooth and WiFi wireless connections.
Review:
Using the Web Server as a Dashboard
(Note that " live-updating" is not yet support in Blockly, but is possible with MicroPython)
You need to connect your smartphone or notebook and our XRP to the same WiFi network.
On your smartphone or notebook, connect to this WiFi network:
SSID: workshop
Password: arduino1
SSID: BTUgoo
Password: blowItUp
Create the program shown here →
Or download remote_control_hello_world.blocks to your notebook, then in the XRP Code Editor, File ... Upload to XRP
Run the program
You should see some like this in the Shell/console:
Starting DNS Server at 192.168.0.106
Open a web browser window on your smartphone or notebook and go to the IP address shown in the Shell (in this example, http://192.168.0.106)
Click on the right arrow (->) button to turn on the LED.
Click on the stop ([]) button to turn off the LED.
Modify this program and change the code for the web page buttons to do something else.
Ideas:
Move the servo up, move the servo down
Drive forward, stop, turn left, turn right
Convert the Blockly program to Python and control the LED on the Button and LED module
Your ideas?