Skip to content

Commit 85167c4

Browse files
committed
Update README.md
1 parent 5ebde97 commit 85167c4

File tree

1 file changed

+6
-66
lines changed

1 file changed

+6
-66
lines changed

README.md

Lines changed: 6 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -1,73 +1,13 @@
11
# Getting Starting with your XRP Robot
22

3-
- First steps of tutorial borrowed from [here](https://projects.raspberrypi.org/en/projects/get-started-pico-w/1)
3+
### Step 1: Plug XRP Robot Controller Board into Computer
44

5-
# Step 1: Install Micropython on your XRP Robot Controller:
5+
### Step 2: Navigate to [xrpcode.wpi.edu](https://xrpcode.wpi.edu)
66

7+
- Follow instructions there to install MicroPython and the libraries onto the board
78

8-
### Download the latest version of Raspberry Pi Pico W firmware [here](https://rpf.io/pico-w-firmware)
9+
### Step 3: Navigate to the tutorial linked there to learn how to use the bot!
910

10-
Connect the small end of your micro USB cable to the Raspberry Pi Pico W.
11+
$~$
1112

12-
![A Raspberry Pi Pico W connected to the small end of a micro USB cable.](https://projects-static.raspberrypi.org/projects/get-started-pico-w/0b627b5c80e71000b5116ecc35acaa49094aef84/en/images/pico-top-plug.png)
13-
14-
Hold down the BOOTSEL button on your Raspberry Pi Pico W.
15-
16-
![A Raspberry Pi Pico W with the BOOTSEL button highlighted](https://projects-static.raspberrypi.org/projects/get-started-pico-w/0b627b5c80e71000b5116ecc35acaa49094aef84/en/images/bootsel.png)
17-
18-
Connect the other end to your desktop computer, laptop, or Raspberry Pi.
19-
20-
![A Raspberry Pi Pico W connected to a laptop via a micro USB cable.](https://projects-static.raspberrypi.org/projects/get-started-pico-w/0b627b5c80e71000b5116ecc35acaa49094aef84/en/images/plug-in-pico.png)
21-
22-
Your file manager should open up, with Raspberry Pi Pico being show as an externally connected drive. Drag and drop the firmware file you downloaded into the file manager. Your Raspberry Pi Pico should disconnect and the file manager will close.
23-
24-
![Image of the Windows file manager opened, showing Raspberry Pi Pico connected as an external drive](https://projects-static.raspberrypi.org/projects/get-started-pico-w/0b627b5c80e71000b5116ecc35acaa49094aef84/en/images/file_manager.png)
25-
26-
27-
# Step 2: Installing dev environment (Mu)
28-
29-
30-
### Download the latest version of the Mu editor [here](https://codewith.mu)
31-
32-
Open Mu, and select the RP2040 Option (Or whichever option represents using Micropython for the board you have)
33-
34-
![](https://codewith.mu/img/en/tutorials/mode_selector1-1.png)
35-
36-
## Step 3: Installing the library using mip
37-
38-
Open up a new file in mu.
39-
40-
Copy the following code into that file:
41-
42-
```python
43-
import network
44-
import mip
45-
import time
46-
47-
def install_update_library(wifi_ssid, wifi_password, timeout = 5):
48-
49-
wlan = network.WLAN(network.STA_IF)
50-
# Configure board to connect to wifi
51-
wlan.active(True)
52-
wlan.connect(wifi_ssid,wifi_password)
53-
start_time = time.time()
54-
# Wait until connection is confirmed before attempting install
55-
while not wlan.isconnected():
56-
print("Connecting to network, may take a second")
57-
if time.time() > start_time+timeout:
58-
print("Failed to connect to network, please try again")
59-
wlan.disconnect()
60-
return
61-
time.sleep(0.25)
62-
# Install up-to-date library files and dependencies
63-
mip.install("github:Open-STEM/XRP_MicroPython")
64-
# Disconnect and disable wifi, since it is no longer needed
65-
wlan.disconnect()
66-
wlan.active(False)
67-
68-
install_update_library("your-ssid","your-password")
69-
```
70-
71-
Edit the method call at the bottom to include your wifi's details, then hit run.
72-
73-
Check the Serial Monitor to confirm that the libraries were properly installed.
13+
### That's it! Happy Learning!

0 commit comments

Comments
 (0)