minor Bug Fixes

This commit is contained in:
Alexander Richter 2023-05-02 16:04:26 +02:00
parent da66118131
commit e72e94b94b
2 changed files with 9 additions and 6 deletions

View File

@ -209,7 +209,7 @@ const int numCols = 4; // Define the number of columns in the matrix
const int rowPins[numRows] = {2, 3, 4, 5};
const int colPins[numCols] = {6, 7, 8, 9};
//####################################### END OF CONFIG ###########################
int keys[numRows][numCols] = {
{1,2,3,4},
@ -223,6 +223,7 @@ int lastKey= 0;
//#define DEBUG
//####################################### END OF CONFIG ###########################
//###Misc Settings###
const int timeout = 10000; // timeout after 10 sec not receiving Stuff

View File

@ -312,8 +312,10 @@ while True:
elif cmd == "M":
firstcom = 1
if value == 1 & LinuxKeyboardInput & Destination[io]:
if value == 1:
if Destination[io] == 0 and LinuxKeyboardInput == 1:
subprocess.call(["xdotool", "key", Chars[io]])
if(Debug):print("Emulating Keypress{}".format(Chars[io]))
else:
c["MKey.{}".format(Chars[io])] = 1
if(Debug):print("MKey{}:{}".format(Chars[io],1))