{"id":18494852,"url":"https://github.com/johnelliott/waybot","last_synced_at":"2026-04-11T03:34:40.630Z","repository":{"id":73854674,"uuid":"87669660","full_name":"johnelliott/waybot","owner":"johnelliott","description":"🚲 📊 Arduino-powered, web-enabled DIY vehicle traffic counter","archived":false,"fork":false,"pushed_at":"2018-07-02T18:44:15.000Z","size":10900,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-14T03:14:58.930Z","etag":null,"topics":["ansible","arduino","data-capture","nodejs","raspberry-pi","serialport"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/johnelliott.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":"2017-04-08T23:09:22.000Z","updated_at":"2018-07-02T18:44:16.000Z","dependencies_parsed_at":"2023-05-12T06:30:49.818Z","dependency_job_id":null,"html_url":"https://github.com/johnelliott/waybot","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/johnelliott/waybot","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnelliott%2Fwaybot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnelliott%2Fwaybot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnelliott%2Fwaybot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnelliott%2Fwaybot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/johnelliott","download_url":"https://codeload.github.com/johnelliott/waybot/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnelliott%2Fwaybot/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31668049,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-10T17:19:37.612Z","status":"online","status_checked_at":"2026-04-11T02:00:05.776Z","response_time":54,"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":["ansible","arduino","data-capture","nodejs","raspberry-pi","serialport"],"created_at":"2024-11-06T13:22:26.940Z","updated_at":"2026-04-11T03:34:40.608Z","avatar_url":"https://github.com/johnelliott.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Waybot 📈\n\nA web app to monitor sensor data form [Waybot traffic counter](https://github.com/johnelliott/wb-counter).\n\n### About\nThis app tries to load fast by using small assets, compression and some initial markup and CSS before the react app starts. A service worker caches assets on supported clients.\n\n### System Diagram\n![diagram of waybot system](https://github.com/johnelliott/wb-web/blob/master/2016-system.jpeg \"Waybot system 2016\")\n\n### Origins\nThis app started as a way to experiment with node, websockets and chart libraries running  and ran locally with the counter connecting directly to the server process. Later I re-did most of the code to use PouchDB, redux and react on the client and deployed it to a cloud server. This required a serial-http bridge—[wb-upload](https://github.com/johnelliott/wb-upload)—to bring the data to the server.\n\n## Development\n- CouchDB is required for local development.\n- I used Let's Encrypt for TLS certificates. For local development on mac, add the certificates to the mac keychain app to satisfy the browser security settings—the green lock in the URL bar.\n\nCheck out [faker.sh](https://github.com/johnelliott/wb-web/blob/master/faker.sh) to see what the app might see from a traffic counter. This shows the data the app processes.\n\n## Deployment\nDeploy to a snowflake server with [Waybot deploy](https://github.com/johnelliott/wb-deploy).\n\nimagemagick/graphicsmagick for creating assets -\u003e [image-resizer.sh](https://github.com/johnelliott/wb-web/blob/master/image-resizer.sh)\ngzip for the compression npm scripts\n\n# Waybot config with Ansible (needs update)\n\n## Use\nUse with ansible 2.0+\n\nNo inventory or configuration file is committed. \nHosts in the example are configured with SSH.\n\n## Examples\nExample ansible inventory file `inventory`:\n```\n[edges]\nraspberry-pi\n\n[cloud]\nwb-cloud-server\n```\n\nExample ansible configuration file `ansible.cfg`:\n```\n[defaults]\nhostfile = inventory\n```\n\nExample playbook run for `edges` raspberry pi uploaders:\n```bash\nansible-playbook edges.yml --extra-vars='{\"api_host\":\"http://apihost.cool:1337/api\",\"serial_port\":\"/dev/ttyACM1\"}'\n```\nCan also use extra-vars.json file with `--extra-vars=@extra-vars.json` on the command line\n\nHere's how to specify app version from bash history:\n```bash\nap cloud.yml --extra-vars='{\"app_version\":\"skeumorphize\"}'\n```\n\nwow, so problems in NVM land and NPM module land\nalso how to to SSL in a smart way? `server_cert_path`\n\ndon't forget to template in symlinks to letsencrypt\n\n# CHIP notes\n I needed to install wireless tools and do https://github.com/fordsfords/wlan_pwr to try to adjust wlan power for power savings... this may need to go off in production\n\n/dev/ttyACM0 is the usb port with arduino\nchip $ lsusb on the chip confirms\nthirteen $ ap chips.yml --ask-become-pass to start installing node\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjohnelliott%2Fwaybot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjohnelliott%2Fwaybot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjohnelliott%2Fwaybot/lists"}