ros_alarms
- Stateful Alarm System¶
Stateful alarm system that allows for the immediate kill of a robotic machine.
This package implements a live alarm system, which requires that there is an alarm server consistently alive to field requests. This alarm server maintains the status of all of the robot’s alarms and handles requested get and set operations.
The ros_alarms.Alarm
class serves as the data structure used by the alarm
server to store data about individual alarms during its lifecycle. This class
should not be constructed by clients or other packages. However, this class
may be passed into callbacks registered with broadcasters or listeners.
Rather, other clients should interface with this library through the
ros_alarms.AlarmListener
or ros_alarms.AlarmBroadcaster
classes,
or the services provided by the alarm server. These classes wrap around the topics
published by the running alarm server to provide more useful Pythonic features.
- /alarm/get
Handles a string argument, the name of the alarm that is requested. Returns a stamped message containing the alarm information.
- /alarm/set
Handles an alarm argument that is used to overwrite the previous alarm information. This argument should contain all information relevant to the alarm.
Because you need to pass an entire alarm object, it is not recommended to use this service in other places. Instead, try using the
AlarmBroadcaster
class.
- /alarm/updates
Topic publishing any getting/setting updates that occur on alarms.
Python¶
Various Python classes have been built around making the alarm system easier to interface with between nodes.
For example, these classes can be used to immediately control alarms without the need to interface with topics or services:
>>> # Assume that the alarm_server node has been started
>>> from ros_alarms import Alarm, AlarmBroadcaster, AlarmListener
>>> broadcaster = AlarmBroadcaster("test-alarm")
>>> listener = AlarmListener("test-alarm")
>>> def callback(alarm: Alarm):
... print(f"An alarm with the name {alarm.alarm_name} was called.")
>>> listener.add_callback(callback, call_when_raised = True)
>>> broadcaster.raise_alarm()
An alarm with the name test-alarm was called.
Alarm¶
- clsAlarm.blank
- clsAlarm.from_msg
- defadd_callback
- defas_msg
- defas_srv_resp
- defupdate
- class ros_alarms.Alarm(alarm_name: str, raised: bool, node_name: str = 'unknown', problem_description: str = '', parameters: dict = {}, severity: int = 0)[source]¶
Pythonic representation of a ROS alarm.
This class should not be constructed by clients (excluding internal
ros_alarms
code, of course). This class is primarily used by the alarm server node to manage data about a series of alarms. However, this class may be passed into callbacks registered to particular alarms.- str(x)
Pretty prints the contents of the alarm. Equivalent to
repr(x)
.
- repr(x)
Pretty prints the contents of the alarm. Equivalent to
str(x)
.
- problem_description¶
A description of the problem related to the alarm. Defaults to an empty string.
- Type
- stamp¶
The time of the most recent update. Defaults to now if ROS has been initialized, otherwise zero.
- Type
rospy.Time
- raised_cbs¶
A list of callbacks to execute when the alarm is raised. Each callback should be associated with the severity required to execute the callback through a tuple.
- Type
List[Tuple[int, Callable]
- cleared_cbs¶
A list of callbacks to execute when the alarm is cleared. Each callback should be associated with the severity required to execute the callback through a tuple.
- Type
List[Tuple[int, Callable]
- add_callback(funct: Callable, call_when_raised: bool = True, call_when_cleared: bool = True, severity_required: tuple[int, int] = (0, 5))[source]¶
Adds a callback function to the alarm.
If the callback is set to be called when the alarm has been raised, and the alarm is already raised, then the callback is immediately called. Similarly, if the callback is set to run when the alarm is cleared, and the alarm is already cleared, then the callback is immediately ran. In both cases, the callback is registered like any other callback.
Exceptions in callbacks are swallowed and are printed out through a rospy logging statement.
- Parameters
funct (Callable) – The callback to add.
call_when_raised (bool) – Whether to call the callback when the alarm is raised. Defaults to
True
.call_when_cleared (bool) – Whether to call the callback when the alarm is cleared. Defaults to
True
.severity_required (Tuple[int, int]) – The severity required to run the callback. The tuple represents the minimum and maximum severities under which to execute the callback. Defaults to
(0, 5)
.
- as_msg() Alarm [source]¶
Get this alarm as an Alarm message.
- Returns
The constructed message.
- Return type
AlarmMsg
- as_srv_resp() AlarmGetResponse [source]¶
Get this alarm as an AlarmGet response.
- Returns
The constructed service response.
- Return type
- classmethod blank(name: str) Alarm [source]¶
Generate a general blank alarm that is cleared with a low severity.
- Parameters
name (str) – The name for the blank alarm.
- Returns
The constructed alarm.
- Return type
- classmethod from_msg(msg: Alarm) Alarm [source]¶
Generate an alarm object from an Alarm message.
- Parameters
msg (AlarmMsg) – The message to generate the object from.
- Returns
The constructed alarm.
- Return type
- update(srv: Alarm)[source]¶
Updates this alarm with a new AlarmSet request. Also will call any required callbacks.
- Parameters
srv (ros_alarms.Alarm) – The request to set the alarm.
AlarmServer¶
- defmake_tagged_alarm
- defset_alarm
- class ros_alarms.nodes.alarm_server.AlarmServer[source]¶
Server responsible for maintaining the status of alarms between all processes.
- alarms¶
A map from the alarm names to to the Alarm objects.
- Type
Dict[str, ros_alarms.Alarm]
- handlers¶
A map from the alarm names to their appropriate handlers.
- Type
Dict[str, HandlerBase]
- meta_alarms¶
A map from the meta alarm names to the Alarm objects.
- Type
Dict[str, ros_alarms.Alarm]
- make_tagged_alarm(name: str) Alarm [source]¶
Makes a blank alarm with the node_name of the alarm_server so that users know it is the initial state.
- set_alarm(alarm: Union[Alarm, Alarm]) bool [source]¶
Sets or updates the alarm.
Updating the alarm triggers all of the alarms callbacks, if any are set. The alarm becomes registered within the server and a message representing the alarm is published to the alarm publishing topic.
- Parameters
alarm (Union[ros_alarms.Alarm, ros_alarms.msg.Alarm]) – The alarm to set in the server.
- Returns
Whether the operation succeeded.
- Return type
AlarmBroadcaster¶
- defclear_alarm
- defraise_alarm
- defwait_for_server
- class ros_alarms.AlarmBroadcaster(name: str, node_name: str | None = None, nowarn: bool = False)[source]¶
Broadcasts information about an alarm, and allows for the raising and clearing of the alarm.
- Parameters
- clear_alarm(**kwargs)[source]¶
Clears the alarm.
- Parameters
kwargs – The associated keyword arguments, as described below.
- Keyword Arguments
node_name (str) – String that holds the name of the node making the request.
problem_description (str) – String with a description of the problem (defaults to empty string).
parameters (dict) – JSON dumpable dictionary with optional parameters that describe the alarm.
severity (int) – Integer in [0, 5] that indicates the severity of the alarm. (5 is most severe)
- Returns
Whether the alarm was successfully cleared.
- Return type
- raise_alarm(**kwargs)[source]¶
Raises the alarm.
- Parameters
kwargs – The associated keyword arguments, as described below.
- Keyword Arguments
node_name (str) – String that holds the name of the node making the request.
problem_description (str) – String with a description of the problem (defaults to empty string).
parameters (dict) – JSON dumpable dictionary with optional parameters that describe the alarm.
severity (int) – Integer in [0, 5] that indicates the severity of the alarm. (5 is most severe)
- Returns
Whether the alarm was successfully raised.
- Return type
- wait_for_server(timeout=None)[source]¶
- Wait for node to connect to alarm server. Waits timeout seconds (or forever
if
timeout
isNone
) to connect then fetches the current alarm and calls callbacks as needed.
Warning
User should always call this method before calling other methods.
- Parameters
timeout (Optional[float]) – The amount of seconds to wait before timing out.
AlarmListener¶
- defadd_callback
- defclear_callbacks
- defget_alarm
- defis_cleared
- defis_raised
- defwait_for_server
- class ros_alarms.AlarmListener(name: str, callback_funct: Callable | None = None, nowarn: bool = False, **kwargs)[source]¶
Listens to an alarm.
- Parameters
- add_callback(funct: Callable, call_when_raised: bool = True, call_when_cleared: bool = True, severity_required: tuple[int, int] = (0, 5))[source]¶
Adds a callback function to the alarm.
- Parameters
funct (Callable) – The callback to add.
call_when_raised (bool) – Whether to call the callback when the alarm is raised. Defaults to
True
.call_when_cleared (bool) – Whether to call the callback when the alarm is cleared. Defaults to
True
.severity_required (Tuple[int, int]) – The severity required to run the callback. The tuple represents the minimum and maximum severities under which to execute the callback. Defaults to
(0, 5)
.
- get_alarm(fetch: bool = True) AlarmGetResponse | None [source]¶
Returns the alarm message.
- Also worth noting, the alarm this method returns has it’s
parameters
field converted to a dictionary.
- Parameters
fetch (bool) – Whether to fetch the alarm from the server. If
False
, then uses the most recently cached alarm. Defaults toTrue
.- Returns
The response message, with its updated
parameters
field.- Return type
- Also worth noting, the alarm this method returns has it’s
- wait_for_server(timeout: float | None = None)[source]¶
- Wait for node to connect to alarm server. Waits timeout seconds (or forever
if
timeout
isNone
) to connect then fetches the current alarm and calls callbacks as needed.
Warning
User should always call this method before calling other methods.
- Parameters
timeout (Optional[float]) – The amount of seconds to wait before timing out.
HeartbeatMonitor¶
- class ros_alarms.HeartbeatMonitor(alarm_name: str, topic_name: str, msg_class, prd: float = 0.2, predicate: Callable | None = None, nowarn: bool = False, **kwargs)[source]¶
Used to trigger an alarm if a message on the topic
topic_name
isn’t published at least everyprd
seconds.An alarm won’t be triggered if no messages are initially received.
All of this class’ methods and attributes are internal.
HandlerBase¶
- defcleared
- defget_alarm
- defmeta_predicate
- defon_set
- defraised
- class ros_alarms.HandlerBase[source]¶
Listens for an alarm with this alarm_name. When that alarm is raised, self.raised will be called. When that alarm is cleared, self.cleared will be called. See the comments below for self.meta_predicate.
All alarm handlers must inherit from this base class in order to be registered.
- cleared(alarm: Alarm)[source]¶
Unless on_set is overridden, called whenever a node requests this alarm be cleared. If it returns False, this request is denied. Otherwise, the alarm is raised
- Parameters
alarm (ros_alarms.msg._Alarm.Alarm) – The new alarm a node had requested to replace the current with.
- property current_alarm: Optional[Alarm]¶
Returns the status of the alarm this handler is registered for.
- Returns
The current alarm instance, if it exists, otherwise
None
.- Return type
Optional[Alarm]
- get_alarm(name: str) Optional[Alarm] [source]¶
Gets the current status of an alarm.
- Returns
The request alarm object, or None if it has not been set.
- Return type
Optional[Alarm]
- meta_predicate(meta_alarm: Alarm, alarms) Union[bool, Alarm] [source]¶
Called on an update to one of this alarms’s meta alarms, if there are any. By default, returns True if any meta alarms are raised.
- Parameters
meta_alarm (ros_alarms.Alarm) – The alarm object of the meta alarm.
alarms (Dict[str, ros_alarms.Alarm]) – A dictionary mapping the name of each child alarm to its Alarm object.
- Returns
Returns a bool indicating if the alarm should be raised, or a new Alarm object which the calling alarm should update itself to.
- Return type
Union[bool, ros_alarms.Alarm]
- on_set(new_alarm: Alarm) Optional[bool] [source]¶
Called whenever a service request is made to the alarm server to the alarm this handler is registered for. Can be used to trigger actions before other nodes are notified of the change or to reject the change. By default, defers to the raised and cleared functions below.
- Parameters
new_alarm (ros_alarms.msg._Alarm.Alarm) – Alarm message that is requested to have this alarm change to.
- Returns
Either
None
, in which case the change is accepted orFalse
, in which case the alarm remains the same and the service request fails.- Return type
Optional[bool]
- raised(alarm: Alarm)[source]¶
Unless on_set is overridden, called whenever a node requests this alarm be raised. If it returns False, this request is denied. Otherwise, the alarm is raised.
- Parameters
alarm (ros_alarms.msg._Alarm.Alarm) – The new alarm a node had requested to replace the current with.
C++¶
AlarmProxy¶
- funcAlarmProxy
- funcAlarmProxy
- funcAlarmProxy
- funcAlarmProxy
- funcas_msg
- funcoperator==
- funcstr
-
struct AlarmProxy¶
Representation of a ROS alarm. Used by several other classes to facilitate proper interactions between components.
Public Functions
-
inline AlarmProxy()¶
The default class constructor. All parameters are empty or zero.
-
AlarmProxy(std::string alarm_name, bool raised, std::string node_name, std::string problem_description, std::string json_parameters, int severity)¶
A constructor which has parameters for all class parameters.
-
AlarmProxy(std::string alarm_name, bool raised, std::string problem_description, std::string json_parameters, int severity)¶
A constructor with parameters for all class attributes, except the node name, which is derived from the current node name (using
ros::this_node
).
-
AlarmProxy(ros_alarms_msgs::Alarm msg)¶
Constructs the class from a ROS message.
- Parameters
msg – The message to construct the class from.
-
ros_alarms_msgs::Alarm as_msg()¶
Converts the Alarm Proxy object to an :class:
Alarm
message.- Returns
The constructed message.
-
std::string str(bool full = false) const¶
Prints a readable representation of the class. Normally prints the alarm name, alarm status, and whether the alarm is raised or cleared. If raised, the severity is also printed.
The full representation also prints the node name, a problem description, and any related JSON parameters.
- Parameters
full – Whether to print the full description.
-
bool operator==(const AlarmProxy &other) const¶
Overloaded equality operator. Returns true if both alarms share the same name, raised status, node name, problem description, and status.
- Parameters
other – The other alarm.
Public Members
-
std::string alarm_name¶
The alarm name.
-
bool raised = false¶
Whether the alarm has been raised by some service.
-
std::string node_name¶
The name of the node connected to the alarm.
-
std::string problem_description¶
The description of the problem associated with the alarm.
-
std::string json_parameters¶
The JSON parameters associated with the alarm.
-
int severity = 0¶
-
inline AlarmProxy()¶
AlarmBroadcaster¶
- funcAlarmBroadcaster
- funcclear
- funcgetAlarm
- funcpublish
- funcraise
- funcupdateSeverity
-
class AlarmBroadcaster¶
Facilitates operations on an alarm, such as raising or clearing an alarm.
Public Functions
-
AlarmBroadcaster(ros::NodeHandle &nh, AlarmProxy *alarm = nullptr)¶
Constructs a broadcaster with an internally controlled (default) or externally controlled AlarmProxy.
- Parameters
nh – The node handle to associate with the broadcaster.
alarm – The alarm proxy.
-
inline void clear()¶
Clears the alarm, and publishes the change to the server.
-
inline void raise()¶
Raises the alarm, and publishes the change to the server.
-
inline void updateSeverity(int sev)¶
Updates the severity associated with an alarm, and raises the alarm. This function should not be used to update the alarm severity to zero.
- Parameters
sev – The new severity.
-
bool publish()¶
Publishes current state of the AlarmProxy to the server. If the publication encountered an error, a ROS warning is sent alongside returning
false
.- Returns
The success of the publication.
-
inline AlarmProxy &getAlarm()¶
Returns the alarm proxy associated with the broadcaster.
Warning: If the class uses an externally modified alarm proxy, then modifying this class could have reprocussions for other services which rely on that alarm proxy.
- Returns
The proxy.
-
AlarmBroadcaster(ros::NodeHandle &nh, AlarmProxy *alarm = nullptr)¶
AlarmListener¶
- funcAlarmListener
- funcaddCb
- funcaddClearCb
- funcaddRaiseCb
- funcaddRaiseCb
- funcaddRaiseCb
- funcclearCallbacks
- funcgetAlarm
- funcgetCachedAlarm
- funcgetLastUpdateTime
- funcgetNumConnections
- funcgetTimeSinceUpdate
- funcisCleared
- funcisRaised
- funcok
- funcqueryCleared
- funcqueryRaised
- funcstart
- funcstop
- funcwaitForConnection
- funcwaitForUpdate
-
template<typename callable_t = std::function<void(AlarmProxy)>>
class AlarmListener¶ Listens to a specific ROS alarm using AlarmProxy.
Public Functions
-
AlarmListener(ros::NodeHandle &nh, std::string alarm_name)¶
Default constructor.
- Parameters
nh – The node handle.
alarm_name – The name of the alarm connected to the listener.
-
inline bool ok() const¶
Return the status of the listener.
- Returns
Whether the listener is operating OK.
-
inline int getNumConnections()¶
Get the number of publishers connected to the ROS node.
- Returns
The number of connections.
-
bool waitForConnection(ros::Duration timeout = {-1.0})¶
Waits for a connection to be established, and returns true if a connection was established.
Waits for a connection to connect to the subscriber as a publisher.
- Parameters
timeout – The amount of time (in seconds) before the function exits and returns false. Default time is -1 seconds, in which the function will never return false.
timeout – The amount of time before the function returns
false
.
- Returns
Whether a connection was established.
- Returns
Whether a connection has been established.
-
inline void start()¶
Starts the async spinner.
-
inline void stop()¶
Stops the async spinner.
-
inline bool isRaised() const¶
Returns a cached value of whether the alarm has been raised. Avoids querying the server by using the cache.
- Returns
Whether the alarm has been raised, according to the cache.
-
inline bool isCleared() const¶
Returns a cached value of whether the alarm is cleared. Does not query the alarm server.
- Returns
Whether the alarm is cleared, according to the cache.
-
inline bool queryRaised()¶
Queries the alarm server to see if an alarm with this name has been raised.
- Returns
Whether the found alarm was raised.
-
inline bool queryCleared()¶
Queries the alarm server to see if this alarm has been cleared.
- Returns
Whether this alarm was cleared, according to the alarm server.
-
AlarmProxy getAlarm()¶
Queries the alarm server for an alarm of the given name.
- Returns
The found alarm with the given name.
-
inline AlarmProxy getCachedAlarm()¶
Returns the most recently cached alarm returned from the alarm server. Avoids a query by using a cache.
- Returns
The most recently cached alarm.
-
void addCb(callable_t cb)¶
Registers a callback to be invoked on both raise and clear.
- Parameters
cb – The callback function.
-
void addRaiseCb(callable_t cb)¶
Registers a callback to be invoked for any severity level.
- Parameters
cb – The callback function.
-
void addRaiseCb(callable_t cb, int severity)¶
Registers a callback to be invoked for a single severity level.
- Parameters
cb – The callback function.
severity – The severity level to execute the callback for.
-
void addRaiseCb(callable_t cb, int severity_lo, int severity_hi)¶
Registers a callback to be invoked for a range of severity levels.
- Parameters
cb – The callback function.
severity_lo – The lowest severity level to execute the callback for.
severity_hi – The highest severity level to execute the callback for.
-
void addClearCb(callable_t cb)¶
Registers a callback to be invoked when an alarm is cleared.
- Parameters
cb – The callback function.
-
inline ros::Time getLastUpdateTime() const¶
Returns the last time the alarm was updated.
- Returns
The most recent update time.
-
inline ros::Duration getTimeSinceUpdate() const¶
Returns the amount of time since the alarm was updated.
- Returns
The length of time since the alarm was updated.
-
bool waitForUpdate(ros::Duration timeout = ros::Duration(-1.0)) const¶
Returns true if a new update occurs before the function times out. If the function times out, returns false.
- Returns
Whether the update occurred.
-
inline void clearCallbacks()¶
Clears all callback associated with the listener.
-
AlarmListener(ros::NodeHandle &nh, std::string alarm_name)¶
ListenerCb¶
- funcoperator()
- funcseverity_check
-
template<typename callable_t = std::function<void(AlarmProxy)>>
struct ListenerCb¶ A callback associated with the Alarm Listener class. Helps to manage callbacks by regulating their execution based on the current severity level and desired calling behavior.
Public Types
Public Functions
-
inline bool severity_check(int severity)¶
Checks the severity of the alarm to determine whether the callback should be executed. The severity should be between the lowest and highest severity levels.
- Returns
Whether to execute the callback based on severity.
-
inline void operator()(ros_alarms_msgs::Alarm msg)¶
Overloads the
()
operator to execute the callback function only if the specified conditions are met.
Public Members
-
callable_t cb_func¶
The specific callback function.
-
int severity_hi = 5¶
The highest severity under which the callback can be called.
-
int severity_lo = 0¶
The lowest severity under which the callback can be called.
-
CallScenario call_scenario = CallScenario::always¶
The scenario under which the callback is executed.
-
inline bool severity_check(int severity)¶
Subjugator-specific¶
BusVoltage¶
- class alarm_handlers.BusVoltage[source]¶
Alarm used to monitor the voltage of the bus.
- alarm_name¶
The name of the alarm. For all alarms of this type, this is set equal to
bus-voltage
.- Type
- raised(alarm: Alarm) None [source]¶
If the severity of the raised alarm is 3, then an indication is raised to all logged-in users about a low bus voltage. If the raised alarm severity is 5, then a message is displayed to all logged-in users about the bus being killed due to low voltage.
- Parameters
alarm (ros_alarms.Alarm) – The raised alarm.
HeightOverBottom¶
- class alarm_handlers.HeightOverBottom[source]¶
Alarm (inheriting from
ros_alarms.HandlerBase
) which monitors the height of the sub in the water. If too low, then an alarm is triggered. When the sub rises above the limit again, the alarm is cleared.The height to kill at is obtained from Dynamic Reconfigure, or is assumed to be
0.4
. The height of the sub is checked at 2Hz.- cleared(alarm: Alarm) None [source]¶
Triggers when the alarm is cleared. Sets the state of the alarm monitor to
- Parameters
alarm (ros_alarms.Alarm) – The alarm which was cleared.
- raised(alarm: Alarm) None [source]¶
Triggers when the alarm is raised. Sets the state of the alarm monitor to represent that the alarm was killed.
- Parameters
alarm (ros_alarms.Alarm) – The alarm which was raised.
HwKill¶
- class alarm_handlers.HwKill[source]¶
Alarm (inheriting from
ros_alarms.HandlerBase
) to represent that the sub experienced a hardware kill.
Kill¶
- defbagger_dump
- defcleared
- defraised
- defset_mobo_kill
- class alarm_handlers.Kill[source]¶
Generic kill used to represent the state of an alarm. Uses a threading condition to manage access
- condition¶
The threading condition used to manage the shared access to the motherboard.
- Type
- HARDWARE_KILL_GRACE_PERIOD_SECONDS¶
The number of seconds to wait for the hardware kill to be removed after asking for it to be removed. If the kill has not been removed within this amount of time, the motherboard kill is reinstated. Set to
6 seconds
.- Type
- cleared(alarm: Alarm)[source]¶
Called when the alarm is cleared. Attempts to use ~.condition to unset the motherboard kill. If the motherboard kill can’t be deactivated, then it is reinstated and a warning is logged.
- Parameters
alarm (ros_alarms.Alarm) – The alarm which was cleared.
- raised(alarm: Alarm) None [source]¶
Called when the alarm is raised. Sets the motherboard kill and attempts to dump the related logging info to a bag file, using the
condition
. At the end of the use of the condition, the condition is notified.- Parameters
alarm (ros_alarms.Alarm) – The alarm which was raised.
NetworkLoss¶
OdomKill¶
- defcheck
- defcheck_continuity
- defclear_kill
- defcleared
- defneed_kill
- defraised
- class alarm_handlers.OdomKill(timeout=0.5)[source]¶
Will kill the sub when it stops hearing odometry messages or when there is a large discontinuity in state estimation. Only meant to run on the sub as a safety measure.
- GRACE_PERIOD¶
The amount of time to wait after the class comes alive. Used in case odometry disappears just when the class is started. Defaults to
5 seconds
.- Type
rospy.Duration
- TIMEOUT¶
The amount of time to wait before an error is logged. Defaults to
0.5 seconds
.- Type
rospy.Duration
- MAX_JUMP¶
The amount of meters that the sub is allowed to jump before an error is logged. Defaults to
0.5 meters
.- Type
- LAUNCH_TIME¶
When the class was started. Used to calculate when the grace period ends.
- Type
rospy.Time
- ab¶
The alarm broadcaster for the node, with a name of
odom-kill
.
- check(*args)[source]¶
Checks to see if an alarm needs to be raised. Raises either an alarm describing that state estimation is not available (if the sub was just started) or that a significant amount of state estimation was lost since the sub was started.
- check_continuity(new_odom_msg: Odometry)[source]¶
Checks the continuity of the odom system. Calculates the difference (in meters) between the current odom message and the previous message. If the sub moved more than
0.5 meters
, a discontinuity is reported.- Parameters
new_odom_msg (Odometry) – The new odometry message to which the old will be compared to.
- clear_kill(alarm: Alarm)[source]¶
Clears the kill imposed on the class.
- Parameters
alarm (ros_alarms.Alarm) – The alarm which is used to determine if a clear needs to occur.
ThrusterOut¶
- defcleared
- defraised
- defupdate_layout
- class alarm_handlers.ThrusterOut[source]¶
Alarm class to indicate that some of the thrusters in the thruster layout are offline.
- cleared(alarm: Alarm)[source]¶
Called when the alarm is cleared. Attempts to update the thruster layout with
update_layout()
.
- raised(alarm: Alarm)[source]¶
Called when the alarm is raised. Attempts to update the thruster layout with
update_layout()
.