- Raspberry Pi 3
- Raspbian Jessy Lite
- Image an SD card with Raspbian (we're using a 16GB one)
- Power up the Pi and figure out what the IP address is. Connect with
ssh [email protected]
, default password:raspberry
- Resize the filesystem to fill the full card:
sudo raspi-config
, selectExpand Filesystem
, hitOK
a couple of times, thenFinish
and reboot - Reconnect with SSH, and update the package lists:
sudo apt-get update
- Change the
pi
user's password by runningpasswd
. Enter the old password when prompted, then the new password twice. - Install git:
sudo apt-get install git
- Go to chilipeppr.com, find the Serial Port Console workspace (http://chilipeppr.com/serialport) and download the Raspberry Pi distribution:
serial-port-json-server-1.88_linux_arm.tar.gz
- Create a new user to run it on the Pi. While logged in as
pi
:sudo adduser cnc
. Enter a password when prompted. - When prompted for user information, set the full name to
cnc
and accept the (blank) defaults for all other fields - Add the new
cnc
user to the sudoers list by creating a file called/etc/sudoers.d/cnc
with mode 0440 and the content:cnc ALL=(ALL) ALL
- Switch user to
cnc
:su - cnc
, then enter the password - Transfer the workspace downloaded in step 1 to the pi. I used (from my machine, note the trailing colon):
scp serial-port-json-server-1.88_linux_arm.tar.gz [email protected]:
- Back on the pi, extract the newly transferred workspace:
tar xzf serial-port-json-server-1.88_linux_arm.tar.gz
- Change into the new directory and start up the server:
cd serial-port-json-server-1.88_linux_arm
,./serial-port-json-server
- Now go back to the ChiliPeppr site and test the connection. Open http://chilipeppr.com/serialport, enter the Pi's IP address on the "Your Servers" tab and hit connect
If the connection test is successful, you'll want to stop the server and set it to run on startup.
- Back on the Pi, stop the server by hitting Ctrl+C.
- Add the server to the
cnc
user's crontab:@reboot /home/cnc/serial-port-json-server-1.88_linux_arm/serial-port-json-server
- Reboot the Pi to test whether the server starts up automatically:
sudo shutdown -r now
- Use the ChiliPeppr site to test the connection again, and hopefully... success!