{"id":20949274,"url":"https://github.com/mal1kc/lazyboard","last_synced_at":"2026-04-27T14:31:14.818Z","repository":{"id":107393557,"uuid":"603533281","full_name":"mal1kc/lazyboard","owner":"mal1kc","description":"This project contains code written to interface with the Lazyboard, a hardware platform created by the Turkish YouTube channel and content creator, Lezzetli Robot Tarifleri.","archived":false,"fork":false,"pushed_at":"2024-02-24T23:13:46.000Z","size":161,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-12-29T14:48:05.876Z","etag":null,"topics":["attiny85","digispark-usb","digisparkkeyboard"],"latest_commit_sha":null,"homepage":"https://lezzetlirobottarifleri.com/lazyboard-usengec-ama-uretken-kisiler-icin-kisisellestirilebilir-macropad","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mal1kc.png","metadata":{"files":{"readme":"readme.org","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2023-02-18T19:55:44.000Z","updated_at":"2025-01-15T10:51:06.000Z","dependencies_parsed_at":"2024-02-25T00:24:33.895Z","dependency_job_id":"e85a24b5-5df4-4fb3-bba9-e5b2cc00910a","html_url":"https://github.com/mal1kc/lazyboard","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/mal1kc/lazyboard","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mal1kc%2Flazyboard","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mal1kc%2Flazyboard/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mal1kc%2Flazyboard/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mal1kc%2Flazyboard/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mal1kc","download_url":"https://codeload.github.com/mal1kc/lazyboard/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mal1kc%2Flazyboard/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32341447,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-26T23:26:28.701Z","status":"online","status_checked_at":"2026-04-27T02:00:06.769Z","response_time":128,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["attiny85","digispark-usb","digisparkkeyboard"],"created_at":"2024-11-19T00:34:52.277Z","updated_at":"2026-04-27T14:31:14.800Z","avatar_url":"https://github.com/mal1kc.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"#+title: lazyboard code base\n\n* what is lazyboard\nread more detailed in [[https://lezzetlirobottarifleri.com/lazyboard-usengec-ama-uretken-kisiler-icin-kisisellestirilebilir-macropad/#Lazyboardu_ve_Komponentleri_Temin_Etme][lazyboard tutorial (Turkish)]]\n\n* libraries that used in code\n\n#+begin_src gitconfig :tangle .gitmodules\n[submodule \"DigisParkKeyboard\"]\n\tpath = lib/DigisParkKeyboard\n\turl = https://github.com/mal1kc/digisparkkeyboard\n\tbranch = main\n#+end_src\n- [[https://github.com/mal1kc/digisparkkeyboard][lib/digisparkkeyboard]]\n** coding tutorial and template code\n\n\n[[./docs/circuit-scheme.png][electronic scheme]]\n\n*** including library\n\n#+begin_src c :tangle ./examples/template.ino\n#define kbd_tr_tr // define keyboard layout\n#include \"DigiKeyboard.h\" // include library file\n#+end_src\n\n*** led control\n\nall leds can be controlled via transistor that connected to PB1 port of attiny85, they can't be conntrolled separately.\n\n#+begin_src c :tangle ./examples/template_led_control.ino\n\n// ------ led control ------\n\n#define led 1 // defining pin number\n\nvoid setup() {\n  pinMode(led, OUTPUT); // setting pinmode as output\n}\n\nvoid loop() {\n  digitalWrite(led, HIGH); // led on\n  delay(500);\n  digitalWrite(led, LOW); // led off\n  delay(500);\n}\n#+end_src\n\n*** reading analog values\n\nattiny85 in lazyboard, that has internal uart or usb uart unit cause this reason we can't directly transfer analog data to serial monitor.But there is a trick,\nwe can intruduce lazyboard as keyboard to pc than we can transfer datas like  printing with keyboard.\n\n#+begin_src c :tangle ./examples/template_read_analog.ino\n\n// ----- reading analog values -----\n\n// setting tr(turkish) keyboard layout\n#define kbd_tr_tr\n#include \"DigiKeyboard.h\"\n\nvoid setup() {\n  // disable input for 2,5 second for no startup errors\n  // and sending empty keystroke\n  DigiKeyboard.delay(2500);\n  DigiKeyboard.sendKeyStroke(0);\n}\n\nvoid loop() {\n\n  // reading mechanic switch data and assigning into data variable\n  int data = analogRead(1);\n  if ( data \u003e 100)\n  {\n    // writing \"read val: \" from keyboard\n    // WARN: error from library cannot print 'ğ' keyword\n    DigiKeyboard.print(\"read val:    \");\n    DigiKeyboard.print(data);\n    // sending 'return'/'enter' key stroke\n    DigiKeyboard.sendKeyStroke(KEY_ENTER);\n    while (analogRead(1) \u003e 100);\n  }\n  // for ignoring analog read unstabilty to waiting very short time\n  DigiKeyboard.delay(50);\n}\n#+end_src\n\n*** mechanic switch control\n[[./docs/circuit-of-mechanic-switches.png][mechanic keyboard scheme]]\n\nlike we can see in scheme if we press *S6* 2.2K resistance and under favour of 10K voltage divider data reading accurs. when we press *S5* 3.3K + 2.2K = 5.5K through voltage divider then accourdingly to that it comes to attiny85.in this senario we can understand which key is pressed.\n*WARN:we need to calibrate our buttons to work all buttons *\n#+begin_src c :tangle ./examples/template_switch_control.ino\n\n// ---- switch control -----\n\n#define kbd_tr_tr\n#include \"DigiKeyboard.h\"\n\nvoid setup() {\n  DigiKeyboard.delay(2500);\n  DigiKeyboard.sendKeyStroke(0);\n}\n\nvoid loop() {\n\n  int data = analogRead(1);\n  if ( data \u003e 100)\n  {\n      //if button 6 pressed we do this operations\n    if (data \u003e 933) {\n      DigiKeyboard.print(\"button 6 pressed\");\n    }\n      //if button 5 pressed we do this operations\n    else if (data \u003e 747) {\n      DigiKeyboard.print(\"button 5 pressed\");\n    }\n      //if button 4 pressed we do this operations\n    else if (data \u003e 577) {\n      DigiKeyboard.print(\"button 4 pressed\");\n    }\n      //if button 3 pressed we do this operations\n    else if (data \u003e 421) {\n      DigiKeyboard.print(\"button 3 pressed\");\n    }\n      //if button 2 pressed we do this operations\n    else if (data \u003e 249) {\n      DigiKeyboard.print(\"button 2 pressed\");\n    }\n      //if button 1 pressed we do this operations\n    else  {\n      DigiKeyboard.print(\"button 1 pressed\");\n    }\n\n    DigiKeyboard.sendKeyStroke(KEY_ENTER);\n    while (analogRead(1) \u003e 100);\n  }\n\n}\n#+end_src\n\n*** Controlling via laser remote control\n**** intruducing remote control buttons\nwith infrared in lazyboard we can use with infrared remote control devices.\nbut we need to find buttons hex codes to configure buttons, for this we can use this code snippet.\n#+begin_src c :tangle ./examples/template_rc_introduce.ino\n#define kbd_tr_tr\n#include \"DigiKeyboard.h\"\n\n\n// setting IR reader pin, 0 is default for 'Lazyboard'\nconst byte IRpin = 0;\n\n// creating and assinging remote and irCode variables ,there are neccesary for our algorithm\nvolatile boolean remote = false;\nvolatile unsigned long irCode = 0;\n\nvoid setup() {\n\n    // setting IR reader pin's mode as Input\n  pinMode(IRpin, INPUT);\n\n\n  // waiting to 2,5s to initialize and start with empty keystroke\n  DigiKeyboard.delay(2500);\n  DigiKeyboard.sendKeyStroke(0);\n}\n\nvoid loop() {\n    // IR reader gives 1 (HIGH) when it not detect any signal\n  if (digitalRead(IRpin)) {\n    remoting();\n  } else {\n\n      // when it gets signal we print values to our computer as keyboard\n    DigiKeyboard.println(irCode, HEX);\n  }\n  // for our algorith work we change remote as true\n  remote = true;\n}\n\n\n//IR reading func\nvoid remoting()\n{\n  if (remote) {\n    remote = false;\n    unsigned long T;\n    for (byte n = 0; n \u003c 32; n++) {\n      do {\n        T = pulseIn(IRpin, HIGH, 2200);\n      } while (T \u003c 64);\n      bitWrite(irCode, n, T \u003e 1120);\n    }\n  }\n}\n#+end_src\n\n**** using remote control\n\n#+begin_src c :tangle ./examples/template_rc_buttons.ino\n#define kbd_tr_tr\n#include \"DigiKeyboard.h\"\n\n// setting IR reader pin, 0 is default for 'Lazyboard'\nconst byte IRpin = 0;\n\n// creating and assinging remote and irCode variables ,there are neccesary for our algorithm\nvolatile boolean remote = false;\nvolatile unsigned long irCode = 0;\n\nvoid setup() {\n\n    // setting IR reader pin's mode as Input\n  pinMode(IRpin, INPUT);\n\n\n  // waiting to 2,5s to initialize and start with empty keystroke\n  DigiKeyboard.delay(2500);\n  DigiKeyboard.sendKeyStroke(0);\n}\n\nvoid loop() {\n    // IR reader gives 1 (HIGH) when it not detect any signal\n  if (digitalRead(IRpin)) {\n    remoting();\n  } else {\n    // if pressed 1.button\n    if (irCode == 0xE718FF00) {\n      DigiKeyboard.println(\"Up\");\n      irCode = 0;\n    }\n    // if pressed 2.button\n    else if(irCode == 0xAD52FF00)\n    {\n      DigiKeyboard.println(\"Down\");\n      irCode = 0;\n    }\n  // for our algorith work we change remote as true\n  remote = true;\n}\n\n\n//IR reading func\nvoid remoting()\n{\n  if (remote) {\n    remote = false;\n    unsigned long T;\n    for (byte n = 0; n \u003c 32; n++) {\n      do {\n        T = pulseIn(IRpin, HIGH, 2200);\n      } while (T \u003c 64);\n      bitWrite(irCode, n, T \u003e 1120);\n    }\n  }\n}\n#+end_src\n\n*** doing key combinations\nfor some situations you may need press multiple button in same time situations like these we use code in below :\n\n#+begin_src c\nDigiKeyboard.sendKeyStroke()\n#+end_src\n\nexample of copy\n\n#+begin_src c\n\nDigiKeyboard.sendKeyStroke(KEY_C , MOD_CONTROL_LEFT);\n// KEY_C is 'C', MOD_CONTROL_LEFT is left control button (left-ctrl)\nDigiKeyboard.sendKeyStroke(KEY_V , MOD_CONTROL_LEFT);\n// KEY_V is 'V', MOD_CONTROL_LEFT is left control button (left-ctrl)\n\n#+end_src\n\nmaybe u need 3 triple key combinations you can use somethink like\n#+begin_src c\nDigiKeyboard.sendKeyStroke(KEY_S, MOD_GUI_LEFT | MOD_SHIFT_LEFT);\n//KEY_S is 'S', MOD_GUI_LEF is left super (prob. key with windows logo) key , MOD_SHIFT_LEFT is left Shift\n\n#+end_src\n\n\nsome special keys\n\n| key_val             | keyboard equivalents  |\n|---------------------+-----------------------|\n| MOD_CONTROL_LEFT    | left Control key      |\n| MOD_SHIFT_LEFT      | left Shift key        |\n| MOD_ALT_LEFT        | left Alt key          |\n| MOD_GUI_LEFT        | left Super key        |\n| +                 + | +                   + |\n| MOD_CONTROL_RIGHT   | right Control key     |\n| MOD_SHIFT_RIGHT     | right Shift key       |\n| MOD_ALT_RIGHT       | right Alt key         |\n| MOD_GUI_RIGHT       | right Super key       |\n\nyou can use *'KEY_'* as prefix for keys in English like in T =\u003e KEY_T\nbut specific layouts like Turkish you need to use *.print()* funtion\nWARN: some apps can be problematic with *.print()* func because of that try using English keys if it is possible\n\n*** adding custom shortcuts for applications\n\nyou can use lazyboard as launcher for launch your frequent used apps.\nlook for example :\n#+begin_src c\n#define kbd_tr_tr\n#include \"DigiKeyboard.h\"\n\nvoid setup() {\n  // disable input for 2,5 second for no startup errors\n  // and sending empty keystroke\n  DigiKeyboard.delay(2500);\n  DigiKeyboard.sendKeyStroke(0);\n}\n\nvoid loop() {\n  int data = analogRead(1);\n  if (data \u003e 100) {\n   if (data \u003e 933) {\n    // open windows run WİN+R\n    DigiKeyboard.sendKeyStroke(KEY_R, MOD_GUI_LEFT);\n    DigiKeyboard.delay(500);\n    // open cmd\n    // Win + r + print cmd + enter\n    DigiKeyboard.print(\"cmd\");\n    DigiKeyboard.sendKeyStroke(KEY_ENTER);\n    DigiKeyboard.delay(600);\n\n    // run command to  change dir tor EAGLE dir\n    DigiKeyboard.print(\"cd C:\\/\");\n    DigiKeyboard.print(\"EAGLE 9.6.2/\");\n    DigiKeyboard.delay(500);\n    DigiKeyboard.sendKeyStroke(KEY_ENTER);\n\n    // run eagle\n    DigiKeyboard.print(\"eagle.exe\");\n    DigiKeyboard.sendKeyStroke(KEY_ENTER);\n    DigiKeyboard.delay(500);\n\n    // close cmd via alt + f4\n    DigiKeyboard.sendKeyStroke(KEY_F4, MOD_ALT_LEFT);\n  } else if (data \u003e 747) {\n    // windows run  win + r\n    DigiKeyboard.sendKeyStroke(KEY_R, MOD_GUI_LEFT);\n    DigiKeyboard.delay(500);\n\n    // CMD\n    DigiKeyboard.print(\"cmd\");\n    DigiKeyboard.sendKeyStroke(KEY_ENTER);\n    DigiKeyboard.delay(600);\n    // cd to arduino installation dir\n    DigiKeyboard.print(\"cd C:\\/\");\n    DigiKeyboard.print(\"Program Files\\/\");\n    DigiKeyboard.print(\"Arduino IDE/\");\n    DigiKeyboard.delay(500);\n    DigiKeyboard.sendKeyStroke(KEY_ENTER);\n    DigiKeyboard.delay(500);\n\n    // run arduino\n    // reason for keystroke 0x35;\n    // in some app names have spaces for this situations we use '\"' symbol and it s hex code is 0x35. (cmd)\n\n\n    DigiKeyboard.sendKeyStroke(0x35);\n    DigiKeyboard.print(\"Arduino IDE.exe\");\n    DigiKeyboard.sendKeyStroke(0x35);\n    DigiKeyboard.sendKeyStroke(KEY_ENTER);\n\n    // if we close cmd arduino ide close cause of this reason we not close cmd\n    DigiKeyboard.delay(500);\n  } else if (data \u003e 577) {\n      //if button 4 pressed we do this operations\n  } else if (data \u003e 421) {\n      //if button 3 pressed we do this operations\n  } else if (data \u003e 249) {\n      //if button 2 pressed we do this operations\n  } else {\n      //if button 1 pressed we do this operations\n  }\n\n  DigiKeyboard.sendKeyStroke(KEY_ENTER);\n  while (analogRead(1) \u003e 100);\n }\n}\n#+end_src\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmal1kc%2Flazyboard","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmal1kc%2Flazyboard","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmal1kc%2Flazyboard/lists"}