kaxori / Button-Handler

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Button_Handler

Generates different click actions from button state changes.

Install

jag pkg install button_handler

examples

A simple usage example.

import gpio
import buttonHandler show *

main:
  pushButton := gpio.Pin GPIO_BUTTON --input --pull_up
  buttonHandler := ButtonHandler pushButton
    --singleClickAction= :: 
      print "CLICK"
  ...

See the examples folder for more examples.

Features and bugs

Please file feature requests and bugs at the issue tracker.

About

License:MIT License