public Joints GetJointsOfType(JointType jointType) { Joints joints = new Joints(); foreach (Joint joint in this) { if (joint.JointType == jointType) { joints.Add(joint); } } return(joints); }
public void LoadJointProfiles() { // RBakerFlag -> TEST CODE! PinMapping cw = new PinMapping(9, "clockwise"); PinMapping ccw = new PinMapping(10, "anti-clockwise"); arduinoSerialPort.ComponentMappings.Add(cw); arduinoSerialPort.ComponentMappings.Add(ccw); cw.SetPinMode(SetPinModeStateCodes.OutputStateCode); ccw.SetPinMode(SetPinModeStateCodes.OutputStateCode); Joint joint = new Joint(cw, ccw, JointType.ElbowRight); joints.Add(joint); }