|
Tollos – Tollos libraries | |
|
Libraries
Background
|
Tollos is wholly written in C and includes the following libraries.
There are also device libraries which provide the ‘glue’ between
the Tollos libraries and the hardware.
Tollos library This libary is called tollos, and is accessed by including tollos.h. It comprises the following modules (.c files with corresponding .h files). Click on the module name for a more detailed description of the functions in the module. The Tollos module is the core of the system; its primary function (sysStartup) sets up the hardware and runs the application as follows:
Also provided are the following functions:
Simple interface to 3-axis accelerometers.
Controls digital I/O bit(s) as available:
Provides communications with a host computer, if available. The functions are:
Numerous functions for drawing to a screen, including:
Three fonts are included with Tollos: a 5×7 monospace (default) ASCII font, a compatible 7×7 proportional font, and an unspaced 8×12 “IBM PC” 256-character font. Simple interface to 3-axis gyroscopes.
Functions to read and write data from I2C bus devices, in I2C master mode (the microcontroller is the Master):
Controls on-board LED(s) as available:
Functions to use UART serial communications devices.
TollosUtil is a small set of utilities (functions and macros):
The vcom functions provide character I/O over a USB link (Virtual COM port).
The miniDec module supports a simple decimal format, ‘dec’, intended for the storage, management, and display of decimal data. As such, it provides functions for conversions to and from ints, doubles, and strings in various forms, along with decQuantize to ‘shape’ decimal data. Additional functions allow detailed inspection and manipulation of decimals. Arithmetic operations are currently not included, but the bounds of the format conform to IEEE 754 rules (section 3) and IEEE 754 arithmetic functions could be added later.
The strf string formatter in tollosUtil can include dec data
using the %m format code.
Other libraries (These are currently running under an earlier version of Tollos, in an experimental avionics device; these will be documented when fully ported to Tollos and mbed and tested.) tollosGPS – high-level access to a GPS device with a ring buffer of messages, etc. tollosSensors – accelerometer, gyro, etc. – the generic interfaces will be moved to the tollos library; specific device glue functions will move into their own library (e.g., ADXL345, ITG3200) tollosGeog – geographic library (bearings and distances from GPS positions) tollosMenu – a simple menu system
|
| Tollos and these web pages were written by Mike Cowlishaw; Please send me any corrections, suggestions, etc. | |
|
All content © Mike Cowlishaw, 2010–2012, except where marked
otherwise. All rights reserved. The pages here are for non-commercial
use only (see the separate licence for Tollos source code).
Privacy policy: the Speleotrove website
records no personal information and sets no ‘cookies’.
However, statistics, etc. might be recorded by the web hosting
service.
This page was last updated on 2011-01-27 by mfc. |