another thing is when i simulate it the pwm works only 30% duty cycle whatever the voltage is
This code
Code:
Vp = (Vp */ 500)>>2 'Equates to: (Vp * 500)/1024
LCDOut $fe,$c0 ,"Pressure = ",DEC (Vp/100),".", DEC2 Vp," volt" 'Display Voltage out of pressure sensor on second line
Divides Vp by 100 to display volts. So this line for example
Code:
if Vp<3 then 'Voltage From Pressure Sensor is Less than preset value (3 volt)
should be
Code:
if Vp<300 then 'Voltage From Pressure Sensor is Less than preset value (3 volt)
Bookmarks