📄 countsleepm.nc
字号:
// $Id: CountSleepM.nc,v 1.1 2004/05/29 21:07:17 jpolastre Exp $// @author Cory Sharp <cssharp@eecs.berkeley.edu>includes CountMsg;includes Timer;module CountSleepM{ provides interface StdControl; uses interface Timer; uses interface Leds; uses interface PowerManagement; uses command result_t Enable();}implementation{ command result_t StdControl.init() { call Leds.init(); return SUCCESS; } command result_t StdControl.start() { call Enable(); call Timer.start( TIMER_REPEAT, 50 ); call PowerManagement.adjustPower(); return SUCCESS; } command result_t StdControl.stop() { return SUCCESS; } event result_t Timer.fired() { call Leds.redToggle(); call PowerManagement.adjustPower(); return SUCCESS; }}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -