### Setup Toit SDK and Tools Source: https://github.com/toitlang/jaguar/blob/main/README.md Downloads and configures the Toit SDK and necessary tools for flashing the Jaguar application onto an ESP32. This is a crucial step after installing the Jaguar binary. ```sh jag setup ``` -------------------------------- ### Install Jaguar CLI with Go Source: https://github.com/toitlang/jaguar/blob/main/README.md Instructions for installing the Jaguar command-line interface tool using the Go programming language's install command. ```sh go install github.com/toitlang/jaguar/cmd/jag@latest ``` -------------------------------- ### Install Jaguar with Homebrew Source: https://github.com/toitlang/jaguar/blob/main/README.md Installs the Jaguar command-line tool on macOS using the Homebrew package manager. This is a convenient way to get started with Jaguar for ESP32 development. ```sh brew install jaguar ``` -------------------------------- ### Flash and Run Example with Jaguar Source: https://github.com/toitlang/jaguar/blob/main/README.md Demonstrates the sequence of commands to flash a device, allow it to connect to WiFi, scan for the device, and run an example Toit application using Jaguar. ```sh build/jag flash sleep 3 # Give the device time to connect to the WiFi. build/jag scan # Select the new device. build/jag run $JAG_TOIT_REPO_PATH/examples/hello.toit build/jag monitor ``` -------------------------------- ### Install Jaguar from AUR Source: https://github.com/toitlang/jaguar/blob/main/README.md Installs the Jaguar package from the Arch User Repository (AUR) on Arch Linux. This command uses the `yay` helper to fetch and build the package. ```sh yay install jaguar-bin ``` -------------------------------- ### List Installed Containers Source: https://github.com/toitlang/jaguar/blob/main/README.md Displays a list of currently installed containers (services and drivers) on the device. This command helps manage system components. ```sh jag container list ``` -------------------------------- ### Install a Service Container Source: https://github.com/toitlang/jaguar/blob/main/README.md Installs or updates a named container, such as a service or driver, onto the device. Use 'jag container install' with the container name and its source file. ```sh jag container install print-service service.toit ``` -------------------------------- ### Install Jaguar with winget Source: https://github.com/toitlang/jaguar/blob/main/README.md Installs the Jaguar command-line tool on Windows 10+ using the Windows Package Manager (winget). This command ensures you have the latest version of Jaguar for your development environment. ```sh winget install --id=Toit.Jaguar -e ``` -------------------------------- ### Install Container with Disabled WiFi Source: https://github.com/toitlang/jaguar/blob/main/README.md Shows how to install a containerized application with Jaguar's WiFi disabled. This allows the container to control the WiFi before Jaguar takes over. ```sh jag container install -D jag.wifi=false softap softap.toit ``` ```sh jag container install -D jag.wifi=false -D jag.timeout=20s softap softap.toit ``` -------------------------------- ### Run Toit Code with Jaguar Source: https://github.com/toitlang/jaguar/blob/main/README.md Executes a Toit program on the target device using the 'jag run' command. This is the basic command to start your application. ```sh jag run hello.toit ``` -------------------------------- ### Update Jaguar with winget Source: https://github.com/toitlang/jaguar/blob/main/README.md Updates an existing Jaguar installation on Windows 10+ using the Windows Package Manager (winget). Regular updates ensure you have the latest features and bug fixes. ```sh winget upgrade --id=Toit.Jaguar -e ``` -------------------------------- ### Uninstall a Service Container Source: https://github.com/toitlang/jaguar/blob/main/README.md Removes a previously installed container from the device. Use 'jag container uninstall' followed by the container name. ```sh jag container uninstall print-service ``` -------------------------------- ### Scan for Jaguar Devices Source: https://github.com/toitlang/jaguar/blob/main/README.md Scans the local network for ESP32 devices running the Jaguar application using UDP broadcasts. This helps in discovering your device after it has been flashed and started. ```sh jag scan ``` -------------------------------- ### Compile Jaguar Project Source: https://github.com/toitlang/jaguar/blob/main/README.md Executes the make command to compile the Jaguar project, including the SDK, Toit dependencies, and the host executable. ```sh make ``` -------------------------------- ### Set Jaguar Toit Repository Path Source: https://github.com/toitlang/jaguar/blob/main/README.md Sets the environment variable JAG_TOIT_REPO_PATH to point to the Toit repository, which is necessary for building Jaguar. ```sh export JAG_TOIT_REPO_PATH=$PWD/third_party/toit ``` -------------------------------- ### Access Defines in Toit Code Source: https://github.com/toitlang/jaguar/blob/main/README.md Demonstrates how to access and use defines passed from the Jaguar CLI within Toit code. It imports necessary libraries to decode and retrieve defined values from system assets. ```toit import encoding.tison import system.assets main: defines := assets.decode.get "jag.defines" --if-present=: tison.decode it --if-absent=: {:} if defines is not Map: throw "defines are malformed" print defines["my-define"] ``` -------------------------------- ### Export ESP-IDF Environment Source: https://github.com/toitlang/jaguar/blob/main/README.md Sources the export script for the ESP-IDF environment, setting up necessary variables and PATHs for compiling ESP32 programs. ```sh source $JAG_TOIT_REPO_PATH/third_party/esp-idf/export.sh ``` -------------------------------- ### Configure WiFi Credentials Source: https://github.com/toitlang/jaguar/blob/main/README.md Stores WiFi SSID and password in Jaguar's configuration file to avoid re-entering them during flashing. This simplifies the flashing process for repeated use. ```sh jag config wifi set --wifi-ssid SSID --wifi-password PASSWORD ``` -------------------------------- ### Live Reload Toit Code with Jaguar Source: https://github.com/toitlang/jaguar/blob/main/README.md Monitors Toit files for changes and automatically reloads them on the target device. Use 'jag watch' to enable live reloading. ```sh jag watch hello.toit ``` -------------------------------- ### Flash Jaguar to ESP32 Source: https://github.com/toitlang/jaguar/blob/main/README.md Flashes the Jaguar application onto your ESP32 via a serial connection. This command prompts for the serial port and WiFi credentials. ```sh jag flash ``` -------------------------------- ### Disable Jaguar WiFi with Timeout Source: https://github.com/toitlang/jaguar/blob/main/README.md Demonstrates how to run a Toit application while temporarily disabling Jaguar's WiFi functionality. It also shows how to set a custom timeout for this operation. ```sh jag run -D jag.wifi=false softap.toit ``` ```sh jag run -D jag.wifi=false -D jag.timeout=5m softap.toit ``` -------------------------------- ### Add User to Dialout Group Source: https://github.com/toitlang/jaguar/blob/main/README.md Demonstrates how to add the current user to the 'dialout' group on Linux, which is often required to access serial ports. ```sh sudo usermod -aG dialout $USER ``` -------------------------------- ### Pass Defines to Toit Code Source: https://github.com/toitlang/jaguar/blob/main/README.md Passes custom defined values to the Toit application using the '-D' option with 'jag run'. These defines are accessible within the Toit code via system assets. ```sh jag run -D my-define=499 defines.toit ``` -------------------------------- ### Check Serial Port Permissions Source: https://github.com/toitlang/jaguar/blob/main/README.md Provides commands to check current user groups and the group ownership of a serial device, typically used for flashing devices like ESP32. ```sh groups ls -g /dev/ttyUSB0 ``` -------------------------------- ### Update Jaguar Firmware Source: https://github.com/toitlang/jaguar/blob/main/README.md Updates the Jaguar system software and application on the device via WiFi. This command 'jag firmware update' will uninstall all containers and stop running applications. ```sh jag firmware update ``` -------------------------------- ### Set Application Timeout Source: https://github.com/toitlang/jaguar/blob/main/README.md Limits the execution time of an application on the device using the '-D jag.timeout' option with 'jag run'. The timeout can be specified in seconds, minutes, or hours. ```sh jag run -D jag.timeout=10s service.toit ``` -------------------------------- ### Monitor ESP32 Serial Output Source: https://github.com/toitlang/jaguar/blob/main/README.md Connects to the ESP32's serial output to monitor logs and status messages from the running Jaguar application. This is useful for debugging. ```sh jag monitor ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.