$regfile = "m32def.dat"
$crystal = 6144000
$baud = 19200
$timeout = 100000

'################################################# ################################################## #################
'################################################# ################################################## #################

Ddra = &B11111000
Ddrb = &B11111111
Ddrc = &B11111111
Ddrd = &B11111111

Porta = &B00000000
Portb = &B00001100
Portc = &B00000000
Portd = &B00000000

'################################################# ################################################## #################
'################################################# ################################################## #################

Porta.0 = 1 '-pull up Widerstand für erste Taste aktivieren
Porta.1 = 1 '-pull up Widerstand für zweite Taste aktivieren
Porta.2 = 1 '-pull up Widerstand für zweite Taste aktivieren

'################################################# ################################################## #################
'################################################# ################################################## #################

Config Lcdpin = Pin , Db4 = Porta.4 , Db5 = Porta.5 , Db6 = Porta.6 , Db7 = Porta.7 , E = Portb.5 , Rs = Portb.0
Config Lcd = 16 * 2
Config Porta = Output
Reset Portb.1
Initlcd
Cursor Off
Cls
Porta.3 = 1 'Licht an

'################################################# ################################################## #################
'################################################# ################################################## #################

'Declare Function Read_gsm(byval Mask As String) As Byte

Dim A As String * 10
Dim B As Word
Dim C As Word
Dim D As String * 32
Dim E As String * 32
Dim F As String * 32
Dim Status As Byte

Config Serialin = Buffered , Size = 20

Enable Interrupts

C = 0

Print "at"

Locate 1 , 1




for b = 1 to 50

A = Inkey()

If Err = 0 Then

Lcd A

End If


Waitms 100



If C = 16 Then

Locate 2 , 1

End If

Incr C


Next B


Locate 2 , 1

Lcd A



End