{"id":16883373,"url":"https://github.com/hardillb/node-red-contrib-flic-buttons","last_synced_at":"2025-04-11T11:51:46.435Z","repository":{"id":68666298,"uuid":"50384090","full_name":"hardillb/node-red-contrib-flic-buttons","owner":"hardillb","description":null,"archived":false,"fork":false,"pushed_at":"2020-01-07T16:34:07.000Z","size":19,"stargazers_count":17,"open_issues_count":4,"forks_count":9,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-03-25T08:11:17.160Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/hardillb.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":"2016-01-25T22:01:21.000Z","updated_at":"2022-08-01T05:03:13.000Z","dependencies_parsed_at":"2023-09-13T21:53:37.493Z","dependency_job_id":null,"html_url":"https://github.com/hardillb/node-red-contrib-flic-buttons","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/hardillb%2Fnode-red-contrib-flic-buttons","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hardillb%2Fnode-red-contrib-flic-buttons/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hardillb%2Fnode-red-contrib-flic-buttons/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hardillb%2Fnode-red-contrib-flic-buttons/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hardillb","download_url":"https://codeload.github.com/hardillb/node-red-contrib-flic-buttons/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248390525,"owners_count":21095818,"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":[],"created_at":"2024-10-13T16:11:29.978Z","updated_at":"2025-04-11T11:51:46.409Z","avatar_url":"https://github.com/hardillb.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# node-red-contrib-flic-buttons\n\nA Node-RED node to interact with the [flic.io][1] BLE buttons.\n\n## Installing Flic Daemon\nThis node requires the [fliclib-linux-hci][2] daemon to handle the low level comunication with the buttons. You will need to install this before you start:\n\n```\ngit clone https://github.com/50ButtonsEach/fliclib-linux-hci.git\n```\n\nyou can either start the daemon manually:\n\n```\ncd bin/armv6l/\nsudo ./flicd -f flic.sqlite3\n```\nor you can edit /etc/rc.local to start the daemon on boot:\n\n```\nsudo nano /etc/rc.local\n```\nAdd the following line just before the exit 0:\n```\nsleep 10 \u0026\u0026  /home/pi/git/fliclib-linux-hci/bin/armv6l/./flicd -d -l /var/log/flic.log  -f /home/pi/git/fliclib-linux-hci/bin/armv6l/flic.sqlite3 \u0026\n\n```\n(obviously change the paths to match where you have installed)\n## Pairing Buttons\n\nButtons need to be paired before you can use this node at the moment. We do this using the scanwizard.js located in the lib folder.\n\n - Ensure that the `daemon` are running\n - Ensure that any phones or other devices that your flic buttons were previously paired with are switched off or have bluetooth disabled\n - navigate to `node-red-contrib-flic-buttons/lib`\n - type the command `node scanwizard.js`\n - press your flic button\n - If it has previously been paired to another device you will have to hold the flic button down for 7 seconds to put it into public mode\n - once paired take a note of the bluetooth address\n - repeat this for all your flic button noting down the address for each button\n\n## Adding Buttons to Node-Red\n\nEach flic node requires you specify a button and a click type. The button is configured with a configuration node that can be shared amounst multiple flic nodes. For example one `Living Room` button might be configured but one node will use the `SingleClick` event and another will use the `Hold` event.\n\nThe button config node takes the following parameters:\n\n - Host - this is the host running the flic.io daemon process, defaults to localhost\n - Port - the port for the daemon process, defaults to 5551\n - Button Address - the bluetooth address that you noted down when pairing your buttons\n\nThe node emits a `msg.payload` that looks like this\n```\n{\n  \"deviceId\":\"80:E4:DA:70:XX:XX\",\n  \"queued\":true,\n  \"timeDiff\":0,\n  \"clickType\":\"ButtonDown\"\n}\n```\n\nClickType can be: `ButtonDown`,`ButtonUp`,`ButtonClick`,`ButtonSingleClick`,`ButtonDoubleClick`,`ButtonHold`.\n\n[1]: https://flic.io/?r=985093\n[2]: https://github.com/50ButtonsEach/fliclib-linux-hci\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhardillb%2Fnode-red-contrib-flic-buttons","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhardillb%2Fnode-red-contrib-flic-buttons","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhardillb%2Fnode-red-contrib-flic-buttons/lists"}