2022_Ateam_MOTORprogramをscrp_slaveでメインマイコンからコントローラー状況を読み取れるように改良。 また、モータに0以外のpwmが送られている場合に基盤付属のledが点灯するようにした。
Dependencies: SBDBT arrc_mbed BNO055
TARGETco.hpp
- Committer:
- guesta
- Date:
- 2022-04-08
- Revision:
- 13:369f4abc1f36
- Parent:
- 1:ea880e226e5a
File content as of revision 13:369f4abc1f36:
#ifndef TARGET_CO_H #define TARGET_CO_H #include "mbed.h" #include "math.h" #define PI 3.1415926535897 class TARGETco{ public: void pass_val(double XPOWER,double YPOWER,double THETA); void pass_target(double TARGET); double obt_target1(); double obt_target2(); double obt_target3(); double obt_target4(); private: void cal_angular(); double theta; double Xpower,Ypower; double Xvelocity,Yvelocity; double target[4]; }; #endif