![](/media/cache/group/default_image.jpg.50x50_q85.jpg)
Use IQS62X sensor and move motor by detected angle
Dependencies: DRV8830 IQS62x IQSDisplayTerminal UIT_ACM1602NI mbed
Fork of Nucleo_ACM1602_I2C_DC by
Diff: MotorMove.h
- Revision:
- 8:f7ad1d7176ba
- Child:
- 9:b58e7d72a91c
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/MotorMove.h Sat Sep 30 16:43:51 2017 +0000 @@ -0,0 +1,31 @@ +#include "mbed.h" +//#include "DRV8830.h" + + +#define ACCEL_SIZE 6 +#define DECEL_SIZE 6 +#define LIMIT_TIME 30 + +class MotorMove{ + + public: + //DRV8830 motor; //Motor + float vol_decel[DECEL_SIZE]; + float vol_accel[ACCEL_SIZE]; + float down_ratio; + + + + void up_motor_set (int time_counter, int speed); + void down_motor_set (int time_counter, int speed); + float ReturnMotorVol(int time_counter, int sw_flag1,int sw_flag2); + + private: + int start_time_count; + float Voltage; + + int bflag_up; + int bflag_down; + }; + + \ No newline at end of file