https://github.com/wokwi/wokwi-embed-bridge-example
Example for using Wokwi together with Platform.io (Prototype)
https://github.com/wokwi/wokwi-embed-bridge-example
Last synced: 5 months ago
JSON representation
Example for using Wokwi together with Platform.io (Prototype)
- Host: GitHub
- URL: https://github.com/wokwi/wokwi-embed-bridge-example
- Owner: wokwi
- Created: 2022-06-28T08:50:37.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2022-06-28T08:51:06.000Z (almost 3 years ago)
- Last Synced: 2024-11-16T01:12:09.656Z (7 months ago)
- Language: Python
- Size: 2.93 KB
- Stars: 3
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Wokwi Platform.io Bridge Example
Note: this is an early prototype, and the implementation is subject to change without notice. Future versions may also impose limits and restrictions on the usage of this feature.
For questions use the Wokwi discord chat at https://wokwi.com/discord
## Usage
1. Install Python version 3.8 or newer and the PlatformIO CLI.
2. Install the python requirements by running
```
pip install -r requirements.txt
```
3. Build the sample arduino project by running
```
cd example && pio run
```
4. Start the bridge server
```
python server.py
```
5. Open the following link in your web browser:
https://wokwi.com/_alpha/wembed/335697688728175187?partner=platformio&port=9012&data=demo"You can change the number in the link to any valid Wokwi project id. The simulator will use the
given project as a template for the diagram (and possibly other settings, such as SD Card files).## Customization and debugging
You can modify the hex/elf file paths inside server.py to serve different set of files.
The bridge server also opens a local GDB server at port 9333. You can debug the code running in the simulation by attaching GDB to this port:
```
target remote localhost:9333
```