You are on page 1of 2

$regfile =

m8535.dat

$crystal = 12000000 inisialisasi adc Config Adc = Single , Prescaler = Auto inisialisasi lcd Config Lcdpin = Pin , Db4 = Portb.4 , Db5 = Portb.5 , Db6 = Portb.6 , Db7 = Port b.7 , E = Portb.2 , Rs = Portb.0 Config Lcd = 16 * 2 : Cursor Off Config Portc = Output Dim S1 As Integer Dim S2 As Integer Dim S3 As Integer Dim S4 As Integer Dim S5 As Integer Dim S6 As Integer Dim S7 As Integer Dim S8 As Integer Do Portc = &B00000000 Start Adc S1 = Getadc(0) : S1 = S1 / 5 Stop Adc Portc = &B00000001 Start Adc S2 = Getadc(0) : S2 = S2 / 5 Stop Adc Portc = &B00000010 Start Adc S3 = Getadc(0) : S3 = S3 / 5 Stop Adc Portc = &B00000011

Start Adc S4 = Getadc(0) : S4 = S4 / 5 Stop Adc Portc = &B00000100 Start Adc S5 = Getadc(0) : S5 = S5 / 5 Stop Adc Portc = &B00000101 Start Adc S6 = Getadc(0) : S6 = S6 / 5 Stop Adc Portc = &B00000110 Start Adc S7 = Getadc(0) : S7 = S7 / 5 Stop Adc Portc = &B00000111 Start Adc S8 = Getadc(0) : S8 = S8 / 5 Stop Adc Locate 1 , 1 : Lcd S8 Locate 1 , 5 : Lcd S7 Locate 1 , 9 : Lcd S6 Locate 1 , 13 : Lcd S5 Locate 2 , 1 : Lcd S4 Locate 2 , 5 : Lcd S3 Locate 2 , 9 : Lcd S2 Locate 2 , 13 : Lcd S1 Waitms 100 : Cls Loop End

You might also like