Copyright (c) 2023-2025 Antmicro
A Python library for interacting with Renode programmatically.
Use pip to install pyrenode3:
pip install 'pyrenode3[all] @ git+https://github.com/antmicro/pyrenode3.git'
If you have Renode installed, then pyrenode3 will interact with it.
Otherwise, if you don't want to install Renode, you can download a Renode package and set PYRENODE_PATH to its location.
To quickly run a sample demo, download the package and run:
wget https://builds.renode.io/renode-latest.pkg.tar.xz
wget https://raw.githubusercontent.com/antmicro/pyrenode3/main/examples/unleashed-fomu.py
export PYRENODE_PATH=`pwd`/renode-latest.pkg.tar.xz
bpython -i unleashed-fomu.py
This will spawn a two-machine demo scenario and, when the Linux boots to shell, you will be able to interact with the simulation via bpython interface.
pyrenode3 can be configured using environment variables:
PYRENODE_PATH- Specifies the location of Renode that will be used bypyrenode3. This can point to a package, an unpacked Renode directory, a Renode source directory with build output, or a portable binary. To modify the output directory used as a source of Renode binaries (location ofRenode.exe), you must set thePYRENODE_BUILD_OUTPUTvariable, with a path relative to the Renode source directory.PYRENODE_PKG,PYRENODE_BUILD_DIR, andPYRENODE_BIN- Deprecated aliases forPYRENODE_PATH.
The Renode path should be specified to use pyrenode3 with a non-installed Renode.
If no variable is specified pyrenode3 will look for the Renode installed in your operating system.
