Amr sherif
Newbie level 4
Hi all , i am New here and i have problem with programing counter with proton program , i am using basic language . My project is to use an analoge to digital converter in Pic 16f877a to calculat the temp by using Lm35 and to make alarm when the Temp reatches a certain value, the problem is i canot declare the Puch button to the program , and also i want to know how to declare the puch button to the micro ( Which port ). Plz replay fast Thx :grin:
The program :
Device 16F877A
XTAL 4
LCD_RSPIN PORTC.0
LCD_ENPIN PORTC.1
LCD_INTERFACE 8
LCD_DTPIN PORTB.0
LCD_LINES 2
Dim name As Byte
Dim s1 As Byte
Dim s2 As Byte
Dim y As Byte
loop:
Button 0,0,255,250,name,0,nopress
Print "F"
nopress:
GoTo loop
The program :
Device 16F877A
XTAL 4
LCD_RSPIN PORTC.0
LCD_ENPIN PORTC.1
LCD_INTERFACE 8
LCD_DTPIN PORTB.0
LCD_LINES 2
Dim name As Byte
Dim s1 As Byte
Dim s2 As Byte
Dim y As Byte
loop:
Button 0,0,255,250,name,0,nopress
Print "F"
nopress:
GoTo loop