1 /* Copyright (C) 2013-2015 by Jacob Alexander
3 * This library is free software; you can redistribute it and/or
4 * modify it under the terms of the GNU Lesser General Public
5 * License as published by the Free Software Foundation; either
6 * version 3.0 of the License, or (at your option) any later version.
8 * This library is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 * Lesser General Public License for more details.
13 * You should have received a copy of the GNU Lesser General Public
14 * License along with this library. If not, see <http://www.gnu.org/licenses/>.
19 // ----- Includes -----
28 // ----- Defines -----
30 #define KEYBOARD_KEYS 0xFF // TODO Determine max number of keys
31 #define KEYBOARD_BUFFER 24 // Max number of key signals to buffer
32 // This limits the NKRO-ability, so at 24, the keyboard is 24KRO
33 // The buffer is really only needed for converter modules
34 // An alternative macro module could be written for matrix modules and still work well
38 // ----- Variables -----
40 extern volatile uint8_t KeyIndex_Buffer[KEYBOARD_BUFFER];
41 extern volatile uint8_t KeyIndex_BufferUsed;
45 // ----- Functions -----
47 // Functions used by main.c
52 // Functions available to macro.c
53 uint8_t Scan_sendData( uint8_t dataPayload );
55 void Scan_finishedWithMacro( uint8_t sentKeys );
56 void Scan_finishedWithOutput( uint8_t sentKeys );