2019NHK_teamA / Mbed 2 deprecated 2019_Test_Arm

Dependencies:   mbed QEI

Committer:
st17099ng
Date:
Thu Sep 05 08:31:37 2019 +0000
Revision:
0:d2abd75a6e2a
2019NHK_ArmTest_program

Who changed what in which revision?

UserRevisionLine numberNew contents of line
st17099ng 0:d2abd75a6e2a 1 #ifndef Help_H
st17099ng 0:d2abd75a6e2a 2 #define Help_H
st17099ng 0:d2abd75a6e2a 3 #include "mbed.h"
st17099ng 0:d2abd75a6e2a 4
st17099ng 0:d2abd75a6e2a 5 #define nDuty10 0x74
st17099ng 0:d2abd75a6e2a 6 #define nDuty20 0x66
st17099ng 0:d2abd75a6e2a 7 #define nDuty25 0x60
st17099ng 0:d2abd75a6e2a 8 #define nDuty30 0x59
st17099ng 0:d2abd75a6e2a 9 #define nDuty40 0x4C
st17099ng 0:d2abd75a6e2a 10 #define nDuty50 0x40
st17099ng 0:d2abd75a6e2a 11 #define nDuty60 0x33
st17099ng 0:d2abd75a6e2a 12 #define nDuty70 0x26
st17099ng 0:d2abd75a6e2a 13 #define nDuty75 0x20
st17099ng 0:d2abd75a6e2a 14 #define nDuty85 0x13
st17099ng 0:d2abd75a6e2a 15 #define nDuty80 0x19
st17099ng 0:d2abd75a6e2a 16 #define nDuty90 0x0C
st17099ng 0:d2abd75a6e2a 17 #define nDuty95 0x00
st17099ng 0:d2abd75a6e2a 18
st17099ng 0:d2abd75a6e2a 19 #define pDuty10 0x8C
st17099ng 0:d2abd75a6e2a 20 #define pDuty20 0x99
st17099ng 0:d2abd75a6e2a 21 #define pDuty25 0x9F
st17099ng 0:d2abd75a6e2a 22 #define pDuty30 0xA6
st17099ng 0:d2abd75a6e2a 23 #define pDuty40 0xB3
st17099ng 0:d2abd75a6e2a 24 #define pDuty50 0xC0
st17099ng 0:d2abd75a6e2a 25 #define pDuty60 0xCD
st17099ng 0:d2abd75a6e2a 26 #define pDuty70 0xD9
st17099ng 0:d2abd75a6e2a 27 #define pDuty75 0xE0
st17099ng 0:d2abd75a6e2a 28 #define pDuty80 0xE6
st17099ng 0:d2abd75a6e2a 29 #define pDuty85 0xEC
st17099ng 0:d2abd75a6e2a 30 #define pDuty90 0xF3
st17099ng 0:d2abd75a6e2a 31 #define pDuty95 0xFF
st17099ng 0:d2abd75a6e2a 32
st17099ng 0:d2abd75a6e2a 33 #define SBREAK 0x80
st17099ng 0:d2abd75a6e2a 34 #define TRANSIT 0x30
st17099ng 0:d2abd75a6e2a 35
st17099ng 0:d2abd75a6e2a 36 #define Rf_add 0x10
st17099ng 0:d2abd75a6e2a 37 #define Rb_add 0x12
st17099ng 0:d2abd75a6e2a 38 #define Lf_add 0x14
st17099ng 0:d2abd75a6e2a 39 #define Lb_add 0x16
st17099ng 0:d2abd75a6e2a 40 #define Arm_add 0x18
st17099ng 0:d2abd75a6e2a 41 #define Dp_add 0x20
st17099ng 0:d2abd75a6e2a 42 #define Rst_add 0x22
st17099ng 0:d2abd75a6e2a 43 #define Lst_add 0x24
st17099ng 0:d2abd75a6e2a 44 #define Fan_add 0x26
st17099ng 0:d2abd75a6e2a 45
st17099ng 0:d2abd75a6e2a 46 #define cir 0
st17099ng 0:d2abd75a6e2a 47 #define tri 1
st17099ng 0:d2abd75a6e2a 48 #define squ 2
st17099ng 0:d2abd75a6e2a 49 #define cro 3
st17099ng 0:d2abd75a6e2a 50 #define up 4
st17099ng 0:d2abd75a6e2a 51 #define dow 5
st17099ng 0:d2abd75a6e2a 52 #define rig 6
st17099ng 0:d2abd75a6e2a 53 #define lef 7
st17099ng 0:d2abd75a6e2a 54 #define r1 8
st17099ng 0:d2abd75a6e2a 55 #define r2 9
st17099ng 0:d2abd75a6e2a 56 #define l1 10
st17099ng 0:d2abd75a6e2a 57 #define l2 11
st17099ng 0:d2abd75a6e2a 58 #define low 1
st17099ng 0:d2abd75a6e2a 59 #define fast 3
st17099ng 0:d2abd75a6e2a 60
st17099ng 0:d2abd75a6e2a 61 #define pri pc.printf
st17099ng 0:d2abd75a6e2a 62
st17099ng 0:d2abd75a6e2a 63 void set_gpio(void);
st17099ng 0:d2abd75a6e2a 64 void get_stick(int *axis,char mode);
st17099ng 0:d2abd75a6e2a 65 bool get_but(int butnum);
st17099ng 0:d2abd75a6e2a 66 void set_speed(int *pspeed);
st17099ng 0:d2abd75a6e2a 67 void set_direct(int *direct);
st17099ng 0:d2abd75a6e2a 68 void set_emg(void);
st17099ng 0:d2abd75a6e2a 69 void set_tire(char *fmot,char *bmot,int direct, char mode, int speed);
st17099ng 0:d2abd75a6e2a 70 void set_slide(char *Rfmot,char *Lfmot,char *Rbmot,char *Lbmot, int but1,int but2, int speed);
st17099ng 0:d2abd75a6e2a 71 void set_mot(char *mot,int num1,int num2);
st17099ng 0:d2abd75a6e2a 72 void set_arm(char *mot,int num, int pulse);
st17099ng 0:d2abd75a6e2a 73 void set_drop(char *mot,int num1, int num2);
st17099ng 0:d2abd75a6e2a 74 void set_sheet(char *mot, char mode,int num1, int num2);
st17099ng 0:d2abd75a6e2a 75 void write_data(char address,char data);
st17099ng 0:d2abd75a6e2a 76 static int Raxis[2],Laxis[2];
st17099ng 0:d2abd75a6e2a 77
st17099ng 0:d2abd75a6e2a 78 #endif