Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

USB serial connection to CBus RS232 PCI feature request #9

Closed
DarylMc opened this issue Dec 20, 2020 · 2 comments
Closed

USB serial connection to CBus RS232 PCI feature request #9

DarylMc opened this issue Dec 20, 2020 · 2 comments

Comments

@DarylMc
Copy link
Contributor

DarylMc commented Dec 20, 2020

Hello Greig
@greiginsydney
I've got a raspberry pi setup using a FTDI USB adapter from the raspberry pi to the Clipsal 5500PC RS232 PCI.

The setup instructions have been available for years now but I forgot it was an option.
I plan to post some info here for consideration as an option in the installer script.

@DarylMc
Copy link
Contributor Author

DarylMc commented Dec 21, 2020

https://blog.addictedtopi.com/2017/05/21/installing-c-gate-on-a-raspberry-pi/
This is where I have always sourced how to setup CGate on the raspberry pi.
Since my CBus networks have an ethernet interface I always skipped the ser2sock service.

This could be put in the install script as an option before CGate installation.
I can't see a problem to install by default and leave the ser2sock service disabled for CNI users.

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

sudo systemctl enable ser2sock.service
sudo systemctl start ser2sock.service

@Amos0001
Copy link

Done!
thanks

@DarylMc DarylMc closed this as completed Jan 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants