ALDiagnosis

Overview | API


What it does

ALDiagnosis module allows the robot to detect if there is a hardware trouble (mainly electrical connection).

Passive diagnosis

The passive diagnosis is running all the time without perturbing the robot behavior.

The main goal of the passive diagnosis is to check every device of the robot and to publish whether the device has or has not an error. A device is an actuator or a sensor. For further details, see: NAO - Actuator & Sensor list.

Active diagnosis

The active diagnosis runs at NAOqi start-up, ALMotionProxy::wakeUp() and ALMotionProxy::rest() without perturbing the robot behavior.

The purpose of the active diagnosis is to verify if every device of the robot is functional and to publish whether the device has or has not an error.

If a failure is detected:

  • If the severity level requires it, ALMotion module reacts in order to protect the robot and the user. For further details about the motion diagnosis reflexes, see: Diagnosis effect.
  • In SERIOUS or CRITICAL severity level, a notification is sent. For further details, see: Event and state notifications.

How it works

The ALDiagnosis module is automatically started with naoqi.

Passive diagnosis

Then, the passive diagnosis is launched. It’s a thread at 20ms that will deduce if the device has an error based on these questions:

  • The electronic board that supports the sensor or the actuator answers or not?
  • Is there a critical error detected on an actuator (over temperature, the position sensor answer...)?

Based on these results, ALMemory error keys are updated for each device, the key format is:

Diagnosis/Passive/DeviceName/Error.

A summary of the passive diagnosis is available using ALDiagnosisProxy::getPassiveDiagnosis()

Active diagnosis

During ALMotionProxy::wakeUp() and/or ALMotionProxy::rest(), some tests are running.

ALMemory error keys are updated for each device, the key format is:

Diagnosis/Active/DeviceName/Error.

A summary of the active diagnosis is available using ALDiagnosisProxy::getActiveDiagnosis()

For further details see error key NAO - Actuator & Sensor list.

If a device is in failure mode and depends on his Level of failure severity, a notification is send:

Severity Notification
0: NEGLIGIBLE No notification.
1: SERIOUS Warning notification.
2: CRITICAL Error notification.

For further details, see: Diagnosis - NAO.

Active Diagnosis tests

nao NAO & juju Pepper

  Test Suite Test Name What it does
Motion LimitsTest_”JointName MotionHalLimitError Verify if joint software limits are the same in Motion and HAL. If not this is a software error.
PositionTests_”JointName SensorCommandError Check motor command/sensor position error Detect if the motor is defective.
Vision AnyCameraTests_CameraName GetImage Try to get an image from camera.
DataChanged Check if data from camera change.

juju Pepper only

  Test Suite Test Name What it does
Sensor WheelName“SensorTest WheelSensorTest Check command/sensor velocity error. Detect if the wheel is defective.
SensorName “BlockedTestSuite SensorBlockedStatusTest Verify if metrical sensor data changed. Detect if the sensor is defective.
InertialSensorTest InertialSensorTest Check the inertial sensor calibration.
GyrometerSensorTest GyrometerSensorTest Check the gyrometer sensor calibration.
Brake”JointNameWithBrake“Tests BrakeBlocked Check command/sensor position and current error to determine if the brake is defective.

Performance and Limitations

Performance

The module takes around 0.2% of CPU.

Limitations

Warning

Make sure people does not touch the robot during a wake up; otherwise the Active diagnosis may return false positive results.

If an electrical connection is unstable, the module sends several notifications. To disable the notification use: ALDiagnosisProxy::setEnableNotification()