add a reference to the repo for the special version of SDCC with cc1111 sdcdb
[web/altusmetrum] / AltOS / index.mdwn
1 # AltOS
2
3 AltOS is the name of Keith's firmware "operating system" for 
4 [TeleMetrum](../TeleMetrum/) and [TeleDongle](../TeleDongle/).
5
6 In addition to the firmware for [TeleMetrum](../TeleMetrum) and 
7 [TeleDongle](../TeleDongle) boards, the AltOS source tree also includes a
8 number of utilities useful for monitoring and logging telemetry during flight,
9 post-processing flight data for analysis, plus utilities for updating firmware,
10 and developing and debugging new functionality.  The first generation of these
11 utilities were Linux-only, but our current second-generation software written
12 largely in [Java](http://java.com) with a small platform-specific library 
13 works identically on Windows, Mac, and Linux systems!
14
15 The firmware and associated software are licensed [GPL version 2](http://www.gnu.org/licenses/old-licenses/gpl-2.0.html)
16
17 ## Available Versions ##
18
19 [[!inline pages="./releases/* and !*/Discussion and !*.bz2 and !*.zip and !*.exe" show="10" rss="no" raw="yes" ]]
20
21 The latest source is always available from [git.gag.com](http://git.gag.com) 
22 in the project [fw/altos](http://git.gag.com/?p=fw/altos;a=summary).  
23
24 If you need to debug code on an Altus Metrum product, you may want the special
25 version of SDCC containing a highly modified sdcdb with support for the cc1111
26 debugging interface, which you can find on [git.gag.com](http://git.gag.com) 
27 in the project [fw/sdcc](http://git.gag.com/?p=fw/sdcc;a=summary).  This is
28 not necessary if you just want to rebuild AltOS and use it.
29
30 ## Features ##
31
32 Version 0.7.1 is the first release containing our new cross-platform Java-based user interface. AltosUI can:
33
34 * Receive and log telemetry from a connected TeleDongle device. All data 
35   received is saved to log files named with the current date and the connected 
36   rocket serial and flight numbers. There is no mode in which telemetry data 
37   will not be saved.
38
39 * Download logged data from TeleMetrum devices, either through a direct USB 
40   connection or over the air through a TeleDongle device.
41
42 * Configure a TeleMetrum device, setting the radio channel, callsign, apogee 
43   delay and main deploy height. This can be done through either a USB 
44   connection or over a radio link via a TeleDongle device.
45
46 * Replay a flight in real-time. This takes a saved telemetry log or eeprom 
47   download and replays it through the user interface so you can relive your 
48   favorite rocket flights.
49
50 * Reprogram Altus Metrum devices. Using an Altus Metrum device connected via 
51   USB, another Altus Metrum device can be reprogrammed using the supplied 
52   programming cable between the two devices.
53
54 * Export Flight data to a comma-separated-values file. This takes either 
55   telemetry or on-board flight data and generates data suitable for use in 
56   external applications. All data is exported using standard units so that no 
57   device-specific knowledge is needed to handle the data.
58
59 * Speak to you during the flight. Instead of spending the flight hunched over 
60   your laptop looking at the screen, enjoy the view while the computer tells 
61   you what’s going on up there. During ascent, you hear the current flight 
62   state and altitude information. During descent, you get azimuth, elevation 
63   and range information to try and help you find your rocket in the air. Once 
64   on the ground, the direction and distance are reported.
65
66 AltosUI provides all of these features on the three target operating systems, 
67 Linux, Mac OS X (version 10.5 or newer) and Windows (XP, Vista or 7). The bulk 
68 of the software is written in Java and is built once and tested and delivered 
69 on all three target platforms. A tiny ‘shim’ library is built on each system 
70 to provide access to the Altus Metrum devices connected over the USB link.
71
72 ## Future Plans ##
73
74 A number of features are implemented or in process in the sources available
75 in our publicly visible repository that are not part of the current stable
76 release.  Some of these features are already available in our C utilities, 
77 but not yet part of our second-generation Java user interface altosui.
78
79 * [Google Earth](http://earth.google.com) "KML" file export.  The 
80   first-generation C program ao-postflight can do this, the implementation 
81   in altosui has improvements.
82
83 * Data plotting.  The first-generation C program ao-postflight can output a
84   set of standard plots as an svg file.  The plotting code we're integrating 
85   into altosui supports direct interaction with the data and is much more fun!
86
87 * State-dependent display. When the rocket is on the pad, you mostly want to 
88   know if it’s ready to fly. When the rocket is descending on a chute, you 
89   want to know where it is in the sky and how fast its falling. Presenting a 
90   limited amount of information that represents what is most interesting to 
91   the user at any given time should make the display easier to read.
92
93 * Ejection charge testing. The TeleMetrum firmware has the ability to be
94   commanded to fire ejection charges over the USB or radio links. Safely 
95   hooking this up to the user interface will allow for wireless ejection 
96   system testing.  It is possible to do this today with a terminal program,
97   but we want this to be a feature in altosui.  The key here is “safely”, of 
98   course, which means figuring out a ‘fool proof’ user interface.
99
100 * A Kalman-filter based approach to apogee detection using more than just the
101   baro sensor, so that we can safely control apogee ejection on flights to
102   altitudes beyond the range of our baro sensor alone.  Unlike the other items
103   on the list, this will be a significant change to the in-rocket TeleMetrum
104   firmware.  It may therefore be a while before this becomes part of a stable 
105   firmware release.
106
107 There are any number of additions that could be made to this list; feel free 
108 to send along ideas that you’ve got. Of course, all of this software is 
109 licensed under the GNU General Public License, so you can get the source and 
110 hack on it in the comfort of your own home.
111
112 ## Platform Specific Notes ##
113
114 ### Linux ###
115
116 If you use [Debian](http://www.debian.org), then a pre-built package for 
117 32-bit x86 is currently available here:
118
119         wget -O - http://altusmetrum.org/apt/altusmetrum.key | apt-key add -
120         wget -O /etc/apt/sources.list.d/altos.list http://altusmetrum.org/apt/altos.list
121         apt-get update
122         apt-get install altos
123
124 If you use some other distribution of Linux, then 
125 a Linux package of our second-generation Java bits that 
126 should run on any distribution with a modern Java version is also 
127 available.  Unlike the Debian pacakge, which depends on various libraries
128 already part of the Debian distribution, this package includes a "fat" jar
129 file with all of the Java libraries that aren't part of the basic Java runtime
130 environment included, so it should "just work" on any system with 
131 Java 6.  Development and testing is done with OpenJDK 6, but current 
132 downloads from [java.com](http://java.com) should be fine too.
133
134 If you'd rather build from source, our source tree includes documentation on 
135 how to build packages for various
136 Linux systems such as [Arch Linux](http://www.archlinux.org), and the 
137 debian/ directory contains all the control
138 files for building the Debian packages on other architectures or derivatives
139 such as [Ubuntu](http://ubuntu.com).
140
141 Bdale has also created a theme for 
142 [GDM](http://projects.gnome.org/gdm/) that he uses on his primary notebook,
143 and the 
144 [Simple Login Manager](http://slim.berlios.de/) that he uses on all of his
145 other machines and which is ideally suited for machines dedicated to AltOS 
146 ground station use.  It includes a photo of a drag-race between 
147 nearly-identical rockets
148 built by Keith and Bdale, that was the first time either of us gave TeleMetrum
149 complete control of a rocket flight without some other backup!  See the themes/
150 directory in the source tree (the themes are included in the Debian package).
151
152 ### Mac ###
153
154 A Mac OS X package that is compatible with 
155 versions 10.5 "Leopard" and later (including 10.6 "Snow Leopard") is 
156 available.  The Mac operating system includes Java, and all Altus Metrum
157 products show up as simple USB serial ports, so this should just work
158 with no additional drivers or other dependency issues.  Older versions of 
159 the Mac operating system come with Java versions that are too old for use 
160 with Altus Metrum software, and we know of no way to update the Java version
161 other than upgrading to a newer operating system.
162
163 ### Windows ###
164
165 Our Windows package is known to work on at least some flavors of XP, Vista, and 
166 Windows 7 Enterprise. If you don't already have Java installed, 
167 download and install a current Java 6 version from [java.com](http://java.com)
168 first.  Then download our installer and run it.  Windows already has 
169 the required USB serial device driver, and our package should do the right
170 things to bind it to our devices, but if you get a complaint about the device
171 being unrecognized, try pointing to the copy of the telemetrum.inf file 
172 included in the package directory manually.  Reports of success or failure 
173 with other versions of Windows would be appreciated!