Open matlab22 opened 1 year ago
Here is how I succesfully installed it on my RP4 running DietPi 8.15:
Turn on Bluetooth:
dietpi-config
Check status of BT:
sudo systemctl status bluetooth
should look like this:
● bluetooth.service - Bluetooth service
Loaded: loaded (/lib/systemd/system/bluetooth.service; enabled; vendor preset: enabled)
Active: active (running) since Tue 2023-03-14 19:21:02 GMT; 37min ago
Docs: man:bluetoothd(8)
Main PID: 1636 (bluetoothd)
Status: "Running"
Tasks: 1 (limit: 2197)
CPU: 499ms
CGroup: /system.slice/bluetooth.service
└─1636 /usr/libexec/bluetooth/bluetoothd
Mar 14 19:21:02 DietPi systemd[1]: Starting Bluetooth service...
Mar 14 19:21:02 DietPi bluetoothd[1636]: Bluetooth daemon 5.55
Mar 14 19:21:02 DietPi systemd[1]: Started Bluetooth service.
Mar 14 19:21:02 DietPi bluetoothd[1636]: Starting SDP server
Mar 14 19:21:02 DietPi bluetoothd[1636]: Bluetooth management interface 1.21 initialized
Check Python version:
python3 --version
should look like this:
Python 3.9.2
Check if PIP is installed:
python3 -m pip --version
If not install with:
sudo apt-get install python3-pip
Install build essentials:
sudo apt-get update
sudo apt-get install build-essential
Install apt-get install python3-dev
to solve the problem with the missing "Python.h"
apt-get install python3-dev
Install TheengsGateway with pip:
pip3 install TheengsGateway
Make a test run like this:
python3 -m TheengsGateway -H "YOURBROKERIP" -u "USERNAME" -p "PASSOWRD"
or with debug details:
python3 -m TheengsGateway -H "YOURBROKERIP" -u "USERNAME" -p "PASSOWRD" -ll "DEBUG"
(9. Run it as a service) https://github.com/theengs/gateway/discussions/5#discussioncomment-2282815
here is the service I use to run as a user without root privilege. But make sure to run it first with the needed parameter under the user you would like to run it later as a service
nano /etc/systemd/system/TheengsGateway.service
[Unit]
Description=Theengs Gateway
After=network.target
[Service]
Restart=always
Type=simple
User=loxberry
Group=loxberry
ExecStart=/usr/bin/python3 -m TheengsGateway
[Install]
WantedBy=multi-user.target
Enable it:
sudo systemctl daemon-reload
sudo systemctl enable --now TheengsGateway.service
Check the status:
sudo journalctl -u TheengsGateway.service -f
Thanks for the tutorial! Out of curiosity seeing your nickname, are you using Theengs with Matlab?
Thanks for the tutorial! Out of curiosity seeing your nickname, are you using Theengs with Matlab?
I used matlab a long time ago. I think the ability of python makes matlab obsolete for me.
The apt-get install python3-dev just did the trick for me trying to install on an Orange Pi 3 LTS. Thank you!
Describe the bug It looks like there is a build error related to missing files required for the project to build successfully. Specifically, the error mentions that the file "Python.h" cannot be found.
System
To Reproduce Steps to reproduce the behavior:
ERROR
here is the detailed error with pip3 install TheengsGateway --verbose: