{"id":15707019,"url":"https://github.com/0x2b3bfa0/python-duckencode","last_synced_at":"2025-05-12T19:13:33.048Z","repository":{"id":92704334,"uuid":"44671554","full_name":"0x2b3bfa0/python-duckencode","owner":"0x2b3bfa0","description":"This program converts Duckyscript code into Arduino code for AVR chips with USB support. (i.e. Arduino Leonardo)","archived":false,"fork":false,"pushed_at":"2020-01-15T17:55:54.000Z","size":20,"stargazers_count":5,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-12T19:13:23.954Z","etag":null,"topics":["arduino","compiler","duckyscript","keyboard","keyboard-emulation","rubber-ducky"],"latest_commit_sha":null,"homepage":"","language":"Python","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/0x2b3bfa0.png","metadata":{"files":{"readme":"README.md","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,"publiccode":null,"codemeta":null}},"created_at":"2015-10-21T11:25:15.000Z","updated_at":"2023-12-17T04:24:00.000Z","dependencies_parsed_at":"2023-04-23T15:17:31.407Z","dependency_job_id":null,"html_url":"https://github.com/0x2b3bfa0/python-duckencode","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x2b3bfa0%2Fpython-duckencode","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x2b3bfa0%2Fpython-duckencode/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x2b3bfa0%2Fpython-duckencode/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x2b3bfa0%2Fpython-duckencode/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/0x2b3bfa0","download_url":"https://codeload.github.com/0x2b3bfa0/python-duckencode/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253805850,"owners_count":21967053,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["arduino","compiler","duckyscript","keyboard","keyboard-emulation","rubber-ducky"],"created_at":"2024-10-03T20:32:38.324Z","updated_at":"2025-05-12T19:13:33.028Z","avatar_url":"https://github.com/0x2b3bfa0.png","language":"Python","readme":"Description\r\n-----------\r\n\r\nSimple DuckyScript to Arduino translator for AVR chips with USB support.\r\n\r\nInstallation\r\n------------\r\n\r\n1. Clone this repository and `cd` into it:\r\n\r\n        git clone https://github.com/0x2b3bfa0/python-duckencode.git\r\n        cd python-duckencode\r\n\r\n2. Make public the `sendReport()` function:\r\n\r\n    You should edit a file called `USBAPI.h`. This file may be on one of the following paths\u003csup\u003e[1](#footnote_1)\u003c/sup\u003e:\r\n\r\n        {ARDUINO}/hardware/arduino/cores/arduino/USBAPI.h\r\n        {SKETCHES}/hardware/arduino/cores/arduino/USBAPI.h\r\n\r\n\r\n    Once you've found this file, open it with your favorite text editor and locate these lines:\r\n\r\n        private:\r\n            KeyMap* _keyMap;\r\n            void sendReport(KeyReport* keys);\r\n            void setKeyMap(KeyMap* keyMap);\r\n        public:\r\n            Keyboard_();\r\n            virtual size_t write(uint8_t);\r\n\r\n    Simply cut this line from the `private` section and paste it on the `public` section:\r\n\r\n        void sendReport(KeyReport* keys);\r\n\r\n    Once edited these lines should look like this:\r\n\r\n        private:\r\n            KeyMap* _keyMap;\r\n            void setKeyMap(KeyMap* keyMap);\r\n        public:\r\n            void sendReport(KeyReport* keys);\r\n            Keyboard_();\r\n            virtual size_t write(uint8_t);\r\n\r\n3. Run the program:\r\n\r\n        ./compiler.py\r\n\r\n---\r\n\r\n\u003ca name=\"footnote_1\"\u003e**1**\u003c/a\u003e**:** `{ARDUINO}` represents the directory into which the Arduino IDE and supporting files have been installed. This may be `/usr/local/arduino` or `/usr/share/arduino` or one of many other possible choices depending on your operating system.\r\n\r\n[1]: https://ctrlaltnarwhal.wordpress.com/2012/10/31/installing-usb-rubber-ducky-on-3rd-party-devices/\r\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F0x2b3bfa0%2Fpython-duckencode","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F0x2b3bfa0%2Fpython-duckencode","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F0x2b3bfa0%2Fpython-duckencode/lists"}