せとうちオープン用のメインプログラム
Dependencies: mbed AQM1602 HMC6352 PID
setting/extern.h@0:b910276f9da2, 2016-05-01 (annotated)
- Committer:
- lilac0112_1
- Date:
- Sun May 01 06:30:37 2016 +0000
- Revision:
- 0:b910276f9da2
from 2v10
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
lilac0112_1 | 0:b910276f9da2 | 1 | #ifndef _EXTERN_H_ |
lilac0112_1 | 0:b910276f9da2 | 2 | #define _EXTERN_H_ |
lilac0112_1 | 0:b910276f9da2 | 3 | |
lilac0112_1 | 0:b910276f9da2 | 4 | #include "def.h" |
lilac0112_1 | 0:b910276f9da2 | 5 | |
lilac0112_1 | 0:b910276f9da2 | 6 | /*追加ライブラリ*/ |
lilac0112_1 | 0:b910276f9da2 | 7 | #include <sstream> |
lilac0112_1 | 0:b910276f9da2 | 8 | #include "math.h" |
lilac0112_1 | 0:b910276f9da2 | 9 | #include "AQM1602.h" |
lilac0112_1 | 0:b910276f9da2 | 10 | #include "HMC6352.h" |
lilac0112_1 | 0:b910276f9da2 | 11 | #include "PID.h" |
lilac0112_1 | 0:b910276f9da2 | 12 | |
lilac0112_1 | 0:b910276f9da2 | 13 | #include "adns_9800.h" |
lilac0112_1 | 0:b910276f9da2 | 14 | #include "txrx.h" |
lilac0112_1 | 0:b910276f9da2 | 15 | #include "switch.h" |
lilac0112_1 | 0:b910276f9da2 | 16 | #include "wordString2.h" |
lilac0112_1 | 0:b910276f9da2 | 17 | #include "IrConfig.h" |
lilac0112_1 | 0:b910276f9da2 | 18 | #include "LineConfig.h" |
lilac0112_1 | 0:b910276f9da2 | 19 | |
lilac0112_1 | 0:b910276f9da2 | 20 | #include "setup.h" |
lilac0112_1 | 0:b910276f9da2 | 21 | #include "command.h" |
lilac0112_1 | 0:b910276f9da2 | 22 | #include "command_functions.h" |
lilac0112_1 | 0:b910276f9da2 | 23 | #include "active.h" |
lilac0112_1 | 0:b910276f9da2 | 24 | #include "input.h" |
lilac0112_1 | 0:b910276f9da2 | 25 | #include "output.h" |
lilac0112_1 | 0:b910276f9da2 | 26 | #include "LineProcess.h" |
lilac0112_1 | 0:b910276f9da2 | 27 | #include "strategy.h" |
lilac0112_1 | 0:b910276f9da2 | 28 | #include "strategy2.h" |
lilac0112_1 | 0:b910276f9da2 | 29 | #include "old_strategy.h" |
lilac0112_1 | 0:b910276f9da2 | 30 | |
lilac0112_1 | 0:b910276f9da2 | 31 | #include "PinConfig.h" |
lilac0112_1 | 0:b910276f9da2 | 32 | #include "CommandConfig.h" |
lilac0112_1 | 0:b910276f9da2 | 33 | #include "ActiveConfig.h" |
lilac0112_1 | 0:b910276f9da2 | 34 | #include "MathTable.h" |
lilac0112_1 | 0:b910276f9da2 | 35 | /*クラス*/ |
lilac0112_1 | 0:b910276f9da2 | 36 | |
lilac0112_1 | 0:b910276f9da2 | 37 | //pc(Computer) |
lilac0112_1 | 0:b910276f9da2 | 38 | extern RawSerial pc; |
lilac0112_1 | 0:b910276f9da2 | 39 | //led(main) |
lilac0112_1 | 0:b910276f9da2 | 40 | //extern DigitalOut LED[4]; |
lilac0112_1 | 0:b910276f9da2 | 41 | extern BusOut LED; |
lilac0112_1 | 0:b910276f9da2 | 42 | //line(bottom) |
lilac0112_1 | 0:b910276f9da2 | 43 | extern BusOut LineKeeper; |
lilac0112_1 | 0:b910276f9da2 | 44 | extern BusIn LineRaw; |
lilac0112_1 | 0:b910276f9da2 | 45 | extern BusIn LineHold; |
lilac0112_1 | 0:b910276f9da2 | 46 | extern InterruptIn Line[3]; |
lilac0112_1 | 0:b910276f9da2 | 47 | extern InterruptIn LineHolding[3]; |
lilac0112_1 | 0:b910276f9da2 | 48 | //ballcheck(bottom) |
lilac0112_1 | 0:b910276f9da2 | 49 | extern InterruptIn BallChecker; |
lilac0112_1 | 0:b910276f9da2 | 50 | extern AnalogIn BallCheckerA; |
lilac0112_1 | 0:b910276f9da2 | 51 | //debug_switch(debug_board) |
lilac0112_1 | 0:b910276f9da2 | 52 | extern DigitalIn Sw[4]; |
lilac0112_1 | 0:b910276f9da2 | 53 | //motor(main) |
lilac0112_1 | 0:b910276f9da2 | 54 | extern Serial motor; |
lilac0112_1 | 0:b910276f9da2 | 55 | //spi(main) |
lilac0112_1 | 0:b910276f9da2 | 56 | extern SPI spi; |
lilac0112_1 | 0:b910276f9da2 | 57 | extern DigitalOut spi_ss[4]; |
lilac0112_1 | 0:b910276f9da2 | 58 | //bluetooth(debug_board) |
lilac0112_1 | 0:b910276f9da2 | 59 | extern RawSerial RN42; |
lilac0112_1 | 0:b910276f9da2 | 60 | extern DigitalOut hmc_reset; |
lilac0112_1 | 0:b910276f9da2 | 61 | //lcd(debug_board) |
lilac0112_1 | 0:b910276f9da2 | 62 | extern AQM1602 Lcd; |
lilac0112_1 | 0:b910276f9da2 | 63 | //cmps |
lilac0112_1 | 0:b910276f9da2 | 64 | extern HMC6352 hmc; |
lilac0112_1 | 0:b910276f9da2 | 65 | //mouse(bottom) |
lilac0112_1 | 0:b910276f9da2 | 66 | extern adns_9800 mouse_sensor; |
lilac0112_1 | 0:b910276f9da2 | 67 | //solenoid(bottom) |
lilac0112_1 | 0:b910276f9da2 | 68 | extern DigitalOut kicker; |
lilac0112_1 | 0:b910276f9da2 | 69 | |
lilac0112_1 | 0:b910276f9da2 | 70 | //Serial for motors |
lilac0112_1 | 0:b910276f9da2 | 71 | extern int speed[4]; |
lilac0112_1 | 0:b910276f9da2 | 72 | extern string StringFIN; |
lilac0112_1 | 0:b910276f9da2 | 73 | //PID |
lilac0112_1 | 0:b910276f9da2 | 74 | extern PID pid; |
lilac0112_1 | 0:b910276f9da2 | 75 | extern Ticker pidupdate; |
lilac0112_1 | 0:b910276f9da2 | 76 | //for Serial |
lilac0112_1 | 0:b910276f9da2 | 77 | extern volatile uint8_t INdata[DATA_NUM], EXdata[DATA_NUM]; |
lilac0112_1 | 0:b910276f9da2 | 78 | //for DataSet |
lilac0112_1 | 0:b910276f9da2 | 79 | //extern Record data; |
lilac0112_1 | 0:b910276f9da2 | 80 | //NewStruct |
lilac0112_1 | 0:b910276f9da2 | 81 | extern CompassVal cmps_set; |
lilac0112_1 | 0:b910276f9da2 | 82 | extern SensorVal data; |
lilac0112_1 | 0:b910276f9da2 | 83 | extern SystemVal sys; |
lilac0112_1 | 0:b910276f9da2 | 84 | //for transition |
lilac0112_1 | 0:b910276f9da2 | 85 | extern Ticker Sw_ticker; |
lilac0112_1 | 0:b910276f9da2 | 86 | extern Timeout button; |
lilac0112_1 | 0:b910276f9da2 | 87 | extern bool state[4]; |
lilac0112_1 | 0:b910276f9da2 | 88 | extern uint8_t statesum, last_statesum; |
lilac0112_1 | 0:b910276f9da2 | 89 | // for Time |
lilac0112_1 | 0:b910276f9da2 | 90 | extern Ticker Motor_ticker; |
lilac0112_1 | 0:b910276f9da2 | 91 | //extern Ticker Line_ticker; |
lilac0112_1 | 0:b910276f9da2 | 92 | extern Ticker Info_ticker; |
lilac0112_1 | 0:b910276f9da2 | 93 | //extern Ticker Hmc_ticker; |
lilac0112_1 | 0:b910276f9da2 | 94 | |
lilac0112_1 | 0:b910276f9da2 | 95 | //extern Timeout Line_timeout[3]; |
lilac0112_1 | 0:b910276f9da2 | 96 | extern Timeout Line_reset; |
lilac0112_1 | 0:b910276f9da2 | 97 | |
lilac0112_1 | 0:b910276f9da2 | 98 | extern Timeout Solenoid_timeout; |
lilac0112_1 | 0:b910276f9da2 | 99 | extern Timeout Kick_stop; |
lilac0112_1 | 0:b910276f9da2 | 100 | |
lilac0112_1 | 0:b910276f9da2 | 101 | extern Timeout Turn_timeout; |
lilac0112_1 | 0:b910276f9da2 | 102 | extern Timeout Turn_stop; |
lilac0112_1 | 0:b910276f9da2 | 103 | |
lilac0112_1 | 0:b910276f9da2 | 104 | extern Timeout Ball_judge; |
lilac0112_1 | 0:b910276f9da2 | 105 | |
lilac0112_1 | 0:b910276f9da2 | 106 | //extern Timeout Kick_now; |
lilac0112_1 | 0:b910276f9da2 | 107 | //extern Timeout Front_now; |
lilac0112_1 | 0:b910276f9da2 | 108 | //extern Timeout Line_home; |
lilac0112_1 | 0:b910276f9da2 | 109 | |
lilac0112_1 | 0:b910276f9da2 | 110 | extern Ticker Duty[DUTY_NUM]; |
lilac0112_1 | 0:b910276f9da2 | 111 | extern Timeout Stp; |
lilac0112_1 | 0:b910276f9da2 | 112 | extern double dutycycle[DUTY_NUM]; |
lilac0112_1 | 0:b910276f9da2 | 113 | |
lilac0112_1 | 0:b910276f9da2 | 114 | #endif /*_EXTERN_H_*/ |