| 1 |
# WeAct Studio RP2040 |
| 2 |
|
| 3 |
The WeAct Studio RP2040 Board is based on the Raspberry Pi RP2040 and can be |
| 4 |
purchased with 2/4/8/16 MiB of flash. |
| 5 |
|
| 6 |
These boards are available from a number of resellers and often have the name |
| 7 |
"Pico Board RP2040". WeAct maintain the [WeActStudio.RP2040CoreBoard](https://github.com/WeActTC/WeActStudio.RP2040CoreBoard/tree/master) |
| 8 |
repository containing information on the board. |
| 9 |
|
| 10 |
## Build notes |
| 11 |
|
| 12 |
By default the firmware supports boards with 16MiB flash. This can be |
| 13 |
configured using the `BOARD_VARIANT` parameter. The valid options are |
| 14 |
`FLASH_2M`, 'FLASH_4M', and 'FLASH_8M'. |
| 15 |
|
| 16 |
```bash |
| 17 |
> cd ports/rp2 |
| 18 |
> make BOARD=WEACTSTUDIO BOARD_VARIANT=FLASH_8M submodules all # Build the 8 MiB variant |
| 19 |
``` |
| 20 |
|
| 21 |
## Board-specific modules |
| 22 |
|
| 23 |
The `board` module contains definitions for the onboard LED and user button. |
| 24 |
|
| 25 |
Example: |
| 26 |
|
| 27 |
```python |
| 28 |
> import board |
| 29 |
> board.led.toggle() # Toggles the state of the on-board LED |
| 30 |
> board.key.value() # Returns 0 or 1 corresponding to the state of the user key |
| 31 |
``` |