{"id":13513974,"url":"https://github.com/maehw/SerialHex2FlipperZeroInfrared","last_synced_at":"2025-03-31T02:33:10.989Z","repository":{"id":118986234,"uuid":"573519691","full_name":"maehw/SerialHex2FlipperZeroInfrared","owner":"maehw","description":"Convert infrared serial interface commands for Flipper Zero 🐬 🧱🤖","archived":false,"fork":false,"pushed_at":"2023-04-10T11:03:08.000Z","size":36,"stargazers_count":81,"open_issues_count":0,"forks_count":3,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-02-12T17:05:11.962Z","etag":null,"topics":["flipper-zero","flipperzero","infrared","infrared-encoder","lego","lego-mindstorms","mindstorms","mindstorms-rcx","rcx","serial-communication"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/maehw.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2022-12-02T16:54:10.000Z","updated_at":"2024-02-08T10:45:07.000Z","dependencies_parsed_at":null,"dependency_job_id":"d43f7d70-7c32-402f-abbb-55e8bb965bfb","html_url":"https://github.com/maehw/SerialHex2FlipperZeroInfrared","commit_stats":{"total_commits":5,"total_committers":1,"mean_commits":5.0,"dds":0.0,"last_synced_commit":"194dae32b2c57297811a5eed64737487fae0df76"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maehw%2FSerialHex2FlipperZeroInfrared","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maehw%2FSerialHex2FlipperZeroInfrared/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maehw%2FSerialHex2FlipperZeroInfrared/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maehw%2FSerialHex2FlipperZeroInfrared/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/maehw","download_url":"https://codeload.github.com/maehw/SerialHex2FlipperZeroInfrared/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246407400,"owners_count":20772126,"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":["flipper-zero","flipperzero","infrared","infrared-encoder","lego","lego-mindstorms","mindstorms","mindstorms-rcx","rcx","serial-communication"],"created_at":"2024-08-01T05:00:41.545Z","updated_at":"2025-03-31T02:33:06.910Z","avatar_url":"https://github.com/maehw.png","language":"Python","funding_links":[],"categories":["Off-device \u0026 Debugging","Databases \u0026 Dumps"],"sub_categories":["*Converters*","Converters"],"readme":"# README\n\nThe Python script `convert.py` can be used to convert infrared serial interface commands (in hexadecimal representation) into a Flipper Zero\u003csup\u003e[1]\u003c/sup\u003e compatible infrared\u003csup\u003e[2]\u003c/sup\u003e `.ir` file.\n\nThe script supports sending multiple multibyte messages at once and adds wait times for message replies by default.\n\nUse case: It can be used to convert LEGO MINDSTORMS RCX\u003csup\u003e[3]\u003c/sup\u003e (the \"yellow programmable brick\") infrared commands\u003csup\u003e[4]\u003c/sup\u003e (see `LEGO_RCX.json` input file).\n\n\u003e :warning: If LEGO MINDSTORMS RCX is a use case for you: the example does not take care of the toggle bit. So sending the IR commands may not always work. You'll need to dive deeper into the internals of the RCX communication protocol. Pull requests are very welcome!\n\n## References\n\n[1] [Flipper Zero — Portable Multi-tool Device for Geeks](https://flipperzero.one/)\n\n[2] [Flipper Zero Blog — Taking over TVs with Flipper Zero Infrared Port](https://blog.flipperzero.one/infrared/)\n\n[3] *Disclaimer: LEGO and MINDSTORMS are trademarks and copyrights of the LEGO Group of companies which does not sponsor, authorize or endorse this site.*\n\n[4] [RCX 2.0 Firmware Command Overview / LASM bytecode specification](https://www.inf.ed.ac.uk/teaching/courses/sdp/lego/LASM_Bytecodes.pdf)\n\n## Dependencies\n\nA Python 3 environment is required.\n\nThe script only imports `sys` and `json` and therefore shouldn't require any additional packages.\n\n\n## Converter usage\n\nRun converter and print output on stdout:\n\n```\n$ python convert.py LEGO_RCX.json\n```\n\nRun converter and pipe output to IR output file:\n\n```\n$ python convert.py LEGO_RCX.json \u003e LEGO_RCX.ir\n```\n\nRun converter and pipe output to both an IR output file and stdout:\n\n```\n$ python convert.py LEGO_RCX.json | tee LEGO_RCX.ir\n```\n\nFor the format of the `.json` file, inspect `LEGO_RCX.json` example.\n\n\n## Plot usage\n\nThe IR signal plot script additionally requires the Python module `matplotlib`.\n\n```\nUsage: python3 plot_signal.py \u003cIR_file_name\u003e \u003cIR_signal_name\u003e\n```\n\nExample:\n\n```\npython plot_signal.py LEGO_RCX.ir ABC_STOP\nTrying to open file 'LEGO_RCX.ir' and then to plot signal 'ABC_STOP'\nFound signal:\n  Raw signal name: ABC_STOP\n  Raw signal data: 833 417 417 417 417 ...\n```\n\n![IR signal plot](./IR_signal_plot.png)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmaehw%2FSerialHex2FlipperZeroInfrared","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmaehw%2FSerialHex2FlipperZeroInfrared","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmaehw%2FSerialHex2FlipperZeroInfrared/lists"}