-
Install WSL2 - https://learn.microsoft.com/en-us/windows/wsl/install
-
Install VS Code - https://code.visualstudio.com/download
-
Setup VS Code for WSL - https://learn.microsoft.com/en-us/windows/wsl/tutorials/wsl-vscode
-
Install Arduino IDE in WSL - In WSL shell, run the following:
- sudo apt-get install nautilus
- sudo apt-get install libfuse2
- sudo apt-get install zenity
- sudo apt-get install libasound-dev
- sudo apt-get install libgbm-dev
- sudo apt install python3-serial
Download Arduino IDE AppImage - https://downloads.arduino.cc/arduino-ide/arduino-ide_latest_Linux_64bit.AppImage Download AppImage to ~/ in WSL (can using the Windows File Explorer to Copy)
Run 'sudo chmod +x [image file name]' in WSL on the downloaded App Image.
run the appImage executable to test - ./arduino-ide_latest_Linux_64bit.AppImage
-
Get the Chatter 2.0 source and update Python - WSL>cd ~ WSL>git clone https://github.com/CircuitMess/Chatter2-Firmware.git
-
Open the Chatter2-Firmware.ino file in Arduino IDE
-
Add the board definitions and Compile following instructions at https://github.com/CircuitMess/Arduino-Packages/ Note: run this command if Python errors:
- WSL>sed -i -e 's/=python /=python3 /g' ~/.arduino15/packages/cm/hardware/esp32/*/platform.txt
At this point the Firmware should be compiled!
-
Get the Chatter2-Library
- WSL>cd ~
- WSL>git clone https://github.com/CircuitMess/Chatter2-Library
-
*** If you have a Chatter (green board) and NOT a Chatter 2.0 (red board) perform the following 2 steps ***
a) Reset the Firmware using https://code.circuitmess.com/ -> 'Restore Firmware' link on top nav. Pick Chatter 2.0.
This step will put some of the artifacts like images on the device.b) In VSCode open the src/PINS.hpp file - change:
#define BATTERY_PIN 34 #define PIN_WAKE 36 to #define BATTERY_PIN 36 #define PIN_WAKE 34
NOTE: This is my best guess on what the battery PIN mapping should be.
THEN run:
WSL>cp -R ~/Chatter2-Library ~/.arduino15/packages/cm/hardware/esp32/1.7.3/libraries
-
Install / Setup USB over IP for WSL - https://learn.microsoft.com/en-us/windows/wsl/connect-usb
-
Compile and Upload the Firmware. In the Arduino IDE:
- Tools -> Serial Monitor and then change to 115200 baud (it is defaulted to 9600 and you will not be able to read)
- Sketch -> Upload
If all goes well the board will update and restart. Error messages will show in serial monitor.
-
You can now make changes to the Firmware code (i.e. change Frequency). Adding Serial.println(..) is great way to start as well.