boneIO 0.9.0.dev9__tar.gz → 0.9.0.dev12__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/PKG-INFO +1 -1
- boneio-0.9.0.dev12/boneio/helper/schema_converter.py +200 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/oled.py +8 -6
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/runner.py +52 -5
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/schema/filters.yaml +2 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/schema/schema.yaml +42 -29
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/schema/update_interval.yaml +1 -1
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/sensor/gpio_new.py +3 -2
- boneio-0.9.0.dev12/boneio/version.py +2 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/adc.schema.json +107 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/abap-BrgZPUOV.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/apex-DyP6w7ZV.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/azcli-BaLxmfj-.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/bat-CFOPXBzS.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/bicep-BfEKNvv3.js +7 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/cameligo-BFG1Mk7z.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/clojure-DTECt2xU.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/codicon-DCmgc-ay.ttf +0 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/coffee-CDGzqUPQ.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/cpp-CLLBncYj.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/csharp-dUCx_-0o.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/csp-5Rap-vPy.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/css-D3h14YRZ.js +8 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/cssMode-C6WOe53z.js +9 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/cypher-DrQuvNYM.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/dart-CFKIUWau.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/dockerfile-Zznr-cwX.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/ecl-Ce3n6wWz.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/elixir-deUWdS0T.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/flow9-i9-g7ZhI.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/freemarker2-Chb0HRQK.js +8 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/fsharp-CzKuDChf.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/go-Cphgjts3.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/graphql-Cg7bfA9N.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/handlebars-BotqKFhK.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/hcl-0cvrggvQ.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/html-BUffd9h5.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/htmlMode-DGiHOMs2.js +9 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/index-CCgG6NMg.css +1 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/index-Dd5fmLR2.js +825 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/ini-Drc7WvVn.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/java-B_fMsGYe.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/javascript-t9M9489U.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/jsonMode-C35_b2Ms.js +15 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/julia-Bqgm2twL.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/kotlin-BSkB5QuD.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/less-BsTHnhdd.js +7 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/lexon-YWi4-JPR.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/liquid-C7SecqiU.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/lua-nf6ki56Z.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/m3-Cpb6xl2v.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/markdown-DSZPf7rp.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/mdx-BEFGzID8.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/mips-B_c3zf-v.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/msdax-rUNN04Wq.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/mysql-DDwshQtU.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/objective-c-B5zXfXm9.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/pascal-CXOwvkN_.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/pascaligo-Bc-ZgV77.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/perl-CwNk8-XU.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/pgsql-tGk8EFnU.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/php-CpIb_Oan.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/pla-B03wrqEc.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/postiats-BKlk5iyT.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/powerquery-Bhzvs7bI.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/powershell-Dd3NCNK9.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/protobuf-COyEY5Pt.js +7 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/pug-BaJupSGV.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/python-BsskM_ld.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/qsharp-DXyYeYxl.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/r-CdQndTaG.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/razor-D_hKeI4x.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/redis-CVwtpugi.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/redshift-25W9uPmb.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/restructuredtext-DfzH4Xui.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/ruby-Cp1zYvxS.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/rust-D5C2fndG.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/sb-CDntyWJ8.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/scala-BoFRg7Ot.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/scheme-Bio4gycK.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/scss-4Ik7cdeQ.js +8 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/shell-CX-rkNHf.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/solidity-Tw7wswEv.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/sophia-C5WLch3f.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/sparql-DHaeiCBh.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/sql-CCSDG5nI.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/st-pnP8ivHi.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/swift-DwJ7jVG9.js +8 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/systemverilog-B9Xyijhd.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/tcl-DnHyzjbg.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/tsMode-CsV3zhd6.js +16 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/twig-CPajHgWi.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/typescript-Cw5sooqS.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/typespec-D-MeaMDU.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/vb-DgyLZaXg.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/wgsl-BIv9DU6q.js +303 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/xml-0KgE2q9x.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/yaml-BXwpGS5c.js +6 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/assets/yaml.worker-C2uymlqn.js +476 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/binary_sensor.schema.json +403 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/boneio.schema.json +44 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/config.schema.json +2423 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/cover.schema.json +138 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/dallas.schema.json +27 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/ds2482.schema.json +39 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/event.schema.json +445 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/ina219.schema.json +119 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/webui/frontend-dist/index.html +2 -2
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/lm75.schema.json +82 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/logger.schema.json +47 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/mcp23017.schema.json +51 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/mcp9808.schema.json +83 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/modbus.schema.json +80 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/modbus_sensors.schema.json +128 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/mqtt.schema.json +103 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/oled.schema.json +130 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/output.schema.json +156 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/output_group.schema.json +79 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/pca9685.schema.json +51 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/pcf8575.schema.json +51 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/sensor.schema.json +129 -0
- boneio-0.9.0.dev12/boneio/webui/frontend-dist/web.schema.json +54 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/webui/web_server.py +14 -3
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/pyproject.toml +1 -1
- boneio-0.9.0.dev9/boneio/version.py +0 -2
- boneio-0.9.0.dev9/boneio/webui/frontend-dist/assets/css.worker-YzWC8yAR.js +0 -84
- boneio-0.9.0.dev9/boneio/webui/frontend-dist/assets/html.worker-D5NPIcdM.js +0 -461
- boneio-0.9.0.dev9/boneio/webui/frontend-dist/assets/index-Bzix_ULo.js +0 -72
- boneio-0.9.0.dev9/boneio/webui/frontend-dist/assets/index-Dt_UdFzp.css +0 -1
- boneio-0.9.0.dev9/boneio/webui/frontend-dist/assets/ts.worker-BSchkg-h.js +0 -51334
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/LICENSE +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/README.md +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/__init__.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/boards/0.7/input.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/boards/0.7/output_32_10.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/boards/0.8/input.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/boards/0.8/output_32_10.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/bonecli.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/const.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/cover.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/example_config/__init__.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/example_config/adc.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/example_config/binary_sensor.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/example_config/binary_sensor_v_0_7.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/example_config/config.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/example_config/cover.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/example_config/event.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/example_config/event_all.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/example_config/event_v_0_7.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/example_config/led32x4A.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/example_config/output24x16A.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/example_config/output24x16A_v0.3.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/example_config/output32x10A.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/example_config/output32x5A.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/fonts/danube__.ttf +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/group/__init__.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/group/output.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/__init__.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/async_updater.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/click_timer.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/config.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/events.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/exceptions.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/filter.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/gpio.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/gpiod.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/ha_discovery.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/loader.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/logger.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/message_bus.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/mqtt.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/oled.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/onewire/W1ThermSensor.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/onewire/__init__.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/onewire/ds2482.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/onewire/onewire.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/pcf8575.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/queue.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/sensor/ina_219_smbus.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/state_manager.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/stats.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/timeperiod.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/util.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/helper/yaml_util.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/input/__init__.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/input/gpio.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/input/gpio_new.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/manager.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/__init__.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/client.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/cwt.json +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/dts1964_3f.json +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/liquid-sensor.json +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/modbuscli.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/orno-or-we-517.json +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/pt100.json +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/r4dcb08.json +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/sdm120.json +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/sdm630.json +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/sensor.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/sht20.json +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/sht30.json +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/single_sensor.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/socomec_e03.json +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/socomec_e23.json +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/sofar.json +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/modbus/utils.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/models/__init__.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/models/files.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/models/logs.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/mqtt_client.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/relay/__init__.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/relay/basic.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/relay/gpio.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/relay/mcp.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/relay/pca.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/relay/pcf.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/schema/actions.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/schema/actions_sensor.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/schema/actions_switch.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/schema/filters_adc.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/schema/id.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/schema/temp_unit.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/sensor/__init__.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/sensor/adc.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/sensor/gpio.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/sensor/ina219.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/sensor/serial_number.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/sensor/temp/__init__.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/sensor/temp/dallas.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/sensor/temp/lm75.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/sensor/temp/mcp9808.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/webui/app.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/webui/frontend-dist/assets/editor.worker-D5ngByhL.js +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/webui/frontend-dist/assets/json.worker-F0ZGA5Zk.js +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/webui/frontend-dist/boneio.svg +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/webui/frontend-dist/boneio_fav.svg +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/boneio/webui/websocket_manager.py +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/tests/32_5_config.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/tests/bandit.yaml +0 -0
- {boneio-0.9.0.dev9 → boneio-0.9.0.dev12}/tests/relay_32_5.py +0 -0
|
@@ -0,0 +1,200 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
import json
|
|
4
|
+
import os
|
|
5
|
+
from typing import Any, Dict, List, Union
|
|
6
|
+
|
|
7
|
+
import yaml
|
|
8
|
+
from yaml import SafeLoader, load
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
class BoneIOLoader(SafeLoader):
|
|
12
|
+
"""Custom YAML loader with !include constructor."""
|
|
13
|
+
|
|
14
|
+
def __init__(self, stream):
|
|
15
|
+
self._root = os.path.split(stream.name)[0]
|
|
16
|
+
super().__init__(stream)
|
|
17
|
+
|
|
18
|
+
def include(self, node):
|
|
19
|
+
"""Include file referenced at node."""
|
|
20
|
+
filename = os.path.join(self._root, self.construct_scalar(node))
|
|
21
|
+
with open(filename, 'r') as f:
|
|
22
|
+
return load(f, BoneIOLoader)
|
|
23
|
+
|
|
24
|
+
# Register the !include constructor
|
|
25
|
+
BoneIOLoader.add_constructor('!include', BoneIOLoader.include)
|
|
26
|
+
|
|
27
|
+
def convert_type(cerberus_type: Union[str, List[str]]) -> Union[str, List[str]]:
|
|
28
|
+
"""Convert Cerberus type to JSON Schema type."""
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
type_map = {
|
|
32
|
+
'string': 'string',
|
|
33
|
+
'integer': 'integer',
|
|
34
|
+
'float': 'number',
|
|
35
|
+
'boolean': 'boolean',
|
|
36
|
+
'dict': 'object',
|
|
37
|
+
'list': 'array'
|
|
38
|
+
}
|
|
39
|
+
if isinstance(cerberus_type, list):
|
|
40
|
+
return [type_map.get(type, 'string') for type in cerberus_type]
|
|
41
|
+
return type_map.get(cerberus_type, 'string')
|
|
42
|
+
|
|
43
|
+
def create_boolean_schema() -> Dict[str, Any]:
|
|
44
|
+
"""Create a schema that accepts both boolean and boolean-like string values."""
|
|
45
|
+
return {
|
|
46
|
+
"oneOf": [
|
|
47
|
+
{"type": "boolean"},
|
|
48
|
+
{
|
|
49
|
+
"type": "string",
|
|
50
|
+
"enum": ["yes", "no", "true", "false", "on", "off"],
|
|
51
|
+
"x-yaml-boolean": True
|
|
52
|
+
}
|
|
53
|
+
]
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
def convert_cerberus_to_json_schema(cerberus_schema: Dict[str, Any]) -> Dict[str, Any]:
|
|
57
|
+
"""Convert a Cerberus schema to JSON Schema format."""
|
|
58
|
+
json_schema = {
|
|
59
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
60
|
+
"type": "object",
|
|
61
|
+
"properties": {},
|
|
62
|
+
"required": []
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
for field, schema in cerberus_schema.items():
|
|
66
|
+
if not isinstance(schema, dict):
|
|
67
|
+
continue
|
|
68
|
+
|
|
69
|
+
field_schema = {}
|
|
70
|
+
|
|
71
|
+
# Handle type conversion, nullable and !include
|
|
72
|
+
if "type" in schema:
|
|
73
|
+
if schema["type"] == "boolean":
|
|
74
|
+
field_schema.update(create_boolean_schema())
|
|
75
|
+
else:
|
|
76
|
+
base_type = convert_type(schema["type"])
|
|
77
|
+
types = ["string"] # Always allow string for !include
|
|
78
|
+
if isinstance(base_type, list):
|
|
79
|
+
types.extend(base_type)
|
|
80
|
+
else:
|
|
81
|
+
types.append(base_type)
|
|
82
|
+
if schema.get("nullable", False):
|
|
83
|
+
types.append("null")
|
|
84
|
+
field_schema["type"] = types
|
|
85
|
+
|
|
86
|
+
# Handle required fields - only if required and no default
|
|
87
|
+
if schema.get("required", False) and "default" not in schema:
|
|
88
|
+
json_schema["required"].append(field)
|
|
89
|
+
|
|
90
|
+
# Handle default values
|
|
91
|
+
if "default" in schema:
|
|
92
|
+
field_schema["default"] = schema["default"]
|
|
93
|
+
|
|
94
|
+
# Handle nested dictionaries and arrays
|
|
95
|
+
if "schema" in schema and isinstance(schema["schema"], dict):
|
|
96
|
+
if schema.get("type") == "dict":
|
|
97
|
+
types = ["string", "object"] # Allow both string for !include and object
|
|
98
|
+
if schema.get("nullable", False):
|
|
99
|
+
types.append("null")
|
|
100
|
+
field_schema["type"] = types
|
|
101
|
+
field_schema["properties"] = {}
|
|
102
|
+
nested_required = []
|
|
103
|
+
|
|
104
|
+
for nested_field, nested_schema in schema["schema"].items():
|
|
105
|
+
field_schema["properties"][nested_field] = convert_cerberus_to_json_schema(
|
|
106
|
+
{nested_field: nested_schema}
|
|
107
|
+
)["properties"][nested_field]
|
|
108
|
+
# Only add to required if the field is required and has no default
|
|
109
|
+
if nested_schema.get("required", False) and "default" not in nested_schema:
|
|
110
|
+
nested_required.append(nested_field)
|
|
111
|
+
|
|
112
|
+
if nested_required:
|
|
113
|
+
field_schema["required"] = nested_required
|
|
114
|
+
|
|
115
|
+
elif schema.get("type") == "list":
|
|
116
|
+
types = ["string", "array"] # Allow both string for !include and array
|
|
117
|
+
if schema.get("nullable", False):
|
|
118
|
+
types.append("null")
|
|
119
|
+
field_schema["type"] = types
|
|
120
|
+
if isinstance(schema["schema"], dict):
|
|
121
|
+
field_schema["items"] = convert_cerberus_to_json_schema(
|
|
122
|
+
{"item": schema["schema"]}
|
|
123
|
+
)["properties"]["item"]
|
|
124
|
+
|
|
125
|
+
# Handle allowed values (enum)
|
|
126
|
+
if "allowed" in schema:
|
|
127
|
+
if schema.get("type") == "list":
|
|
128
|
+
if "items" not in field_schema:
|
|
129
|
+
field_schema["items"] = {}
|
|
130
|
+
field_schema["items"]["enum"] = schema["allowed"]
|
|
131
|
+
# Add examples for better IDE support
|
|
132
|
+
field_schema["items"]["examples"] = [schema["allowed"][0]] if schema["allowed"] else []
|
|
133
|
+
else:
|
|
134
|
+
field_schema["enum"] = schema["allowed"]
|
|
135
|
+
# Add examples for better IDE support
|
|
136
|
+
field_schema["examples"] = [schema["allowed"][0]] if schema["allowed"] else []
|
|
137
|
+
|
|
138
|
+
# Handle descriptions from meta
|
|
139
|
+
if "meta" in schema and isinstance(schema["meta"], dict):
|
|
140
|
+
if "label" in schema["meta"]:
|
|
141
|
+
field_schema["description"] = schema["meta"]["label"]
|
|
142
|
+
# Add title for better IDE support
|
|
143
|
+
field_schema["title"] = field.replace("_", " ").capitalize()
|
|
144
|
+
|
|
145
|
+
json_schema["properties"][field] = field_schema
|
|
146
|
+
|
|
147
|
+
# Remove required array if empty
|
|
148
|
+
if not json_schema["required"]:
|
|
149
|
+
del json_schema["required"]
|
|
150
|
+
|
|
151
|
+
return json_schema
|
|
152
|
+
|
|
153
|
+
def generate_section_schema(section_name: str, section_schema: Dict[str, Any]) -> Dict[str, Any]:
|
|
154
|
+
"""Generate a schema for a specific section."""
|
|
155
|
+
if section_schema.get("type") == "array":
|
|
156
|
+
# For array types, use the items schema directly
|
|
157
|
+
return {
|
|
158
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
159
|
+
**convert_cerberus_to_json_schema({section_name: section_schema})["properties"][section_name]
|
|
160
|
+
}
|
|
161
|
+
else:
|
|
162
|
+
# For object types, wrap in an object schema
|
|
163
|
+
return {
|
|
164
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
165
|
+
"type": "object",
|
|
166
|
+
"properties": {
|
|
167
|
+
section_name: convert_cerberus_to_json_schema({section_name: section_schema})["properties"][section_name]
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
def main():
|
|
172
|
+
"""Main function to convert schema."""
|
|
173
|
+
script_dir = os.path.dirname(os.path.abspath(__file__))
|
|
174
|
+
schema_file = os.path.join(script_dir, "..", "schema", "schema.yaml")
|
|
175
|
+
output_dir = os.path.join(script_dir, "..", "..", "frontend", "public")
|
|
176
|
+
|
|
177
|
+
# Create output directory if it doesn't exist
|
|
178
|
+
os.makedirs(output_dir, exist_ok=True)
|
|
179
|
+
|
|
180
|
+
# Load the schema
|
|
181
|
+
with open(schema_file, "r") as f:
|
|
182
|
+
schema = yaml.load(f, Loader=BoneIOLoader)
|
|
183
|
+
|
|
184
|
+
# Convert and save the main schema
|
|
185
|
+
json_schema = convert_cerberus_to_json_schema(schema)
|
|
186
|
+
main_schema_file = os.path.join(output_dir, "config.schema.json")
|
|
187
|
+
with open(main_schema_file, "w") as f:
|
|
188
|
+
json.dump(json_schema, f, indent=2)
|
|
189
|
+
print(f"Schema written to {main_schema_file}")
|
|
190
|
+
|
|
191
|
+
# Generate and save section-specific schemas
|
|
192
|
+
for section_name, section_schema in schema.items():
|
|
193
|
+
section_json_schema = generate_section_schema(section_name, section_schema)
|
|
194
|
+
section_schema_file = os.path.join(output_dir, f"{section_name}.schema.json")
|
|
195
|
+
with open(section_schema_file, "w") as f:
|
|
196
|
+
json.dump(section_json_schema, f, indent=2)
|
|
197
|
+
print(f"Section schema for {section_name} written to {section_schema_file}")
|
|
198
|
+
|
|
199
|
+
if __name__ == "__main__":
|
|
200
|
+
main()
|
|
@@ -293,13 +293,15 @@ class Oled:
|
|
|
293
293
|
display_image = Image.new("1", (128, 64), 0) # Mode 1, size 128x64, black background
|
|
294
294
|
draw = ImageDraw.Draw(display_image)
|
|
295
295
|
|
|
296
|
-
# Add title text
|
|
297
|
-
|
|
298
|
-
draw.text((2, 2),
|
|
296
|
+
# Add title text on the left side
|
|
297
|
+
# text_width = fonts["small"].getsize(title)[0]
|
|
298
|
+
draw.text((2, 2), "Scan to", font=fonts["small"], fill=WHITE)
|
|
299
|
+
draw.text((2, 12), "access", font=fonts["small"], fill=WHITE)
|
|
300
|
+
draw.text((2, 22), "webui", font=fonts["small"], fill=WHITE)
|
|
299
301
|
|
|
300
|
-
# Calculate position to
|
|
301
|
-
x =
|
|
302
|
-
y = ((64 - qr_image.size[1]) // 2)
|
|
302
|
+
# Calculate position to align QR code to right and center vertically
|
|
303
|
+
x = 128 - qr_image.size[0] - 2 # Align to right with 2 pixels padding
|
|
304
|
+
y = ((64 - qr_image.size[1]) // 2) # Center vertically
|
|
303
305
|
|
|
304
306
|
# Paste QR code onto center of display image
|
|
305
307
|
display_image.paste(qr_image, (x, y))
|
|
@@ -5,6 +5,7 @@ from __future__ import annotations
|
|
|
5
5
|
import asyncio
|
|
6
6
|
import logging
|
|
7
7
|
import os
|
|
8
|
+
import signal
|
|
8
9
|
import warnings
|
|
9
10
|
from typing import Any, Set
|
|
10
11
|
|
|
@@ -76,6 +77,17 @@ async def async_run(
|
|
|
76
77
|
web_server = None
|
|
77
78
|
tasks: Set[asyncio.Task] = set()
|
|
78
79
|
event_bus = EventBus(loop=asyncio.get_event_loop())
|
|
80
|
+
shutdown_event = asyncio.Event()
|
|
81
|
+
loop = asyncio.get_event_loop()
|
|
82
|
+
|
|
83
|
+
def signal_handler():
|
|
84
|
+
"""Handle shutdown signals."""
|
|
85
|
+
_LOGGER.info("Received shutdown signal, initiating graceful shutdown...")
|
|
86
|
+
shutdown_event.set()
|
|
87
|
+
|
|
88
|
+
# Register signal handlers
|
|
89
|
+
for sig in (signal.SIGTERM, signal.SIGINT):
|
|
90
|
+
loop.add_signal_handler(sig, signal_handler)
|
|
79
91
|
|
|
80
92
|
event_bus_task = asyncio.create_task(event_bus.start())
|
|
81
93
|
tasks.add(event_bus_task)
|
|
@@ -134,14 +146,13 @@ async def async_run(
|
|
|
134
146
|
|
|
135
147
|
tasks.update(manager.get_tasks())
|
|
136
148
|
|
|
137
|
-
|
|
138
149
|
message_bus_type = "MQTT" if isinstance(message_bus, MQTTClient) else "Local"
|
|
139
150
|
_LOGGER.info("Starting message bus %s.", message_bus_type)
|
|
140
151
|
message_bus_task = asyncio.create_task(message_bus.start_client())
|
|
141
152
|
tasks.add(message_bus_task)
|
|
142
153
|
message_bus_task.add_done_callback(tasks.discard)
|
|
143
154
|
|
|
144
|
-
|
|
155
|
+
# Start web server if configured
|
|
145
156
|
if "web" in config:
|
|
146
157
|
web_config = config.get("web") or {}
|
|
147
158
|
_LOGGER.info("Starting Web server.")
|
|
@@ -159,15 +170,51 @@ async def async_run(
|
|
|
159
170
|
web_server_task.add_done_callback(tasks.discard)
|
|
160
171
|
else:
|
|
161
172
|
_LOGGER.info("Web server not configured.")
|
|
173
|
+
|
|
162
174
|
try:
|
|
163
|
-
|
|
175
|
+
# Convert tasks set to list for main gather
|
|
176
|
+
task_list = list(tasks)
|
|
177
|
+
main_gather = asyncio.gather(*task_list)
|
|
178
|
+
|
|
179
|
+
# Wait for either shutdown signal or main task completion
|
|
180
|
+
await asyncio.wait([
|
|
181
|
+
main_gather,
|
|
182
|
+
asyncio.create_task(shutdown_event.wait())
|
|
183
|
+
], return_when=asyncio.FIRST_COMPLETED)
|
|
184
|
+
|
|
185
|
+
if shutdown_event.is_set():
|
|
186
|
+
_LOGGER.info("Starting graceful shutdown...")
|
|
187
|
+
main_gather.cancel()
|
|
188
|
+
try:
|
|
189
|
+
await main_gather
|
|
190
|
+
except asyncio.CancelledError:
|
|
191
|
+
pass
|
|
192
|
+
|
|
164
193
|
return 0
|
|
165
194
|
except asyncio.CancelledError:
|
|
166
|
-
|
|
195
|
+
_LOGGER.info("Main task cancelled")
|
|
167
196
|
except (RestartRequestException, GracefulExit):
|
|
168
|
-
|
|
197
|
+
_LOGGER.info("Restart or graceful exit requested")
|
|
169
198
|
except Exception as e:
|
|
170
199
|
_LOGGER.error(f"Unexpected error: {type(e).__name__} - {e}")
|
|
171
200
|
finally:
|
|
201
|
+
_LOGGER.info("Cleaning up resources...")
|
|
202
|
+
# Stop the event bus
|
|
172
203
|
event_bus.request_stop()
|
|
204
|
+
|
|
205
|
+
# Create a copy of tasks set to avoid modification during iteration
|
|
206
|
+
remaining_tasks = list(tasks)
|
|
207
|
+
if remaining_tasks:
|
|
208
|
+
# Cancel and wait for all remaining tasks
|
|
209
|
+
for task in remaining_tasks:
|
|
210
|
+
if not task.done():
|
|
211
|
+
task.cancel()
|
|
212
|
+
|
|
213
|
+
# Wait for all tasks to complete
|
|
214
|
+
try:
|
|
215
|
+
await asyncio.gather(*remaining_tasks, return_exceptions=True)
|
|
216
|
+
except Exception as e:
|
|
217
|
+
_LOGGER.error(f"Error during cleanup: {type(e).__name__} - {e}")
|
|
218
|
+
|
|
219
|
+
_LOGGER.info("Shutdown complete")
|
|
173
220
|
return 0
|
|
@@ -2,7 +2,7 @@ mqtt:
|
|
|
2
2
|
type: dict
|
|
3
3
|
required: True
|
|
4
4
|
meta:
|
|
5
|
-
label: Mqtt section
|
|
5
|
+
label: "https://boneio.eu/docs/black/configuration/mqtt \n Mqtt section of boneIO Black configuration file. It handled connecting to mqtt broker, which then is connected to Home Assistant or other smart home system."
|
|
6
6
|
schema:
|
|
7
7
|
host:
|
|
8
8
|
required: True
|
|
@@ -30,7 +30,7 @@ mqtt:
|
|
|
30
30
|
default: boneIO
|
|
31
31
|
required: True
|
|
32
32
|
meta:
|
|
33
|
-
label: Prefix topic for boneIO to use.
|
|
33
|
+
label: Prefix topic for boneIO to use. If not set, then it will be set to name of the device from boneio section, otherwise set to boneIO.
|
|
34
34
|
ha_discovery:
|
|
35
35
|
type: dict
|
|
36
36
|
meta:
|
|
@@ -53,7 +53,7 @@ web:
|
|
|
53
53
|
required: False
|
|
54
54
|
nullable: True
|
|
55
55
|
meta:
|
|
56
|
-
label: Web section
|
|
56
|
+
label: "https://boneio.eu/docs/black/0.9.x-dev/configuration/web \n Web section of boneIO Black. It enables web interface. Default on port 8090."
|
|
57
57
|
schema:
|
|
58
58
|
port:
|
|
59
59
|
required: False
|
|
@@ -83,6 +83,8 @@ web:
|
|
|
83
83
|
logger:
|
|
84
84
|
type: dict
|
|
85
85
|
required: False
|
|
86
|
+
meta:
|
|
87
|
+
label: "https://boneio.eu/docs/black/configuration/logger \n Logger section of boneIO Black. It enables logging level. If run as systemd service, then it will log to journal. If not, then it will log to /tmp/boneio.log"
|
|
86
88
|
schema:
|
|
87
89
|
default:
|
|
88
90
|
type: string
|
|
@@ -98,12 +100,14 @@ logger:
|
|
|
98
100
|
coerce: lower # Convert to lowercase for all values
|
|
99
101
|
allowed: ['critical', 'error', 'warning', 'info', 'debug', 'CRITICAL', 'ERROR', 'WARNING', 'INFO', 'DEBUG']
|
|
100
102
|
meta:
|
|
101
|
-
label:
|
|
103
|
+
label: "Each line suppose to have one python module name and logging level eg pymodbus.client: INFO."
|
|
102
104
|
|
|
103
105
|
oled:
|
|
104
106
|
type: dict
|
|
105
107
|
default: {}
|
|
106
108
|
required: True
|
|
109
|
+
meta:
|
|
110
|
+
label: "https://boneio.eu/docs/black/configuration/oled \n Oled section of boneIO Black. It enables oled screen. You'd need enabled: true to make it work."
|
|
107
111
|
schema:
|
|
108
112
|
enabled:
|
|
109
113
|
type: boolean
|
|
@@ -176,6 +180,8 @@ oled:
|
|
|
176
180
|
modbus:
|
|
177
181
|
type: dict
|
|
178
182
|
required: False
|
|
183
|
+
meta:
|
|
184
|
+
label: "https://boneio.eu/docs/black/configuration/modbus \n Modbus section of boneIO Black. It enables modbus support. You define on which uart it modbus defined. For new boneIO it is uart4. For old boneIO it is uart1."
|
|
179
185
|
schema:
|
|
180
186
|
uart:
|
|
181
187
|
type: string
|
|
@@ -202,7 +208,7 @@ modbus_sensors:
|
|
|
202
208
|
type: list
|
|
203
209
|
required: False
|
|
204
210
|
meta:
|
|
205
|
-
label:
|
|
211
|
+
label: "https://boneio.eu/docs/black/configuration/modbus-sensors \n List of modbus sensors. You can use predefined modbus sensors. It would fetch data from them and publish to mqtt."
|
|
206
212
|
schema:
|
|
207
213
|
type: dict
|
|
208
214
|
schema:
|
|
@@ -226,14 +232,19 @@ modbus_sensors:
|
|
|
226
232
|
- lower
|
|
227
233
|
allowed:
|
|
228
234
|
[
|
|
229
|
-
'
|
|
235
|
+
'cwt',
|
|
236
|
+
'dts1964_3f',
|
|
237
|
+
'liquid-sensor',
|
|
238
|
+
'orno-or-we-517',
|
|
239
|
+
'pt100',
|
|
240
|
+
'r4dcb08',
|
|
230
241
|
'sdm120',
|
|
231
|
-
'
|
|
242
|
+
'sdm630',
|
|
243
|
+
'sht20',
|
|
244
|
+
'sht30',
|
|
232
245
|
'socomec_e03',
|
|
233
246
|
'socomec_e23',
|
|
234
|
-
'
|
|
235
|
-
'orno-or-we-517',
|
|
236
|
-
'r4cb08'
|
|
247
|
+
'sofar',
|
|
237
248
|
]
|
|
238
249
|
meta:
|
|
239
250
|
label: Model to load from database.
|
|
@@ -260,16 +271,14 @@ lm75:
|
|
|
260
271
|
type: list
|
|
261
272
|
required: False
|
|
262
273
|
meta:
|
|
263
|
-
label: LM75 Sensor list.
|
|
274
|
+
label: "https://boneio.eu/docs/black/configuration/lm75 \n LM75 Sensor list. All boneIO Black has one LM75 on board."
|
|
264
275
|
schema:
|
|
265
276
|
type: dict
|
|
266
277
|
required: False
|
|
267
278
|
schema:
|
|
268
279
|
id: !include id.yaml
|
|
269
280
|
address:
|
|
270
|
-
type:
|
|
271
|
-
- string
|
|
272
|
-
- integer
|
|
281
|
+
type: integer
|
|
273
282
|
required: True
|
|
274
283
|
default: 0x48
|
|
275
284
|
meta:
|
|
@@ -282,7 +291,7 @@ ina219:
|
|
|
282
291
|
type: list
|
|
283
292
|
required: False
|
|
284
293
|
meta:
|
|
285
|
-
label: INA219 Sensor list.
|
|
294
|
+
label: "https://boneio.eu/docs/black/configuration/ina219 \n INA219 Sensor list. All boneIO Black has one INA219 on board, which measures current, voltage and power of boneIO board."
|
|
286
295
|
schema:
|
|
287
296
|
type: dict
|
|
288
297
|
required: False
|
|
@@ -321,7 +330,7 @@ mcp9808:
|
|
|
321
330
|
type: list
|
|
322
331
|
required: False
|
|
323
332
|
meta:
|
|
324
|
-
label: MCP9808 Sensor list.
|
|
333
|
+
label: "https://boneio.eu/docs/black/configuration/mcp9808 \n MCP9808 Sensor list. Older boneIO Black had one MCP9808 instead of LM75on board, which measures temperature."
|
|
325
334
|
schema:
|
|
326
335
|
type: dict
|
|
327
336
|
required: False
|
|
@@ -343,7 +352,7 @@ mcp23017:
|
|
|
343
352
|
type: list
|
|
344
353
|
required: False
|
|
345
354
|
meta:
|
|
346
|
-
label: mcp23017 Pin config
|
|
355
|
+
label: "https://boneio.eu/docs/black/configuration/mcp23017 \n MCP23017 Pin config. All boneIO Black 32X10/Cover/Cover Mix/24x16 has two MCP23017 on board. If you use new boneio: section, then you don't need to define this."
|
|
347
356
|
schema:
|
|
348
357
|
type: dict
|
|
349
358
|
schema:
|
|
@@ -369,7 +378,7 @@ pcf8575:
|
|
|
369
378
|
type: list
|
|
370
379
|
required: False
|
|
371
380
|
meta:
|
|
372
|
-
label: pcf8575 Pin config
|
|
381
|
+
label: "https://boneio.eu/docs/black/configuration/pcf8575 \n PCF8575 Pin config. UNSTABLE."
|
|
373
382
|
schema:
|
|
374
383
|
type: dict
|
|
375
384
|
schema:
|
|
@@ -395,7 +404,7 @@ pca9685:
|
|
|
395
404
|
type: list
|
|
396
405
|
required: False
|
|
397
406
|
meta:
|
|
398
|
-
label: pca9685 Pin config
|
|
407
|
+
label: "https://boneio.eu/docs/black/configuration/pca9685 \n PCA9685 Pin config."
|
|
399
408
|
schema:
|
|
400
409
|
type: dict
|
|
401
410
|
schema:
|
|
@@ -420,7 +429,7 @@ pca9685:
|
|
|
420
429
|
output:
|
|
421
430
|
type: list
|
|
422
431
|
meta:
|
|
423
|
-
label: List of
|
|
432
|
+
label: "https://boneio.eu/docs/black/configuration/output \n List of outputs to define."
|
|
424
433
|
check_with: output_id_uniqueness
|
|
425
434
|
schema:
|
|
426
435
|
type: dict
|
|
@@ -505,7 +514,7 @@ output:
|
|
|
505
514
|
output_group:
|
|
506
515
|
type: list
|
|
507
516
|
meta:
|
|
508
|
-
label: List of groupes outputs
|
|
517
|
+
label: "https://boneio.eu/docs/black/configuration/output_group \n List of groupes outputs to define. Output has to be defined first in output section!"
|
|
509
518
|
check_with: output_id_uniqueness
|
|
510
519
|
schema:
|
|
511
520
|
type: dict
|
|
@@ -539,7 +548,7 @@ output_group:
|
|
|
539
548
|
binary_sensor:
|
|
540
549
|
type: list
|
|
541
550
|
meta:
|
|
542
|
-
label: GPIO
|
|
551
|
+
label: "https://boneio.eu/docs/black/configuration/binary \n GPIO binary section of boneIO Black. It enables binary sensors in HA. It detects press and release states. It can run action based on states. It always send message to MQTT broker of invoked state."
|
|
543
552
|
schema:
|
|
544
553
|
type: dict
|
|
545
554
|
schema:
|
|
@@ -651,7 +660,7 @@ binary_sensor:
|
|
|
651
660
|
event:
|
|
652
661
|
type: list
|
|
653
662
|
meta:
|
|
654
|
-
label: GPIO
|
|
663
|
+
label: "https://boneio.eu/docs/black/configuration/event \n GPIO event entity section of boneIO Black. It enables event entities in HA. It detects single, double and long click. It can run action based on states. It always send message to MQTT broker of invoked state."
|
|
655
664
|
schema:
|
|
656
665
|
type: dict
|
|
657
666
|
schema:
|
|
@@ -729,7 +738,7 @@ event:
|
|
|
729
738
|
adc:
|
|
730
739
|
type: list
|
|
731
740
|
meta:
|
|
732
|
-
label: GPIO ADC section
|
|
741
|
+
label: "https://boneio.eu/docs/black/configuration/adc \n GPIO ADC section of boneIO Black. It enables ADC sensors in HA. Don't let them hang without use."
|
|
733
742
|
schema:
|
|
734
743
|
type: dict
|
|
735
744
|
schema:
|
|
@@ -756,7 +765,7 @@ cover:
|
|
|
756
765
|
type: list
|
|
757
766
|
required: False
|
|
758
767
|
meta:
|
|
759
|
-
label: Cover section
|
|
768
|
+
label: "https://boneio.eu/docs/black/configuration/cover \n Cover section of boneIO Black. It enables cover entities in HA. You'd need output config to use it first."
|
|
760
769
|
schema:
|
|
761
770
|
type: dict
|
|
762
771
|
schema:
|
|
@@ -830,7 +839,7 @@ ds2482:
|
|
|
830
839
|
type: list
|
|
831
840
|
required: False
|
|
832
841
|
meta:
|
|
833
|
-
label: DS2482
|
|
842
|
+
label: "https://boneio.eu/docs/black/configuration/ds2482 \n DS2482 section of boneIO Black. It enables DS2482 1 wire extenders, which you can use in sensor: config."
|
|
834
843
|
schema:
|
|
835
844
|
type: dict
|
|
836
845
|
required: False
|
|
@@ -846,6 +855,8 @@ ds2482:
|
|
|
846
855
|
dallas:
|
|
847
856
|
type: dict
|
|
848
857
|
required: False
|
|
858
|
+
meta:
|
|
859
|
+
label: "https://boneio.eu/docs/black/configuration/dallas \n Dallas section of boneIO Black. It enables Dallas bus in boneIO Black Kernel."
|
|
849
860
|
schema:
|
|
850
861
|
id:
|
|
851
862
|
type: string
|
|
@@ -857,7 +868,7 @@ sensor:
|
|
|
857
868
|
type: list
|
|
858
869
|
required: False
|
|
859
870
|
meta:
|
|
860
|
-
label: Sensor list. Currently only Dallas DS18B20 support.
|
|
871
|
+
label: Sensor list. Currently only Dallas DS18B20 and DS2482 support. Check DS18B20 or DS2482 section for more info.
|
|
861
872
|
schema:
|
|
862
873
|
type: dict
|
|
863
874
|
schema:
|
|
@@ -897,7 +908,7 @@ boneio:
|
|
|
897
908
|
type: dict
|
|
898
909
|
required: False
|
|
899
910
|
meta:
|
|
900
|
-
label: BoneIO configuration section
|
|
911
|
+
label: "https://boneio.eu/docs/black/0.9.x-dev/configuration/boneio \n BoneIO configuration section. It's new section for boneIO Black. It enables you to use predefined device types. For now only 0.7 and 0.8 devices are supported."
|
|
901
912
|
schema:
|
|
902
913
|
name:
|
|
903
914
|
type: string
|
|
@@ -905,7 +916,9 @@ boneio:
|
|
|
905
916
|
meta:
|
|
906
917
|
label: Name of boneio. Default is Black.
|
|
907
918
|
version:
|
|
908
|
-
type:
|
|
919
|
+
type:
|
|
920
|
+
- float
|
|
921
|
+
- string
|
|
909
922
|
coerce:
|
|
910
923
|
- str
|
|
911
924
|
required: False
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
"""GpioInputBinarySensorNew to receive signals."""
|
|
2
2
|
|
|
3
3
|
import logging
|
|
4
|
-
from boneio.const import PRESSED, RELEASED, BOTH
|
|
5
|
-
from boneio.helper import GpioBaseClass
|
|
6
4
|
import time
|
|
5
|
+
|
|
6
|
+
from boneio.const import BOTH, PRESSED, RELEASED
|
|
7
|
+
from boneio.helper import GpioBaseClass
|
|
7
8
|
from boneio.helper.gpio import add_event_callback, add_event_detect
|
|
8
9
|
|
|
9
10
|
_LOGGER = logging.getLogger(__name__)
|