基本クラス
Dependents: 300_PS3com Quadrifoglio_PS3COM
Master.cpp
00001 #include "Master.h" 00002 00003 Master::Master() : 00004 pc(USBTX, USBRX, 115200) 00005 ,shot(Pin_Kicker) 00006 ,drib(Pin_Dribbler) 00007 { 00008 motor[0] = new KohiMD(Pin_motor_0); 00009 motor[1] = new KohiMD(Pin_motor_1); 00010 motor[2] = new KohiMD(Pin_motor_2); 00011 motor[3] = new KohiMD(Pin_motor_3); 00012 shot.setkickperiod(Kicker_Period); 00013 shot.setoutputtime(Kicker_OutPutTime); 00014 drib.setspeed(0.0); 00015 } 00016 00017 void Master::Shot() 00018 { 00019 shot.outPut(); 00020 } 00021 00022 void Master::Dribble(float power) 00023 { 00024 drib.setspeed(power); 00025 } 00026 00027 void Master::SetValueMotor(int num, double val) 00028 { 00029 motor[num]->setSpeed(val); 00030 }
Generated on Thu Aug 18 2022 01:18:45 by
1.7.2