Public Member Functions | |
def | __init__ |
def | init_dio |
Static Public Attributes | |
string | HAND_L = '1' |
string | HAND_R = '2' |
Private Member Functions | |
def | _dio_writer |
Private Attributes | |
_parent | |
Static Private Attributes | |
int | _DIO_ASSIGN_OFF = 0 |
int | _DIO_ASSIGN_ON = 1 |
int | _DIO_MASK = 0 |
This class provides methods that are generic for the hands of Kawada Industries' dual-arm robot called Nextage Open. DIO pin numbers are set in nextage_ros_bridge.abs_hand_command.AbsractHandCommand
Definition at line 40 of file base_hands.py.
def nextage_ros_bridge.base_hands.BaseHands.__init__ | ( | self, | |
parent | |||
) |
Since this class operates requires an access to hrpsys.hrpsys_config.HrpsysConfigurator, valid 'parent' is a must. Otherwise __init__ returns without doing anything. @type parent: hrpsys.hrpsys_config.HrpsysConfigurator @param parent: derived class of HrpsysConfigurator.
Reimplemented in nextage_ros_bridge.iros13_hands.Iros13Hands, and nextage_ros_bridge.base_toolchanger_hands.BaseToolchangerHands.
Definition at line 61 of file base_hands.py.
def nextage_ros_bridge.base_hands.BaseHands._dio_writer | ( | self, | |
digitalout_indices, | |||
dio_assignments, | |||
padding = _DIO_ASSIGN_OFF |
|||
) | [private] |
This private method calls HrpsysConfigurator.writeDigitalOutputWithMask, which this class expects to be available via self._parent. According to the current (Oct 2013) hardware spec, numbering rule differs regarding 0 (numeric figure) in dout and mask as follows: * 0 is "OFF" in the digital output. * 2/1/2014 Assignment modified 0:ON --> 0:OFF * 0 is "masked" and not used in mask. Since using '0' is defined in hrpsys and not in the robots side, we'll always use '0' for masking. @type digitalout_indices: int[] @param digitalout_indices: Array of indices of digital output that NEED to be flagged as 1. eg. If you're targetting on 25 and 26th places in the DIO array but only 25th is 1, then the array becomes [24]. @type dio_assignments: int[] @param dio_assignments: range(32). Also called as "masking bits" or just "mask". This number corresponds to the assigned digital pin of the robot. eg. If the target pins are 25 and 26, dio_assignments = [24, 25] @param padding: Either 0 or 1. DIO bit array will be populated with this value. Usually this method assumes to be called when turning something "on". Therefore by default this value is ON.
Definition at line 74 of file base_hands.py.
def nextage_ros_bridge.base_hands.BaseHands.init_dio | ( | self | ) |
Initialize dio. All channels will be set '0' (off), EXCEPT for tool changers (channel 19 and 24) so that attached tools won't fall.
Definition at line 158 of file base_hands.py.
int nextage_ros_bridge::base_hands.BaseHands::_DIO_ASSIGN_OFF = 0 [static, private] |
Definition at line 56 of file base_hands.py.
int nextage_ros_bridge::base_hands.BaseHands::_DIO_ASSIGN_ON = 1 [static, private] |
Definition at line 55 of file base_hands.py.
int nextage_ros_bridge::base_hands.BaseHands::_DIO_MASK = 0 [static, private] |
Definition at line 57 of file base_hands.py.
Reimplemented in nextage_ros_bridge.base_toolchanger_hands.BaseToolchangerHands.
Definition at line 68 of file base_hands.py.
string nextage_ros_bridge::base_hands.BaseHands::HAND_L = '1' [static] |
Reimplemented in nextage_ros_bridge.base_toolchanger_hands.BaseToolchangerHands.
Definition at line 52 of file base_hands.py.
string nextage_ros_bridge::base_hands.BaseHands::HAND_R = '2' [static] |
Reimplemented in nextage_ros_bridge.base_toolchanger_hands.BaseToolchangerHands.
Definition at line 53 of file base_hands.py.