I have recently discovered that you can access pigpiod from a socket (check docs or code ). I wanted to leverage this feature so I can run a BrachioGraph from my computer. The best part is that I don't need to touch the code to tell the BrachioGraph where is the Raspberry pi daemon as it uses environment variables 👯♂️ 👯♀️ 🥳 .
I think that this feature is very convenient but is not documented. I propose to add a "Run from a PC" section under "Install the software" that explains the steps, that are, basically:
- Run pigpiod in the Raspberry pi as usual.
- In the PC install packages. In my case (debian bookworm):
sudo apt install -y python3-venv python3-tk libjbig0 libjpeg-dev liblcms2-2 libopenjp2-7 libtiff6 libwebpdemux2 libwebpmux3 libzstd1 libatlas3-base libgfortran5 git python3-venv python3-dev unzip make build-essential python3-pip
- Git clone, create the environment and run like in the Raspberry adding the address of the Raspberry as the PIGPIO_ADDR environment parameter (in the example
raspberrypi.local)
$ git clone https://github.com/evildmp/BrachioGraph.git
$ cd BrachioGraph/
BrachioGraph$ python3 -m venv env # Note that in the original docs the virtual environment is created in the parent folder, not in the repo's folder
BrachioGraph$ source env/bin/activate
(env) BrachioGraph$ pip install -r requirements.txt
(env) BrachioGraph$ PIGPIO_ADDR=raspberrypi.local python
>>> from brachiograph import BrachioGraph
>>> bg = BrachioGraph() # this bg controls the remote BrachioGraph at raspberrypi.local
...
So far, I have tested to move the axis but I have not tested to print anything so I don't know if there is any issue.
Greetings and thanks for this project!
I have recently discovered that you can access
pigpiodfrom a socket (check docs or code ). I wanted to leverage this feature so I can run a BrachioGraph from my computer. The best part is that I don't need to touch the code to tell the BrachioGraph where is the Raspberry pi daemon as it uses environment variables 👯♂️ 👯♀️ 🥳 .I think that this feature is very convenient but is not documented. I propose to add a "Run from a PC" section under "Install the software" that explains the steps, that are, basically:
raspberrypi.local)So far, I have tested to move the axis but I have not tested to print anything so I don't know if there is any issue.
Greetings and thanks for this project!