- Shouldn't affect anything, and will allow for greater buffer clearing controlsimple
} | } | ||||
// Signal KeyIndex_Buffer that it has been properly read | // Signal KeyIndex_Buffer that it has been properly read | ||||
void scan_finishedWithBuffer( void ) | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
} | } | ||||
// Signal that the keys have been properly sent over USB | // Signal that the keys have been properly sent over USB | ||||
void scan_finishedWithUSBBuffer( void ) | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
} | } | ||||
// Functions available to macro.c | // Functions available to macro.c | ||||
uint8_t scan_sendData( uint8_t dataPayload ); | uint8_t scan_sendData( uint8_t dataPayload ); | ||||
void scan_finishedWithBuffer( void ); | |||||
void scan_finishedWithUSBBuffer( void ); | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ); | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ); | |||||
void scan_lockKeyboard( void ); | void scan_lockKeyboard( void ); | ||||
void scan_unlockKeyboard( void ); | void scan_unlockKeyboard( void ); | ||||
void scan_resetKeyboard( void ); | void scan_resetKeyboard( void ); |
} | } | ||||
// Signal KeyIndex_Buffer that it has been properly read | // Signal KeyIndex_Buffer that it has been properly read | ||||
inline void scan_finishedWithBuffer( void ) | |||||
inline void scan_finishedWithBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
return; | return; | ||||
} | } | ||||
// | // | ||||
// However, this differentiation causes complications on how the key signals are discarded and used | // However, this differentiation causes complications on how the key signals are discarded and used | ||||
// The single keypresses must be discarded immediately, while the modifiers must be kept | // The single keypresses must be discarded immediately, while the modifiers must be kept | ||||
inline void scan_finishedWithUSBBuffer( void ) | |||||
inline void scan_finishedWithUSBBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
uint8_t foundModifiers = 0; | uint8_t foundModifiers = 0; | ||||
// Functions available to macro.c | // Functions available to macro.c | ||||
uint8_t scan_sendData( uint8_t dataPayload ); | uint8_t scan_sendData( uint8_t dataPayload ); | ||||
void scan_finishedWithBuffer( void ); | |||||
void scan_finishedWithUSBBuffer( void ); | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ); | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ); | |||||
void scan_lockKeyboard( void ); | void scan_lockKeyboard( void ); | ||||
void scan_unlockKeyboard( void ); | void scan_unlockKeyboard( void ); | ||||
void scan_resetKeyboard( void ); | void scan_resetKeyboard( void ); |
} | } | ||||
// Signal KeyIndex_Buffer that it has been properly read | // Signal KeyIndex_Buffer that it has been properly read | ||||
void scan_finishedWithBuffer( void ) | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
} | } | ||||
// Signal that the keys have been properly sent over USB | // Signal that the keys have been properly sent over USB | ||||
void scan_finishedWithUSBBuffer( void ) | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
} | } | ||||
// Functions available to macro.c | // Functions available to macro.c | ||||
uint8_t scan_sendData( uint8_t dataPayload ); | uint8_t scan_sendData( uint8_t dataPayload ); | ||||
void scan_finishedWithBuffer( void ); | |||||
void scan_finishedWithUSBBuffer( void ); | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ); | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ); | |||||
void scan_lockKeyboard( void ); | void scan_lockKeyboard( void ); | ||||
void scan_unlockKeyboard( void ); | void scan_unlockKeyboard( void ); | ||||
void scan_resetKeyboard( void ); | void scan_resetKeyboard( void ); |
} | } | ||||
// Signal KeyIndex_Buffer that it has been properly read | // Signal KeyIndex_Buffer that it has been properly read | ||||
void scan_finishedWithBuffer( void ) | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
} | } | ||||
// Signal that the keys have been properly sent over USB | // Signal that the keys have been properly sent over USB | ||||
void scan_finishedWithUSBBuffer( void ) | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
} | } | ||||
// Functions available to macro.c | // Functions available to macro.c | ||||
uint8_t scan_sendData( uint8_t dataPayload ); | uint8_t scan_sendData( uint8_t dataPayload ); | ||||
void scan_finishedWithBuffer( void ); | |||||
void scan_finishedWithUSBBuffer( void ); | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ); | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ); | |||||
void scan_lockKeyboard( void ); | void scan_lockKeyboard( void ); | ||||
void scan_unlockKeyboard( void ); | void scan_unlockKeyboard( void ); | ||||
void scan_resetKeyboard( void ); | void scan_resetKeyboard( void ); |
// Signal KeyIndex_Buffer that it has been properly read | // Signal KeyIndex_Buffer that it has been properly read | ||||
// In the case of the Micro Switch 8304, we leave the buffer alone until more scancode data comes in | // In the case of the Micro Switch 8304, we leave the buffer alone until more scancode data comes in | ||||
void scan_finishedWithBuffer( void ) | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
// We received a Clear code from the 8304, clear the buffer now that we've used it | // We received a Clear code from the 8304, clear the buffer now that we've used it | ||||
if ( BufferReadyToClear ) | if ( BufferReadyToClear ) | ||||
} | } | ||||
// Signal that the keys have been properly sent over USB | // Signal that the keys have been properly sent over USB | ||||
void scan_finishedWithUSBBuffer( void ) | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
} | } | ||||
// Functions available to macro.c | // Functions available to macro.c | ||||
uint8_t scan_sendData( uint8_t dataPayload ); | uint8_t scan_sendData( uint8_t dataPayload ); | ||||
void scan_finishedWithBuffer( void ); | |||||
void scan_finishedWithUSBBuffer( void ); | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ); | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ); | |||||
void scan_lockKeyboard( void ); | void scan_lockKeyboard( void ); | ||||
void scan_unlockKeyboard( void ); | void scan_unlockKeyboard( void ); | ||||
void scan_resetKeyboard( void ); | void scan_resetKeyboard( void ); |
// Signal KeyIndex_Buffer that it has been properly read | // Signal KeyIndex_Buffer that it has been properly read | ||||
// Not needed as a signal is sent to remove key-presses | // Not needed as a signal is sent to remove key-presses | ||||
void scan_finishedWithBuffer( void ) | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
return; | return; | ||||
} | } | ||||
KeyIndex_BufferUsed = 0; | KeyIndex_BufferUsed = 0; | ||||
} | } | ||||
void scan_finishedWithUSBBuffer( void ) | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
return; | return; | ||||
} | } |
// Functions available to macro.c | // Functions available to macro.c | ||||
uint8_t scan_sendData( uint8_t dataPayload ); | uint8_t scan_sendData( uint8_t dataPayload ); | ||||
void scan_finishedWithUSBBuffer( void ); | |||||
void scan_finishedWithBuffer( void ); | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ); | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ); | |||||
void scan_lockKeyboard( void ); | void scan_lockKeyboard( void ); | ||||
void scan_unlockKeyboard( void ); | void scan_unlockKeyboard( void ); | ||||
void scan_resetKeyboard( void ); | void scan_resetKeyboard( void ); |
// Signal KeyIndex_Buffer that it has been properly read | // Signal KeyIndex_Buffer that it has been properly read | ||||
// Not needed as a signal is sent to remove key-presses | // Not needed as a signal is sent to remove key-presses | ||||
void scan_finishedWithBuffer( void ) | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
return; | return; | ||||
} | } | ||||
// USB module is finished with buffer | // USB module is finished with buffer | ||||
// Not needed as a signal is sent to remove key-presses | // Not needed as a signal is sent to remove key-presses | ||||
void scan_finishedWithUSBBuffer( void ) | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
return; | return; | ||||
} | } |
// Functions available to macro.c | // Functions available to macro.c | ||||
uint8_t scan_sendData( uint8_t dataPayload ); | uint8_t scan_sendData( uint8_t dataPayload ); | ||||
void scan_finishedWithUSBBuffer( void ); | |||||
void scan_finishedWithBuffer( void ); | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ); | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ); | |||||
void scan_lockKeyboard( void ); | void scan_lockKeyboard( void ); | ||||
void scan_unlockKeyboard( void ); | void scan_unlockKeyboard( void ); | ||||
void scan_resetKeyboard( void ); | void scan_resetKeyboard( void ); |
// Signal KeyIndex_Buffer that it has been properly read | // Signal KeyIndex_Buffer that it has been properly read | ||||
// TODO | // TODO | ||||
void scan_finishedWithBuffer( void ) | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
} | } | ||||
// Signal that the keys have been properly sent over USB | // Signal that the keys have been properly sent over USB | ||||
void scan_finishedWithUSBBuffer( void ) | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
} | } | ||||
// Functions available to macro.c | // Functions available to macro.c | ||||
uint8_t scan_sendData( uint8_t dataPayload ); | uint8_t scan_sendData( uint8_t dataPayload ); | ||||
void scan_finishedWithBuffer( void ); | |||||
void scan_finishedWithUSBBuffer( void ); | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ); | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ); | |||||
void scan_lockKeyboard( void ); | void scan_lockKeyboard( void ); | ||||
void scan_unlockKeyboard( void ); | void scan_unlockKeyboard( void ); | ||||
void scan_resetKeyboard( void ); | void scan_resetKeyboard( void ); |
} | } | ||||
// Signal KeyIndex_Buffer that it has been properly read | // Signal KeyIndex_Buffer that it has been properly read | ||||
inline void scan_finishedWithBuffer( void ) | |||||
inline void scan_finishedWithBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
return; | return; | ||||
} | } | ||||
// Signal that the keys have been properly sent over USB | // Signal that the keys have been properly sent over USB | ||||
// TODO | // TODO | ||||
inline void scan_finishedWithUSBBuffer( void ) | |||||
inline void scan_finishedWithUSBBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
/* | /* | ||||
uint8_t foundModifiers = 0; | uint8_t foundModifiers = 0; |
// Functions available to macro.c | // Functions available to macro.c | ||||
uint8_t scan_sendData( uint8_t dataPayload ); | uint8_t scan_sendData( uint8_t dataPayload ); | ||||
void scan_finishedWithBuffer( void ); | |||||
void scan_finishedWithUSBBuffer( void ); | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ); | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ); | |||||
void scan_lockKeyboard( void ); | void scan_lockKeyboard( void ); | ||||
void scan_unlockKeyboard( void ); | void scan_unlockKeyboard( void ); | ||||
void scan_resetKeyboard( void ); | void scan_resetKeyboard( void ); |
// Signal that the keys have been properly sent over USB | // Signal that the keys have been properly sent over USB | ||||
inline void scan_finishedWithUSBBuffer( void ) | |||||
inline void scan_finishedWithUSBBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
return; | return; | ||||
} | } | ||||
// Signal KeyIndex_Buffer that it has been fully scanned using the macro module | // Signal KeyIndex_Buffer that it has been fully scanned using the macro module | ||||
inline void scan_finishedWithBuffer( void ) | |||||
inline void scan_finishedWithBuffer( uint8_t sentKeys ) | |||||
{ | { | ||||
return; | return; | ||||
} | } |
// Functions available to macro.c | // Functions available to macro.c | ||||
uint8_t scan_sendData( uint8_t dataPayload ); | uint8_t scan_sendData( uint8_t dataPayload ); | ||||
void scan_finishedWithBuffer( void ); | |||||
void scan_finishedWithUSBBuffer( void ); | |||||
void scan_finishedWithBuffer( uint8_t sentKeys ); | |||||
void scan_finishedWithUSBBuffer( uint8_t sentKeys ); | |||||
void scan_lockKeyboard( void ); | void scan_lockKeyboard( void ); | ||||
void scan_unlockKeyboard( void ); | void scan_unlockKeyboard( void ); | ||||
void scan_resetKeyboard( void ); | void scan_resetKeyboard( void ); |