Closed DarylMc closed 1 year ago
It's ironic @DarylMc that you've posted this update because I finally found some time a few weeks ago to re-test the setup.md that @greiginsydney created and I tried to merge in your changes. Let me wipe the sd card I have in my raspberry pi and re-run my testing. My intention was to see if I could run both the CBUS plugin as well as the Unifi Protect cameras plugin on the same pi.
Does this ticket take over from ticket #22 that I raised?
@jensenoz Yes it addresses #22 Let me know how you go in case I missed something. I will run up another test install today. When I get a chance I will try editing Greig's setup instructions and send a pull request.
@jensenoz
My list of steps if that helps
FYI the latest Raspberry Pi Imager is throwing an error so I went back one version.
(Mac) rpi imager advanced settings set hostname (homebridge) username (pi) password (*****) enable ssh
(Mac) Generate key for ssh connections
(Mac) ssh-keygen
(Mac) Copy RSA key to pi
(Mac) ssh-copy-id pi@homebridge.local
ssh pi@homebridge.local
sudo apt update && sudo apt full-upgrade
sudo reboot
sudo dpkg-reconfigure locales
sudo timedatectl set-timezone Australia/Brisbane
sudo reboot
example File transfer (Mac-pi) scp /Users/darylmcdougall/Downloads/TEST.xml pi@homebridge.local:/home/pi
example File transfer (pi -Mac) sudo scp setup.sh darylmcdougall@MacBookPro.local:/Users/darylmcdougall/Downloads
Install Homebridge-CBus Plugin
sudo hb-shell
sudo hb-service add homebridge-cbus
exit
Run Greig's script
sudo apt install subversion -y
svn export https://github.com/greiginsydney/Homebridge-cbus-installer/trunk/code/ ~ --force
sudo chmod +x setup.sh
sudo -E -H ./setup.sh step1
wait 5-10min after reboot
sudo -E ./setup.sh copy
Fix error connecting to remote CGate
allow TLS V1 and TLS V1.1
sudo nano /usr/lib/jvm/java-8-openjdk-armhf/jre/lib/security/java.security
Remove TLSv1, TLSv1.1 in the line "jdk.tls.disabledAlgorithms="
For USB serial interface
git clone https://github.com/nutechsoftware/ser2sock.git
sudo mv ser2sock /usr/local/bin
cd /usr/local/bin/ser2sock
chown -R pi:pi .
mv config.h.in config.h
cc -o ser2sock ser2sock.c
sudo nano /etc/systemd/system/ser2sock.service
[Unit] Description=ser2sock
[Service] ExecStart=/usr/local/bin/ser2sock/ser2sock -p 10001 -s /dev/ttyUSB0 -b 9600 Restart=always User=root Group=root Environment=PATH=/usr/bin:/usr/local/bin Environment=NODE_ENV=production WorkingDirectory=/usr/local/bin/ser2sock/
[Install] WantedBy=multi-user.target
Enable and Start service
sudo systemctl enable ser2sock.service
sudo systemctl start ser2sock.service
disable wifi
sudo systemctl disable wifi-connect.service
sudo nano /boot/config.txt
add the two lines after
"# Additional overlays and parameters are documented /boot/overlays/README"
dtoverlay=disable-wifi
dtoverlay=disable-bt
Apologies @DarylMc I don't quite understand the purpose of these two lines. Is this the copy over of the CBUS .XML file to the Pi?
@jensenoz Do you mean the example file transfer using scp? I just thought it might be helpful to mention how to do via terminal.
Ahh bingo. Apologies. I actually use WIN Scp and kinda thought that might be what those lines were referring to by the virtue of the SCP item in the two lines. ;)
Instructions updated Issue closed https://github.com/greiginsydney/Homebridge-cbus-installer/pull/26
This issue was fixed with https://github.com/greiginsydney/Homebridge-cbus-installer/pull/26
Follow Greig's setup instructions but homebridge-cbus plugin needs to be installed with this method before running the script. Install homebridge-cbus Enter hb shell
sudo hb-shell
sudo hb-service add homebridge-cbus
Exit hb shellexit
Transfer xml to /home/pi Install subversionsudo apt install subversion -y
Download Greig's scriptsvn export https://github.com/greiginsydney/Homebridge-cbus-installer/trunk/code/ ~ --force
sudo chmod +x setup.sh
sudo -E -H ./setup.sh step1
After the reboot take a break for 5-10 minutes. Run the next script
sudo -E ./setup.sh copy