ジャパンオープン用のLPC824専用プログラム
Dependencies: mbed-src Ping SDFileSystem
Diff: main/format.cpp
- Revision:
- 7:22d0c4a400c4
- Parent:
- 6:80c2f4fce2eb
--- a/main/format.cpp Thu Mar 03 05:24:45 2016 +0000 +++ b/main/format.cpp Thu Mar 10 14:11:08 2016 +0000 @@ -135,15 +135,15 @@ uint16_t ave_buff_long2[LONG_AVE]; uint32_t ave_sum_long; uint32_t ave_sum_long2; - uint16_t ir_val_long_plus; - uint16_t ir_val_long_plus2; + //uint16_t ir_val_long_plus; + //uint16_t ir_val_long_plus2; static uint8_t const ch_num[3]={8, 8, 4}; static uint16_t const ir_dis_range[2][8]={ - {0, 2000, 2250, 2500, 2600, 2700, 3000, 3900, },//IR_SHORT 0 - {0, 1000, 1100, 1200, 1300, 1500, 1800, 2000, },//IR_LONG 1 + {0, 2000, 2250, 2500, 2600, 2700, 3000, 3500, },//IR_SHORT 0 + {0, 1000, 1100, 1200, 1300, 1500, 1700, 1900, },//IR_LONG 1 }; @@ -209,7 +209,7 @@ } ave_buff_long[0] = ir_val_long[7]; - ir_val_long_plus = ir_val_long[7]; + //ir_val_long_plus = ir_val_long[7]; ir_val_long[7] = ave_sum_long/LONG_AVE; //移動平均2 @@ -220,7 +220,7 @@ } ave_buff_long2[0] = ir_val_long[0]; - ir_val_long_plus2 = ir_val_long[0]; + //ir_val_long_plus2 = ir_val_long[0]; ir_val_long[0] = ave_sum_long2/LONG_AVE; @@ -342,7 +342,7 @@ pc.printf("Diff_long:%d\t", ir_val_diff[IR_LONG]);//検出した最大値と最小値の差(遠) pc.printf("ir_val_phase[IR_SHORT]:%d\t", ir_val_phase[IR_SHORT]);//判定されたボールの距離の段階(遠) pc.printf("ir_val_phase[IR_LONG]:%d\t", ir_val_phase[IR_LONG]);//判定されたボールの距離の段階(遠) - //pc.printf("notice:%d\t", ir_notice);//判定されたボールの状況 + pc.printf("notice:%d\t", ir_notice);//判定されたボールの状況 pc.printf("ir_place:%d\t", ir_place);