{"id":22261781,"url":"https://github.com/jsonfm/serialio","last_synced_at":"2025-08-03T23:41:04.637Z","repository":{"id":137721138,"uuid":"441563935","full_name":"jsonfm/serialio","owner":"jsonfm","description":null,"archived":false,"fork":false,"pushed_at":"2021-12-25T15:38:17.000Z","size":6,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-25T13:47:02.873Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jsonfm.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,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-12-24T22:21:00.000Z","updated_at":"2021-12-25T15:38:20.000Z","dependencies_parsed_at":"2023-05-02T20:46:15.436Z","dependency_job_id":null,"html_url":"https://github.com/jsonfm/serialio","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/jsonfm/serialio","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jsonfm%2Fserialio","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jsonfm%2Fserialio/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jsonfm%2Fserialio/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jsonfm%2Fserialio/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jsonfm","download_url":"https://codeload.github.com/jsonfm/serialio/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jsonfm%2Fserialio/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":268629728,"owners_count":24281172,"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","status":"online","status_checked_at":"2025-08-03T02:00:12.545Z","response_time":2577,"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":[],"created_at":"2024-12-03T09:14:21.785Z","updated_at":"2025-08-03T23:41:04.374Z","avatar_url":"https://github.com/jsonfm.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SerialIO\n\nA serial library based on callbacks and threading.\n\n## Single Serial Device\nYou could run a single serial device as follows:\n```python\nfrom serialio import SerialEmitter\n\n\nserial = SerialEmitter(port='/dev/cu.usbserial-1460', baudrate='9600', timeout=0.25)\n\n# Do something if the connection status changes\nserial.on('connection-status', lambda status: print('serial port is open: ', status))\n\n# Do something if a new data were received\nserial.on('data-incoming', lambda data: print('received data: ', data))\n\n# Do something if a change occurs in the serial ports\nserial.on('ports-update', lambda ports: print('New devices detected: ', ports))\n\n# Start execution loop\nserial.start()\n```\nThe serial device has its own execution loop running on a thread.\n## Multiple Serial Devices\nAlso multiples serial devices cool be manage at the same time:\n```python\nfrom serialio import SerialManager\n\n\nserial = SerialManager(devices=['/dev/cu.usbserial-1460'], baudrate=9600, timeout=0.25)\n\n# Do something if the connection status changes\nserial.on('connection-status', lambda device, status: print(f'{device} connection status: {status}'))\n\n# Do something if a new data were received\nserial.on('data-incoming', lambda device, data: print(f'{device} has new data: {data}'))\n\n# Start all serial devices listed\nserial.startAll()\n```\n\n## License\nMIT","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjsonfm%2Fserialio","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjsonfm%2Fserialio","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjsonfm%2Fserialio/lists"}