Class: Sphero::Request::SetPowerNotification

Inherits:
Sphero::Request show all
Defined in:
lib/sphero/request.rb

Constant Summary

Constants inherited from Sphero::Request

ACCELEROMETER_AXIS_X_FILTERED, ACCELEROMETER_AXIS_X_RAW, ACCELEROMETER_AXIS_Y_FILTERED, ACCELEROMETER_AXIS_Y_RAW, ACCELEROMETER_AXIS_Z_FILTERED, ACCELEROMETER_AXIS_Z_RAW, ACCELONE, GYRO_AXIS_H_FILTERED, GYRO_AXIS_L_FILTERED, GYRO_AXIS_M_FILTERED, GYRO_AXIS_X_FILTERED, GYRO_AXIS_X_RAW, GYRO_AXIS_Y_FILTERED, GYRO_AXIS_Y_RAW, GYRO_AXIS_Z_FILTERED, GYRO_AXIS_Z_RAW, GetAutoReconnect, GetBluetoothInfo, GetPowerState, GetRGB, GetVersioning, IMU_PITCH_ANGLE_FILTERED, IMU_ROLL_ANGLE_FILTERED, IMU_YAW_ANGLE_FILTERED, LEFT_MOTOR_BACK_EMF_FILTERED, LEFT_MOTOR_BACK_EMF_RAW, MAGNETOMETER_AXIS_X_FILTERED, MAGNETOMETER_AXIS_X_RAW, MAGNETOMETER_AXIS_Y_FILTERED, MAGNETOMETER_AXIS_Y_RAW, MAGNETOMETER_AXIS_Z_FILTERED, MAGNETOMETER_AXIS_Z_RAW, ODOMETER_X, ODOMETER_Y, Ping, QUATERNION_Q0, QUATERNION_Q1, QUATERNION_Q2, QUATERNION_Q3, RIGHT_MOTOR_BACK_EMF_FILTERED, RIGHT_MOTOR_BACK_EMF_RAW, SOP1, SOP2, SetAutoReconnect, SetBackLEDOutput, SetRGB, SetRotationRate, VELOCITY_X, VELOCITY_Y

Instance Attribute Summary

Attributes inherited from Sphero::Request

#data, #seq

Instance Method Summary collapse

Methods inherited from Sphero::Request

#bytes, #checksum, #dlen, #header, make_command, #packet_body, #packet_header, #response, #to_str

Constructor Details

#initialize(seq, enable) ⇒ SetPowerNotification

Returns a new instance of SetPowerNotification.



130
131
132
133
# File 'lib/sphero/request.rb', line 130

def initialize seq, enable
  super(seq, [enable])
  @cid = 0x21
end