iii. How to Develop¶
Here, we will perform two steps in one: learning how to make modifications to the code, and how to change the final screen in CCIS which describes what the builds are.
What IDE should I use?¶
Anki tended to use Visual Studio Code - just use that.
What OS should I use?¶
An M-series Macs, or an x86_64 Linux PC - toolchains are only available for these platforms.
Let's make a modification!¶
- Open up the diode-os-victor folder in VSCode.
- Open up
animProcess/src/cozmoAnim/faceDisplay/faceInfoScreenManager.cpp
- Modify lines 69-72 to match the details of your new CFW.
- Open a terminal and run
cd ~/diode-os-victor
- Build the code by running this:
./build/build-v.sh
Deploy¶
When you deploy code to a robot, his /anki folder gets replaced. This can be done on a laptop (reference: Ryzen 7840U, 16GB RAM). You do not need to build a whole OTA every time you want to test a change. ./build/build.sh just builds a /anki folder.
- Open a terminal and
cd ~/diode-os-victor
- Echo your robot's IP address to robot_ip.txt:
echo "192.168.1.50" > robot_ip.txt
- Run:
curl -o robot_sshkey https://github.com/kercre123/unlocking-vector/raw/refs/heads/main/ssh_root_key
- Deploy:
./build/deploy-v.sh
Build an OTA with your change¶
- Run
cd ~/diode-os
- Update the submodule:
cd anki/victor
git pull origin main
cd ../../
git add .
git commit -m "vp"
git push
- Build:
./build/build.sh -bt dev -v 1
- Your OTA will be at: ./_build/vicos-3.0.1.1d.ota.