-
Notifications
You must be signed in to change notification settings - Fork 2
Datalogger setup log
Setup for data acquisition from GPS, humidity, altimet, NB. Machine reachable at adsb.local.
apt-get install ntp ntpdate gpsd gpsd-clients udhcpd lighttpd pyserial
update-rc.d -f lightdm remove
echo Etc/UTC >/etc/timezone
sudo dpkg-reconfigure --frontend noninteractive tzdata
dpkg-reconfigure gpsd
Autostart yes, usb automatically no, device /dev/ttyS2
, options -n
, sock keep default.
Previously, ntp was used for time synchronization. But this clashes with the gpsd as it attempts to open the ttyS2 concurrently. One option is to use two outputs (ttyACM0 for the USB readout and ntp daemon and ttyS2 for gpsd).
Chrony takes about one minute to synchronize, this is the chrony.conf
used:
refclock SHM 0 refid GPS poll 2 trust
makestep 0.1 -1
keyfile /etc/chrony/chrony.keys
commandkey 1
driftfile /var/lib/chrony/chrony.drift
# log tracking measurements statistics
# logdir /var/log/chrony
dumponexit
dumpdir /var/lib/chrony
local stratum 10
logchange 0.5
rtconutc
Data shall be stored to SD card. 32 GB SD card with ext4 mounted at /data, bound to /dev/mmcblk1p1 in fstab.
IP set in nm-connection-manager
to 192.168.0.5 static, gw 192.168.0.1, so the network would be accessible.
Edited /etc/default/udhcpd
to enable the daemon start.
Modified /etc/udhcpd.conf
to:
start 192.168.0.20 #default: 192.168.0.20
end 192.168.0.40 #default: 192.168.0.254
interface eth1 #default: eth0
option domain local
option lease 864000 # 10 days of seconds
First we'll try lighttpd. The setup was modified to include:
server.document-root = "/data"
server.dir-listing = "enable"