source: core/trunk/client/README.txt @ 271

Last change on this file since 271 was 265, checked in by smoser, 12 years ago

#153

  • Property svn:mime-type set to text/plain
File size: 4.3 KB
RevLine 
[211]1
2
3    OVERVIEW
4   
5This document describes the installation procedure for the Flarm-Radar Client
6on a Raspberry PI running Raspbian. At the time of writing this document, this
7is the only platform where the client has been tested over a long time period
8in a production-like environment.
9
10However, the client can be installed on any operating system where
[265]11Perl (http://www.perl.org) is available. Some customising might be required
[211]12in this case.
13
14
15    REQUIREMENTS
16   
17Note: Early versions of Raspbian had a nasty bug that caused minicom to freeze
18  the entire system after some hours or days of operations. Don't forget to
19  update the OS before starting with the installation.
20
[265]211. Log on the Raspberry (as user 'pi') and install required dependencies
22  -> $ sudo apt-get update && apt-get install zip dnsutils libwww-perl minicom
[211]23 
[265]242. Connect the Flarm to the Raspberry and start minicom
25  -> $ sudo minicom
26
273. Configure communication settings for minicom (tty, baud rate, etc.). Save the
[211]28  configuration file. Once the configuration is correct and the Flarm Device is
[215]29  turned on, you must be able to see live position data when you start minicom:
30
[265]31$ sudo minicom
[211]32....
33$GPRMC,123512.00,A,4710.24781,N,00902.46662,E,0.017,237.67,240312,,,A*6E
34$GPGGA,123512.00,4710.24781,N,00902.46662,E,1,8,1.40,413.2,M,48.0,M,,*6E
35$PFLAA,0,-118,-85,1,1,4B51BC,0,,0,0.1,1*1E
36$PFLAA,0,-35,-124,2,1,4B51FF,158,,0,0.1,1*14
37$PFLAU,2,1,1,1,0,,0,,*61
38$GPRMC,123513.00,A,4710.24782,N,00902.46659,E,0.002,237.67,240312,,,A*60
39$GPGGA,123513.00,4710.24782,N,00902.46659,E,1,8,1.40,413.1,M,48.0,M,,*67
40....
41 
42If you reach that: Congratulations, you're nearly done :-)
43
44
45    INSTALLATION
[265]46
47Installation is possible via software package or manually, the second option
48is for advanced users.
49
50Installation via Software Package
51
521. Download and unzip the client from http://www.flarmradar.ch/public/dist/pkg
53  -> $ wget http://www.flarmradar.ch/public/dist/pkg/flarmclient_<version>_all.deb
54
552. Install the package
56  -> $ sudo pkg -i flarmclient_<version>_all.deb
[211]57 
[265]58
59Manual Installation
60
[211]611. Create a new account named 'flarm'
[265]62  -> $ sudo useradd -m --system flarm
[211]63
[216]64Note1: This account does not need a password (because you might loose it and
[211]65  it is safer anyway).
66 
[216]672. Make sure that the user 'flarm' has permissions to read from the device
68  that was previously configured in minicom. If RS232-USB adapter is used, then
69  this is /dev/ttyUSB0, or alike. It is usually sufficient to assign the user
70  with an additional secondary group.
71 
723. Change identity to 'flarm'
[265]73  -> $ sudo su - flarm
[211]74 
[216]754. Download and unzip the client from http://www.flarmradar.ch/public/dist
[223]76  -> $> wget http://www.flarmradar.ch/public/dist/client-SNAPSHOT.zip
77  -> $> unzip flarmclient-SNAPSHOT.zip
[211]78 
79
80    CONFIGURATION
81
[265]82The client reads a single configuration file /etc/flarmclient.conf
[211]83
[265]841. Set the a client key. Request a key at info@flarmradar.ch if you use
85  the public server. If you use your own server, then you are free to set
86  your own key.
[211]87
[265]882. Configure the URL of the flarm server. If you use the public server, then
89  you can leave the default value.
[211]90
91
[265]92
[211]93    TEST THE INSTALLATION
[265]94
951. Download a file containing sample data for testing
96  -> $ wget https://secure.netzschmiede.ch/trac/flarmradar/browser/core/trunk/client/data/2012_03_25_departure.data
[211]97   
[265]982. Start the client as user 'flarm', use the test file from above for testing
99  $> sudo -u flarm flarmclient -f 2012_03_25_departure.data
[211]100 
101The client must run without errors and stream the data to the server. Check on
102the server while the client is processing the data file.
103
[265]1043. Connect the FLARM device and run the client software
[215]105  $> flarmclient
106 
107... if all goes well, you can see live data on your radar. Congratulations!
108
109   
110    INTEGRATION
111
112We must make sure that the client starts automatically after booting the
[265]113device.
[215]114
[265]115If the client was installed via software package, then you find
116a working example in /etc/cron.d/flarmclient. Remove the hash(#)-character
117at the beginning of the first line. The cron-job then periodically checks if
118the client is up and restarts it if necessary. This is useful for a device
119that is installed on the field where you don't have direct access to restart
120the process.
[223]121
[265]122Alternatively, use a runlevel script to start the client at boot time. Many
123examples for this can be found in the internet.
Note: See TracBrowser for help on using the repository browser.