主にオムニです。

Dependencies:   EC mbed HCSR04

Fork of asimawari by yuto kawamura

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers atai.h Source File

atai.h

00001 
00002 
00003 //前進の方向の定義
00004 double fai=60;//φ
00005 //個体差で出力調整
00006 double power_set=0.4;
00007 double power[3];
00008 double M[3];
00009 double MAX;
00010 double max();
00011 double x;
00012 double y;
00013 double X;
00014 double Y;
00015 int i;
00016 int j;
00017 //ジョイスティック入力値の偏角
00018 double sita;
00019 //関数代入用の角度調整
00020 double sita_2;
00021 
00022 //モーターのクラス
00023 PwmOut motor[3][2]= {PwmOut(p21),PwmOut(p22),
00024                      PwmOut(p23),PwmOut(p24),
00025                      PwmOut(p25),PwmOut(p26)
00026                     };
00027 
00028 //モーターの初期設定
00029 void setting()
00030 {
00031     for(i=0; i<=2; i++) {
00032         power[i]=power_set;
00033     }
00034     for(i=0; i<=2; i++) {
00035         for(j=0; j<=2; i++) {
00036             motor[i][j].period_us(100);
00037         }
00038     }
00039 }
00040 
00041 float attach_timing=0.05f;
00042 
00043