Guten Morgen zusammen. Ich würde gerne den Code von Peter Danegger für eine Tastatur Matrix auf einem AVR Atmega 8 nutzen. Es soll später eine Tastatur werden mit 4 Spalten und 5 Reihen also 20 Taster eine C routine habe ich schon aber da werden meine Taster nicht entprellt. Bei der Routine von Peter ist aber direkt eine Entprellung drin und deshalb wollte ich die Verwenden. Nur ich bekomme beim Compilieren einige Fehlermeldungen die ich schon nich ganz nachvolziehen kann. Warum zum Beispiel wird das array valid_keys nicht erkannt ?! sowie alle andern sachen auch ? könnte mir vieleicht jmd auf die Sprünge helfen ? Schönen Gruß Frank
1 | ../Tastermatrix.c:30: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'valid_keys' |
2 | ../Tastermatrix.c:31: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'last_keys' |
3 | ../Tastermatrix.c: In function 'InitKeyboard': |
4 | ../Tastermatrix.c:39: error: 'valid_keys' undeclared (first use in this function) |
5 | ../Tastermatrix.c:39: error: (Each undeclared identifier is reported only once |
6 | ../Tastermatrix.c:39: error: for each function it appears in.) |
7 | ../Tastermatrix.c:40: error: 'last_keys' undeclared (first use in this function) |
8 | ../Tastermatrix.c: In function 'GetKey': |
9 | ../Tastermatrix.c:53: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'ROW' |
10 | ../Tastermatrix.c:53: error: 'ROW' undeclared (first use in this function) |
11 | ../Tastermatrix.c:53: error: expected expression before ']' token |
12 | ../Tastermatrix.c:61: error: 'valid_keys' undeclared (first use in this function) |
13 | ../Tastermatrix.c:66: error: 'last_keys' undeclared (first use in this function) |