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

Doc: update installation of NodeJS, add paths for NMEA sample files + cosmetics #1648

Merged
merged 9 commits into from
Nov 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 16 additions & 18 deletions docs/src/installation/raspberry_pi_installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,16 @@ Once the OS installation has been completed, you are ready to commence.

1. Update the list of install packages.
```
$ sudo apt update
sudo apt update
```

1. Install NodeJS and npm.
```
$ curl -sL https://deb.nodesource.com/setup_18.x | sudo -E bash -
$ sudo apt-get install -y nodejs
```
1. Install NodeJS 18 and npm.

Follow [instructions for Ubuntu and Debian based distributions like Raspberry Pi OS at NodeSource Distributions](https://github.com/nodesource/distributions#installation-instructions).

1. Ensure that we're using the latest version of npm.
```
$ sudo npm install -g npm@latest
sudo npm install -g npm@latest
```

Use the following command to check the versions of NodeJS and npm installed.
Expand All @@ -51,25 +49,25 @@ Once the OS installation has been completed, you are ready to commence.

1. Install a Bonjour (mDNS) service for Linux called Avahi, which allows Apps and other network devices to Discover the Signal K server.
```
$ sudo apt install libnss-mdns avahi-utils libavahi-compat-libdnssd-dev
sudo apt install libnss-mdns avahi-utils libavahi-compat-libdnssd-dev
```

## Install Signal K Server

```
$ sudo npm install -g signalk-server
sudo npm install -g signalk-server
```

You can test that installation was successful by starting the server using some
sample data.

```
$ signalk-server --sample-nmea0183-data
signalk-server --sample-nmea0183-data
```

You should see the terminal output "signalk-server running at 0.0.0.0:3000" as shown below...
```
$ signalk-server --sample-nmea0183-data
signalk-server --sample-nmea0183-data
Using sample data from /usr/lib/node_modules/signalk-server/samples/plaka.log
signalk-server running at 0.0.0.0:3000
```
Expand Down Expand Up @@ -101,7 +99,7 @@ Now that you have Signal K server installed, you will want to generate a setting
and configure your RPi to start the server automatically. To do this run the setup script by entering the following command and follow the prompts.

```
$ sudo signalk-server-setup
sudo signalk-server-setup
```

You can re-run this command at any time in the future to change the settings.
Expand All @@ -114,20 +112,20 @@ Signal K server will now be started automatically when your RPi boots up.

If you want to temporarily stop the Signal K server, you can do so by entering the following commands:
```
$ sudo systemctl stop signalk.service
$ sudo systemctl stop signalk.socket
sudo systemctl stop signalk.service
sudo systemctl stop signalk.socket
```

To start Signal K server again enter the following commands:
```
$ sudo systemctl start signalk.service
$ sudo systemctl start signalk.socket
sudo systemctl start signalk.service
sudo systemctl start signalk.socket
```

To stop Signal K server from starting automatically enter the following commands:
```
$ sudo systemctl disable signalk.service
$ sudo systemctl disable signalk.socket
sudo systemctl disable signalk.service
sudo systemctl disable signalk.socket
```


Expand Down
Binary file added docs/src/setup/SK_file_stream_N2K.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 17 additions & 1 deletion docs/src/setup/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,26 @@ The options presented will vary based on the data type chosen.

Please refer to the [Canboat PGN database](https://canboat.github.io/canboat/canboat.html) to see what PGNs are supported.


**_NMEA0183_**: The processing of NMEA0183 sentences is done by [nmea0183-signalk](https://github.com/SignalK/signalk-parser-nmea0183)

**Connection type "File Stream"**

Sample files are available which can be set up as input for the server.

Use below command to get the path to a NMEA 2000 file with navigation data and AIS targets.

```
sudo find / -name "aava-n2k.data"
```
Set up according to picture.

![SK_N2K_file](./SK_file_stream_N2K.png)

To get the path for the sample file, data type NMEA 0183, use below command.

```
sudo find / -name "plaka.log"
```
### Install Plugins and Webapps

Signal K server functionality can be extended through the use of plugins and webapps.
Expand Down
Loading