Necr0tizing / ArduinoKeyboardLayouts

Arduino keyboard languages for easy swapping of keyboard layout codes to match your language, ideal for non US users
9 stars 1 forks source link

software problem #1

Open anavrageuser opened 5 years ago

anavrageuser commented 5 years ago

Hi i wanted to make a bad usb kinda thing. So i wanted to have my keyboard layout because the english one types incorrectly. Then i downloaded your Czech keyboard.cpp and i also added it as described. But when i go and include the keyboard library i always get en error saying Multiple libraries were found for "Keyboard.h" Used: C:\Program Multiple libraries were found for "HID.h" Used: C:\Program exit status 1 Error compiling for board Arduino/Genuino Micro.

pls help.

akskaftun commented 4 years ago

Having some issues with the layout acting as norwegian. Symbols that needs "Alt Gr" does not behave like they should. Do you know what the hex code of that key is?

s0ck37 commented 3 years ago

Having some issues with the layout acting as norwegian. Symbols that needs "Alt Gr" does not behave like they should. Do you know what the hex code of that key is?

I had the same problem with spanish layout, I could solve it by making a custom function to print a string instead of Keyboard.print()
I haven't tried other layouts, just the spanish one.

void print_all(char* str){
  for(int i = 0; i<strlen(str); i++){
    if(((int)str[i] > 90 and (int)str[i] < 94) or ((int)str[i] > 122 and (int)str[i] < 126)){
      Keyboard.press(KEY_RIGHT_ALT);
      Keyboard.press((char)str[i]);
      Keyboard.releaseAll();
    } else{
      Keyboard.print(str[i]);
    }
  }
}