Tekkotsu Homepage
Demos
Overview
Downloads
Dev. Resources
Reference
Credits

PowerSrcID Namespace Reference

holds source ID types for power events; see EventBase, see PowerSourceID_t More...

Enumerations

enum  PowerSourceID_t {
  PauseSID = 0, MotorPowerSID, VibrationSID, BatteryEmptySID,
  LowPowerWarnSID, BatteryFullSID, ExternalPowerSID, ExternalPortSID,
  BatteryConnectSID, BatteryInitSID, DischargingSID, ChargingSID,
  OverheatingSID, PowerGoodSID, ChargerStatusSID, SuspendedSID,
  OverChargedSID, TermDischargeSID, TermChargeSID, ErrorSID,
  StationConnectSID, BatteryOverCurrentSID, DataFromStationSID, RegisterUpdateSID,
  RTCSID, SpecialModeSID, BMNDebugModeSID, PlungerSID,
  UpdatedSID, NumPowerSIDs
}
 

holds source ID types for power events

More...

Detailed Description

holds source ID types for power events; see EventBase, see PowerSourceID_t


Enumeration Type Documentation

holds source ID types for power events

Also serve as offsets into WorldState::powerFlags[].

I've never seen a lot of these events thrown by the OS. 'NS' means never-seen, which could simply be because i haven't put it in that situation (don't have a station-type power charger) or because the OS doesn't actually support sending that flag.

Under normal conditions, you'll see MotorPowerSID, BatteryConnectSID, DischargingSID, and PowerGoodSID always active with occasional VibrationSID and UpdateSID. When the chest button is pushed, PauseSID is activated and MotorPowerSID is deactivated.

The BatteryMonitorBehavior will give a warning once power begins getting low. The OS won't boot off a battery with less than 15% power remaining (which is when the LowPowerWarnSID is thrown)

Note:
there's not a one-to-one correspondance of the events from the OPENR power system... i map several OPENR events to fewer Tekkotsu events, check the event's name if you want to know the specific source (say if low battery is low current and/or low voltage) Status ETIDS are only generated when one of a related group goes on/off but others are still active
Enumerator:
PauseSID 

the chest button was pushed (this is not a normal button, it kills power to the motors in hardware)

MotorPowerSID 

active while the motors have power

VibrationSID 

triggered when the OS decides a large acceleration has occured, like falling down (or more specifically, hitting the ground afterward)

BatteryEmptySID 

battery is dead

LowPowerWarnSID 

triggered when sensors[PowerRemainOffset] <= 0.15 (PowerGoodSID stays on)

BatteryFullSID 

battery is full

ExternalPowerSID 

receiving power from an external source (such as AC cable, may or may not include the "station", see StationConnectSID)

ExternalPortSID 

an external power source is plugged in (does not imply current is flowing however)

BatteryConnectSID 

a battery is plugged in

BatteryInitSID 

? NS

DischargingSID 

using power from the battery (although still stays on after hooked up to external power)

ChargingSID 

you used to be able to charge while running, tho that has changed in more recent versions of OPEN-R. In any case, I never saw this even when it did work.

OverheatingSID 

in case the robot starts getting too hot NS

PowerGoodSID 

there is power, either from external or battery

ChargerStatusSID 

? NS

SuspendedSID 

? NS

OverChargedSID 

in case the charger screws up somehow (?) NS

TermDischargeSID 

end of battery (?) NS

TermChargeSID 

end of charging (?) NS

ErrorSID 

general power error NS

StationConnectSID 

connected to a station NS

BatteryOverCurrentSID 

similar to OverChargedSID (?) NS

DataFromStationSID 

? NS

RegisterUpdateSID 

? NS

RTCSID 

? NS

SpecialModeSID 

? NS

BMNDebugModeSID 

? NS

PlungerSID 

I think this is in reference to having a memorystick (?) NS.

UpdatedSID 

sent as last event after processing a frame

NumPowerSIDs 

Definition at line 63 of file WorldState.h.


Tekkotsu v5.1CVS
Generated Mon May 9 04:59:25 2016 by Doxygen 1.6.3