Llosa de Viango Tollos – microcontroller libraries



Getting started



  Tollos libraries

  Device libraries





  Sample application


Microcontroller libraries include:

  • a linker script suitable for use with Tollos (part of the Tollos package)
  • code ‘glue’ modules (.c and possibly .h files) for Tollos interfaces (part of Tollos)
  • code modules (.c and .h files) for the microcontroller core (usually derived by the device manufacturer from materials supplied by ARM)
  • code modules for drivers for the microcontroller peripherals (GPIO, UARTs, etc.); these are written and provided by the device manufacturer (NXP, STM, etc.).

Manufacturer-supplied source code is always held in a subdirectory of a library named ‘public’. These files are not part of Tollos but are included in the download so that all the source code needed to support an application is available. It is believed their licensing terms indicate that the manufacturer-supplied code may be freely used and distributed, but you should check the terms yourself if you have a concern.

The following microcontroller libraries are under development for Tollos:

  • lpc17xx – code and linker scripts for the LPC1763 through LPC1769 chips, using the CMSIS-compliant library supplied by NXP.

  • stmf10x – code and linker script for the STM32f10x family of chips, using the CMSIS-compliant library supplied by STMicroelectronics. The USB support is partitioned into a separate library, stmvcom.

ARM Cortex-based microcontrollers usually include a number of common devices, although the drivers for these vary significantly between manufacturers. Tollos provides the following ‘glue’ modules which hide these differences.

Bit device

These functions take a port (GPIO register) number and a bit mask.
See lpcBitIO and stmBitIO for details.
  • bitExistIO – test whether a bit exists
  • bitIntIO – effect an interrupt configuration of a bit or bits
  • bitQueryIO – query the state of a bit or bits
  • bitSetIO – effect an action on a bit or bits

I2C device

This carries out I2C bus I/O.
See lpcI2CIO and stmI2CIO for details.
  • i2cInitIO – initialize an I2C channel/bus
  • i2cIO – I2C general I/O function

System device

Core processor functions.
See lpcSysIO and stmSysIO for details.
  • sysFeedDogIO – feed the watchdog timer, if enabled
  • sysInitProcIO – initialize microcontroller processor
  • sysIRQIO – enable or disable an interrupt
  • sysPowerIO – enter a sleep or powerdown mode
  • sysQueryIO – query value of a board
  • sysSetIO – set an board value

UART device

This carries out UART serial I/O.
See lpcUARTIO for details.
  • uartGetcIO – get character from UART device
  • uartInitIO – initialize UART for I/O
  • uartPutcIO – send character to UART device

VCom device

This carries out serial I/O over a USB Virtual COM port. Note that USB support is held in a separate library.
See stmVCom (in library stmvcom) for details.
  • vcomGetcIO – get character from USB device
  • vcomInitIO – initialize USB for I/O
  • vcomPutcIO – send character to USB device
  • vcomStopIO – stop USB device

Microcontroller links

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-16 by mfc.