Francisco Guerra
/
SymbitronValves
Amplitude Modulation Code
Fork of SymbitronValves by
Diff: main.cpp
- Revision:
- 8:89be5a6807f0
- Parent:
- 7:9f6dfd88cd18
--- a/main.cpp Fri Jul 03 12:59:11 2015 +0000 +++ b/main.cpp Thu Jan 14 16:07:39 2016 +0000 @@ -40,11 +40,11 @@ { static uint16_t usbcounter = 0; float meas = getPressure_Pa(); - setpoint1= ain_setpoint.read()*50000; - if(setpoint1 - meas >2000) { + setpoint1= ain_setpoint.read()*60000; + if(setpoint1 - meas >2500) { v1close = 0; v1open = 1; - } else if (meas - setpoint1 > 2000) { + } else if (meas - setpoint1 > 2500) { v1close = 1; v1open = 0; } else