|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.microedition.midlet.MIDlet
frog.plugin.spot.onspot.FrogSpot
public class FrogSpot
Main class for FROG interaction using a Sun SPOT. Provides access to all SunSPOT facilities and sets up all the Managers.
AccelManager,
FilterManager,
ConnectionManager| Field Summary | |
|---|---|
(package private) static LIS3L02AQAccelerometer |
accel
|
(package private) static byte |
ACCEL_FAILURE
Status light |
protected AccelManager |
accelManager
|
protected ConnectionManager |
conn
|
(package private) static byte |
CONNECTED
Status light |
(package private) static byte |
DISCOVER_FAILURE
Status light |
(package private) static EDemoBoard |
e
|
protected FilterManager |
filter
|
(package private) static byte |
FILTER_FAILURE
Status light |
(package private) static byte |
FINDING_HOST
Status light |
(package private) static ITriColorLED[] |
leds
|
(package private) static byte |
RECEIVE_FAILURE
Status light |
(package private) static IRadioPolicyManager |
rpm
|
(package private) static byte |
SEND_FAILURE
Status light |
(package private) static ISpot |
spot
|
(package private) static ISwitch |
sw1
|
(package private) static ISwitch |
sw2
|
(package private) static IAT91_TC |
timer
|
(package private) static byte |
TURN_OFF
Status light |
(package private) static byte |
WATCHER_FAILURE
Status light |
| Fields inherited from interface frog.plugin.spot.Frog_Spot_Constants |
|---|
CORRUPT_DATA, END_OF_DATA, INT_CORRUPT_DATA, INT_END_OF_DATA, MSG_ACK, MSG_ADD_FILTER, MSG_ALIVE, MSG_DISCONNECT, MSG_DISCOVER, MSG_END_OF_DATA, MSG_ERROR, MSG_GESTURE, MSG_REMOVE_FILTERS, MSG_RESEND, MSG_SAMPLE_RATE, PORT_BCAST, PORT_MAX, PORT_REPLY, PORT_START, SPOT1, SPOT1_PORT, SPOT2, SPOT2_PORT, SPOT3, SPOT3_PORT, SPOT4, SPOT4_PORT, SPOT5, SPOT5_PORT, SPOT6, SPOT6_PORT, SPOT7, SPOT7_PORT, SPOT8, SPOT8_PORT, SPOTB1, SPOTB1_PORT, SPOTB2, SPOTB2_PORT, SPOTB3, SPOTB3_PORT, SPOTB4, SPOTB4_PORT |
| Constructor Summary | |
|---|---|
FrogSpot()
FrogSpot is constructed from the main method of the Squawk VM. |
|
| Method Summary | |
|---|---|
protected void |
destroyApp(boolean unconditional)
Called by the Squawk VM when the reset button is pressed. |
(package private) static void |
enableLights(byte status)
Sets the LEDs on the SPOT to a given status code. |
protected void |
pauseApp()
Deprecated. Never called. Not used by the Squawk VM. |
void |
shutdown()
Silently catches any exceptions from destroyApp(boolean) and
reboots the SPOT. |
protected void |
startApp()
Squawk VM starts execution here. |
void |
switchPressed(ISwitch sw2)
Reboots the Sun SPOT. |
void |
switchReleased(ISwitch sw2)
Deprecated. unused |
| Methods inherited from class javax.microedition.midlet.MIDlet |
|---|
getAppProperty, notifyDestroyed, notifyPaused, resumeRequest |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
static final EDemoBoard e
static final LIS3L02AQAccelerometer accel
static final ITriColorLED[] leds
static final ISpot spot
static final IRadioPolicyManager rpm
static final ISwitch sw1
static final ISwitch sw2
static final IAT91_TC timer
static final byte TURN_OFF
static final byte FINDING_HOST
static final byte CONNECTED
static final byte DISCOVER_FAILURE
static final byte ACCEL_FAILURE
static final byte FILTER_FAILURE
static final byte SEND_FAILURE
static final byte RECEIVE_FAILURE
static final byte WATCHER_FAILURE
protected final AccelManager accelManager
protected final FilterManager filter
protected final ConnectionManager conn
| Constructor Detail |
|---|
public FrogSpot()
throws Throwable
Throwable - if anything goes wrong setting up this MIDlet| Method Detail |
|---|
protected void destroyApp(boolean unconditional)
throws MIDletStateChangeException
destroyApp in class MIDletunconditional - unused
MIDletStateChangeExceptionprotected void pauseApp()
pauseApp in class MIDletpublic void shutdown()
destroyApp(boolean) and
reboots the SPOT.
protected void startApp()
throws MIDletStateChangeException
startApp in class MIDletMIDletStateChangeExceptionpublic void switchPressed(ISwitch sw2)
switchPressed in interface ISwitchListenersw2 - the SPOT's "Switch 2"public void switchReleased(ISwitch sw2)
switchReleased in interface ISwitchListenerstatic void enableLights(byte status)
status - a given status byte such as FINDING_HOST or JOIN_FAILURE
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||