Apps     Components     Interfaces     All Files     Source Tree     source: tos.interfaces.Leds.nc

Interface: Leds

Abstraction of the LEDs.
Author: Jason Hill
  David Gay
  Philip Levis

Components providing this interface:
tos.lib.Commands.CommandLeds
tos.system.LedsC
tos.system.NoLeds

Components requiring this interface:
apps.Blink.BlinkM
apps.BlinkTask.BlinkTaskM
apps.Bombilla.AMPromiscuous
apps.GenericBase.GenericBaseM
apps.HighFrequencySampling.HFSM
apps.Ident.AppM
apps.Ident.IdentC
apps.MicaHWVerify.MicaHWVerifyM
apps.Oscilloscope.OscilloscopeM
apps.OscilloscopeRF.OscilloscopeM
apps.SecureTOSBase.SecureTOSBaseM
apps.Sense.SenseM
apps.SenseLightToLog.SenseLightToLogM
apps.SenseLightToLog.SimpleCmdM
apps.SenseTask.SenseTaskM
apps.SimpleCmd.SimpleCmdM
apps.Surge.SurgeM
apps.TASKApp.Field
apps.TOSBase.TOSBaseM
apps.TestEEPROM.Byte.TestByteEEPROMC
apps.TestEEPROM.ByteSpeed.ETimingM
apps.TestEEPROM.EEPROM.TestEEPROMM
apps.TestEEPROM.Page.TestEEPROMM
apps.TestSnooze.TestSnoozeM
apps.TestTinyAlloc.TestTinyAllocM
apps.TestTinySec.TestTinySecM
apps.TestUart.TestUartM
apps.TransparentBase.TOSBaseM
tos.lib.Attributes.AttrMicM
tos.lib.Commands.CommandLedsM
tos.lib.Commands.CommandPotM
tos.lib.Commands.CommandResetM
tos.lib.Counters.IntToLedsM
tos.lib.FS.Remote
tos.lib.Queue.QueuedSendM
tos.lib.TinyDB.AggOperator
tos.lib.TinyDB.DBBufferC
tos.lib.TinyDB.NetworkMultiHopM
tos.lib.TinyDB.ParsedQuery
tos.lib.TinyDB.QueryResult
tos.lib.TinyDB.SimpleTimeM
tos.lib.TinyDB.TupleRouterM
tos.lib.TinySec.TinySecM
tos.lib.Util.TinyAlloc
tos.lib.Util.UartDebuggerM
tos.lib.VM.components.BombillaEngineM
tos.lib.VM.opcodes.OPputledM
tos.platform.mica.ByteEEPROMC
tos.platform.mica.MicaHighSpeedRadioTinySecM
tos.platform.mica.PageEEPROMM
tos.platform.mica.RadioPacketTinySecM
tos.sensorboards.micasb.I2CPotM
tos.system.AMPromiscuous
tos.system.NoCRCPacket
tos.system.SimpleTimeM
tos.system.TimerM

Commands

Commands - Details

init

result_t init(void)

Initialize the LEDs; among other things, initialization turns them all off.
Returns: SUCCESS always.

redOn

result_t redOn(void)

Turn the red LED on.
Returns: SUCCESS always.

redOff

result_t redOff(void)

Turn the red LED off.
Returns: SUCCESS always.

redToggle

result_t redToggle(void)

Toggle the red LED. If it was on, turn it off. If it was off, turn it on.
Returns: SUCCESS always.

greenOn

result_t greenOn(void)

Turn the green LED on.
Returns: SUCCESS always.

greenOff

result_t greenOff(void)

Turn the green LED off.
Returns: SUCCESS always.

greenToggle

result_t greenToggle(void)

Toggle the green LED. If it was on, turn it off. If it was off, turn it on.
Returns: SUCCESS always.

yellowOn

result_t yellowOn(void)

Turn the yellow LED on.
Returns: SUCCESS always.

yellowOff

result_t yellowOff(void)

Turn the yellow LED off.
Returns: SUCCESS always.

yellowToggle

result_t yellowToggle(void)

Toggle the yellow LED. If it was on, turn it off. If it was off, turn it on.
Returns: SUCCESS always.