Ich habe grade mal versucht anhand des Datenblatts ein kleines Programm in Bascom zu schreiben, um das Display anzusteuern.
Ich habe leider grad das Display nicht zur Hand, aber würde das nach diesem Muster in der Theorie funktionieren?
Code:
$regfile "m8def.dat"
$crystal = 1000000
Config Portd = Output
Config Portb = Output
'Init
E = 1
E = 0
Rw = 0
Rs = 1
Portd = 0
Rw = 0
Rs = 0
Portd = 0b00100100
Rw = 0
Rs = 1
Portd = 0x01
Rw = 0
Rs = 0
Portd = 0b10010110
Rw = 0
Rs = 1
Portd = 0x02
Rw = 0
Rs = 0
Portd = 0x16
'(Rw = 0
Rs = 1
Portd = 0x03
')
'(Rw = 0
Rs = 1
Portd = 0x04
')
'Test ausgeben
Rw = 0
Rs = 1
Portd = 0x0c
Rw = 0
Rs = 0
Portd = 0b01010100 'T
Rw = 0
Rs = 1
Portd = 0x0c
Rw = 0
Rs = 0
Portd = 0b01100101 'e
Rw = 0
Rs = 1
Portd = 0x0c
Rw = 0
Rs = 0
Portd = 0b01110011 's
Rw = 0
Rs = 1
Portd = 0x0c
Rw = 0
Rs = 0
Portd = 0b01110100 't
End
Lesezeichen