Skip to content

Commit

Permalink
Merge branch 'ntp' of https://github.com/canopy-ros/canopy_client int…
Browse files Browse the repository at this point in the history
…o ntp
  • Loading branch information
Zareen Choudhury committed Jan 25, 2018
2 parents cbf71f6 + d68ce14 commit 12ba446
Showing 1 changed file with 36 additions and 9 deletions.
45 changes: 36 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,25 +2,52 @@
This is the ROS node for the client-side application of Canopy.

## Installation
See the [Canopy docs](http://canopy-docs.readthedocs.io/en/latest/client-docs.html#installation).
```
cd <YOUR CATKIN WORKSPACE>/src
git clone https://github.com/baalexander/rospy_message_converter
git clone https://github.com/canopy-ros/canopy_client
cd canopy_client
. ./canopy_client_install.sh
```

## Clock Synchronization
This section describes the _client-side_ instructions for synchronizing the clocks of your Canopy clients and the Canopy server using `chrony`.

Install chrony and copy the configuration file to `/etc/chrony`:
```
sudo apt-get install chrony
sudo cp chrony_canopy_client.conf /etc/chrony
```

### Setting up chrony
Modify the chrony configuration file `/etc/chrony/chrony_canopy_client.conf` to reflect your Canopy server's IP address:
```
# /etc/chrony/chrony_canopy_client.conf
server 128.31.37.168
...
```
Disable and stop the default chrony service:
```
sudo systemctl stop chrony
sudo systemctl disable chrony
```

Enable and start the Canopy chrony service:
```
sudo systemctl enable chrony_canopy_client
sudo systemctl start chrony_canopy_client
```

### Checking chrony setup
To check whether the service is running correctly, run `systemctl status chrony_canopy_client` which should show an active running status:
```
chrony_canopy_client.service - chrony service for canopy client
Loaded: loaded (/lib/systemd/system/chrony_canopy_client.service; static; vendor preset: enabled)
Active: active (running)
...
```

Restart chrony with this configuration file:
To check whether the chrony daemon `chronyd` is working correctly, run `chronyc activity` which should return the following:
```
sudo chronyd -f /etc/chrony/chrony_canopy_client.conf -r -s
200 OK
3 sources online
0 sources offline
0 sources doing burst (return to online)
0 sources doing burst (return to offline)
0 sources with unknown address
```
If you see the message `506 Cannot talk to daemon`, then `chronyd` is not running properly.

0 comments on commit 12ba446

Please sign in to comment.