TinyOS is an embedded, component-based
operating system
An operating system (OS) is system software that manages computer hardware and software resources, and provides common daemon (computing), services for computer programs.
Time-sharing operating systems scheduler (computing), schedule tasks for ...
and platform for low-power wireless devices, such as those used in
wireless sensor network
Wireless sensor networks (WSNs) refer to networks of spatially dispersed and dedicated sensors that monitor and record the physical conditions of the environment and forward the collected data to a central location. WSNs can measure environmental ...
s (WSNs),
smartdust
Smartdust is a system of many tiny microelectromechanical systems (MEMS) such as sensors, robots, or other devices, that can detect, for example, light, temperature, vibration, magnetism, or chemicals. They are usually operated on a computer networ ...
,
ubiquitous computing
Ubiquitous computing (or "ubicomp") is a concept in software engineering, hardware engineering and computer science where computing is made to appear seamlessly anytime and everywhere. In contrast to desktop computing, ubiquitous computing imp ...
,
personal area network
A personal area network (PAN) is a computer network for interconnecting electronic devices within an individual person's workspace. A PAN provides data transmission among devices such as computers, smartphones, tablets and personal digital assi ...
s,
building automation
Building automation (BAS), also known as building management system (BMS) or building energy management system (BEMS), is the automatic centralized control of a building's HVAC, HVAC (heating, ventilation and air conditioning), electrical, light ...
, and
smart meter
A smart meter is an electronic device that records information—such as consumption of electric energy, voltage levels, current, and power factor—and communicates the information to the consumer and electricity suppliers. Advanced meterin ...
s. It is written in the
programming language
A programming language is a system of notation for writing computer programs.
Programming languages are described in terms of their Syntax (programming languages), syntax (form) and semantics (computer science), semantics (meaning), usually def ...
nesC, as a set of cooperating tasks and processes. It began as a collaboration between the
University of California, Berkeley
The University of California, Berkeley (UC Berkeley, Berkeley, Cal, or California), is a Public university, public Land-grant university, land-grant research university in Berkeley, California, United States. Founded in 1868 and named after t ...
,
Intel Research, and
Crossbow Technology
Crossbow Technology, Inc. (also referred to as XBOW) was a California-based company that specialized in navigation products, including gyroscopes and guidance, navigation, and control units.
History
Crossbow was founded by Mike A. Horton in ...
, was released as
free and open-source software
Free and open-source software (FOSS) is software available under a license that grants users the right to use, modify, and distribute the software modified or not to everyone free of charge. FOSS is an inclusive umbrella term encompassing free ...
under a
BSD license
BSD licenses are a family of permissive free software licenses, imposing minimal restrictions on the use and distribution of covered software. This is in contrast to copyleft licenses, which have share-alike requirements. The original BSD lic ...
, and has since grown into an international consortium, the
TinyOS Alliance
TinyOS is an embedded, component-based operating system and platform for low-power wireless devices, such as those used in wireless sensor networks (WSNs), smartdust, ubiquitous computing, personal area networks, building automation, and smart me ...
.
TinyOS has been used in space, being implemented in
ESTCube-1.
Implementation
TinyOS applications are written in the programming language
nesC, a dialect of the
C language
C (''pronounced'' '' – like the letter c'') is a general-purpose programming language. It was created in the 1970s by Dennis Ritchie and remains very widely used and influential. By design, C's features cleanly reflect the capabilities o ...
optimized for the memory limits of sensor networks.
Its supplementary tools are mainly in the form of
Java
Java is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea (a part of Pacific Ocean) to the north. With a population of 156.9 million people (including Madura) in mid 2024, proje ...
and
shell script
A shell script is a computer program designed to be run by a Unix shell, a command-line interpreter. The various dialects of shell scripts are considered to be command languages. Typical operations performed by shell scripts include file manipu ...
front-ends. Associated libraries and tools, such as the nesC compiler and
Atmel AVR
AVR is a family of microcontrollers developed since 1996 by Atmel, acquired by Microchip Technology in 2016. They are 8-bit RISC single-chip microcontrollers based on a modified Harvard architecture. AVR was one of the first microcontroller ...
binutils toolchains, are mostly written in C.
TinyOS programs are built of
software components
Component-based software engineering (CBSE), also called component-based development (CBD), is a style of software engineering that aims to construct a software system from components that are loosely-coupled and reusable. This emphasizes the sep ...
, some of which present hardware abstractions. Components are connected to each other using
interfaces
Interface or interfacing may refer to:
Academic journals
* ''Interface'' (journal), by the Electrochemical Society
* '' Interface, Journal of Applied Linguistics'', now merged with ''ITL International Journal of Applied Linguistics''
* '' Inter ...
. TinyOS provides interfaces and components for common abstractions such as packet communication, routing, sensing, actuation and storage.
TinyOS is fully
non-blocking: it has one
call stack
In computer science, a call stack is a Stack (abstract data type), stack data structure that stores information about the active subroutines and block (programming), inline blocks of a computer program. This type of stack is also known as an exe ...
. Thus, all
input/output
In computing, input/output (I/O, i/o, or informally io or IO) is the communication between an information processing system, such as a computer, and the outside world, such as another computer system, peripherals, or a human operator. Inputs a ...
(I/O) operations that last longer than a few hundred
microsecond
A microsecond is a unit of time in the International System of Units (SI) equal to one millionth (0.000001 or 10−6 or ) of a second. Its symbol is μs, sometimes simplified to us when Unicode is not available.
A microsecond is to one second, ...
s are asynchronous and have a
callback
Callback may refer to:
* Callback (comedy), a joke which refers to one previously told
* Callback (computer programming), callable (i.e. function) that is passed as data and expected to be called by another callable.
* Callback (telecommunication ...
. To enable the native
compiler
In computing, a compiler is a computer program that Translator (computing), translates computer code written in one programming language (the ''source'' language) into another language (the ''target'' language). The name "compiler" is primaril ...
to better optimize across call boundaries, TinyOS uses nesC's features to link these callbacks, called events, statically. While being non-blocking enables TinyOS to maintain high concurrency with one stack, it forces programmers to write complex logic by stitching together many small event handlers. To support larger computations, TinyOS provides tasks, which are similar to a
Deferred Procedure Call
A Deferred Procedure Call (DPC) is a Microsoft Windows operating system mechanism which allows high-priority tasks (e.g. an interrupt handler) to defer required but lower-priority tasks for later execution. This permits device drivers and other l ...
and
interrupt handler
In computer systems programming, an interrupt handler, also known as an interrupt service routine (ISR), is a special block of code associated with a specific interrupt condition. Interrupt handlers are initiated by hardware interrupts, software ...
bottom halves. A TinyOS component can post a task, which the OS will schedule to run later. Tasks are non-
preemptive and run in
first in, first out order. This simple
concurrency
Concurrent means happening at the same time. Concurrency, concurrent, or concurrence may refer to:
Law
* Concurrence, in jurisprudence, the need to prove both ''actus reus'' and ''mens rea''
* Concurring opinion (also called a "concurrence"), a ...
model is typically sufficient for I/O centric applications, but its difficulty with CPU-heavy applications has led to developing a
thread library for the OS, named TOSThreads. TOSThreads are unmaintained and have been deprecated.
TinyOS code is statically linked with program code and is compiled into a small binary, using a custom
GNU toolchain
The GNU toolchain is a broad collection of programming tools produced by the GNU Project. These tools form a toolchain (a suite of tools used in a serial manner) used for developing software applications and operating systems.
The GNU toolchain pl ...
. Associated utilities are provided to complete a development platform for working with TinyOS.
History
TinyOS began as a project at UC Berkeley as part of the
DARPA
The Defense Advanced Research Projects Agency (DARPA) is a research and development agency of the United States Department of Defense responsible for the development of emerging technologies for use by the military. Originally known as the Adva ...
NEST program. It has since grown to involve thousands of academic and commercial developers and users worldwide. (list in reverse chronological order)
* August 2012: TinyOS 2.1.2 released
* April 2010: TinyOS 2.1.1 released.
* August 2008: TinyOS 2.1.0 released.
* July 2007: TinyOS 2.0.2 released. Work on TinyOS 2.1, which involves slight changes to a few interfaces, begins.
* April 2007: TinyOS 2.0.1 released at the 4th TinyOS Technology Exchange in Cambridge, MA.
* November 2006: TinyOS 2.0 released at the SenSys conference in Boulder, CO.
* July 2006: TinyOS 2.0 beta2 released.
* February 2006: TinyOS 2.0 beta1 released at the 3rd TinyOS Technology Exchange in Stanford, CA.
* December 2005: TinyOS 1.1.15, the last 1.1 version, is released.
* July 2005: NEST project concludes.
* June 2004: Working group forms on next steps for TinyOS, based on experiences porting to new platforms. Group agrees to start work on 2.0.
* September 2003 – December 2005: TinyOS begins a periodic minor release process.
* August 2003: TinyOS version 1.1 is released, which includes new nesC features including data race detection.
* September 2002: TinyOS version 1.0, implemented in nesC, is released.
* April 2002: Work on the nesC programming language begins as a collaboration between Intel Research and UC Berkeley.
* February 2002: Berkeley distributes 1000 mica nodes to other participants in the NEST project.
* 2001: Berkeley develops the mica platform and releases TinyOS version 0.6.
* 2000: Berkeley designs the rene platform and partners with Crossbow, Inc., who mass-produces the hardware. TinyOS version 0.43 is made available to the public via SourceForge. Pre-1.0 versions of TinyOS are a mix of C and
Perl
Perl is a high-level, general-purpose, interpreted, dynamic programming language. Though Perl is not officially an acronym, there are various backronyms in use, including "Practical Extraction and Reporting Language".
Perl was developed ...
scripts.
* 1999: First TinyOS platform (WeC) and OS implementations are developed at Berkeley.
Integrated development environments
As of 2010, three
integrated development environment
An integrated development environment (IDE) is a Application software, software application that provides comprehensive facilities for software development. An IDE normally consists of at least a source-code editor, build automation tools, an ...
s (IDEs) are available for TinyOS, as
plug-ins for
Eclipse
An eclipse is an astronomical event which occurs when an astronomical object or spacecraft is temporarily obscured, by passing into the shadow of another body or by having another body pass between it and the viewer. This alignment of three ...
:
* ''YETI 2'', ETH Zürich (development stopped)
* ''XPairtise'' by Rasmus Pedersen, Copenhagen Business School
* ''TinyDT'', Vanderbilt University
References
External links
TinyOS on GitHub{{Wireless Sensor Network
Embedded operating systems
Software using the BSD license