diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1bd423d..2b344d9 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -12,7 +12,7 @@ permissions: jobs: deps: name: Dependencies - runs-on: ubuntu-20.04 + runs-on: ubuntu-22.04 env: MIX_ENV: test strategy: @@ -22,8 +22,8 @@ jobs: elixir: 1.12.3 otp: 24.3.4 - pair: - elixir: 1.14.3 - otp: 25.3.2 + elixir: 1.16.0 + otp: 26.2.1 lint: lint steps: - uses: styfle/cancel-workflow-action@0.11.0 @@ -61,7 +61,7 @@ jobs: static_code_analysis: name: Static Code Analysis needs: deps - runs-on: ubuntu-20.04 + runs-on: ubuntu-22.04 env: MIX_ENV: test strategy: @@ -71,8 +71,8 @@ jobs: elixir: 1.12.3 otp: 24.3.4 - pair: - elixir: 1.14.3 - otp: 25.3.2 + elixir: 1.16.0 + otp: 26.2.1 lint: lint steps: - uses: styfle/cancel-workflow-action@0.11.0 @@ -100,8 +100,8 @@ jobs: - run: mix format --check-formatted if: ${{ matrix.lint }} - # - run: mix deps.unlock --check-unused - # if: ${{ matrix.lint }} + - run: mix deps.unlock --check-unused + if: ${{ matrix.lint }} - run: mix credo if: ${{ matrix.lint }} @@ -111,7 +111,7 @@ jobs: unit_tests: needs: deps - runs-on: ubuntu-20.04 + runs-on: ubuntu-22.04 env: MIX_ENV: test strategy: @@ -122,8 +122,8 @@ jobs: elixir: 1.12.3 otp: 24.3.4 - pair: - elixir: 1.14.3 - otp: 25.3.2 + elixir: 1.16.0 + otp: 26.2.1 lint: lint steps: - uses: styfle/cancel-workflow-action@0.11.0 diff --git a/CHANGELOG.md b/CHANGELOG.md index bb6c3fe..3b2d101 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,17 +1,27 @@ # Changelog +## v0.1.3 (2024-01-17) + +### Changed + +- change ownership to elixir-sensors +- add a Livebook notebook for basic usage + ## v0.1.2 (2023-05-13) ### Fixed + - `timestamp_ms` time unit ### Changed + - use `circuits_i2c` v2 release candidate in dev and test environment; optiontally in prod ## v0.1.1 (2023-05-09) ### Added + - support for features such as: - read/write power saving mode - read/write low threshold @@ -19,4 +29,5 @@ - read interrupt status ## v0.1.0 (2023-05-07) + - First release diff --git a/mix.exs b/mix.exs index 024dc03..1fe7cdf 100644 --- a/mix.exs +++ b/mix.exs @@ -1,7 +1,7 @@ defmodule VEML7700.MixProject do use Mix.Project - @version "0.1.2" + @version "0.1.3" @description "Use Vishay ambient light sensor VEML7700 in Elixir" @source_url "https://github.com/elixir-sensors/veml7700" @datasheet_url "https://www.vishay.com/docs/84286/veml7700.pdf" @@ -39,9 +39,8 @@ defmodule VEML7700.MixProject do # Run "mix help deps" to learn about dependencies. defp deps do [ - # {:circuits_i2c, "~> 2.0 or ~> 1.0 or ~> 0.3"}, - {:circuits_i2c, github: "elixir-circuits/circuits_i2c", branch: "v2.0", override: true}, - {:circuits_sim, github: "elixir-circuits/circuits_sim"}, + {:circuits_i2c, "~> 2.0 or ~> 1.0 or ~> 0.3"}, + {:circuits_sim, github: "elixir-circuits/circuits_sim", only: [:dev, :test]}, {:credo, "~> 1.7", only: [:dev, :test], runtime: false}, {:dialyxir, "~> 1.3", only: [:dev, :test], runtime: false}, {:ex_doc, "~> 0.29", only: :docs, runtime: false} diff --git a/mix.lock b/mix.lock index 702d37a..9bb2f3f 100644 --- a/mix.lock +++ b/mix.lock @@ -1,20 +1,20 @@ %{ - "bunt": {:hex, :bunt, "0.2.1", "e2d4792f7bc0ced7583ab54922808919518d0e57ee162901a16a1b6664ef3b14", [:mix], [], "hexpm", "a330bfb4245239787b15005e66ae6845c9cd524a288f0d141c148b02603777a5"}, + "bunt": {:hex, :bunt, "1.0.0", "081c2c665f086849e6d57900292b3a161727ab40431219529f13c4ddcf3e7a44", [:mix], [], "hexpm", "dc5f86aa08a5f6fa6b8096f0735c4e76d54ae5c9fa2c143e5a1fc7c1cd9bb6b5"}, "cerlc": {:hex, :cerlc, "0.2.1", "cfe0880aa049ebcca079ca49578055aa48e7f2e9ed8ae08bd1f919d59015d03f", [:rebar3], [], "hexpm", "37f0d74a4277dcbaf64c7c47e9953dcc8060d26d86bb466ab2a86928e0181a7d"}, - "circuits_gpio": {:git, "https://github.com/elixir-circuits/circuits_gpio.git", "93a2ae2c68acb0cf6c6ecfeabff18a175ca431e8", [branch: "v2.0"]}, - "circuits_i2c": {:git, "https://github.com/elixir-circuits/circuits_i2c.git", "9cc1ecb90534c6a46791a84e7765154ba148443d", [branch: "v2.0"]}, - "circuits_sim": {:git, "https://github.com/elixir-circuits/circuits_sim.git", "dd9512b983490dbba2854de81210942a30e01d65", []}, - "circuits_spi": {:git, "https://github.com/elixir-circuits/circuits_spi.git", "fdae3283b466d6746c78b2cbf8abdc3daa4bdf80", [branch: "v2.0"]}, - "credo": {:hex, :credo, "1.7.0", "6119bee47272e85995598ee04f2ebbed3e947678dee048d10b5feca139435f75", [:mix], [{:bunt, "~> 0.2.1", [hex: :bunt, repo: "hexpm", optional: false]}, {:file_system, "~> 0.2.8", [hex: :file_system, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "6839fcf63d1f0d1c0f450abc8564a57c43d644077ab96f2934563e68b8a769d7"}, - "dialyxir": {:hex, :dialyxir, "1.3.0", "fd1672f0922b7648ff9ce7b1b26fcf0ef56dda964a459892ad15f6b4410b5284", [:mix], [{:erlex, ">= 0.2.6", [hex: :erlex, repo: "hexpm", optional: false]}], "hexpm", "00b2a4bcd6aa8db9dcb0b38c1225b7277dca9bc370b6438715667071a304696f"}, - "earmark_parser": {:hex, :earmark_parser, "1.4.32", "fa739a0ecfa34493de19426681b23f6814573faee95dfd4b4aafe15a7b5b32c6", [:mix], [], "hexpm", "b8b0dd77d60373e77a3d7e8afa598f325e49e8663a51bcc2b88ef41838cca755"}, - "elixir_make": {:hex, :elixir_make, "0.7.6", "67716309dc5d43e16b5abbd00c01b8df6a0c2ab54a8f595468035a50189f9169", [:mix], [{:castore, "~> 0.1 or ~> 1.0", [hex: :castore, repo: "hexpm", optional: true]}], "hexpm", "5a0569756b0f7873a77687800c164cca6dfc03a09418e6fcf853d78991f49940"}, + "circuits_gpio": {:hex, :circuits_gpio, "2.0.1", "91019a11aedb574a2d8690e59471ee7bfb5706ff256d67dccfee280c8128a7a4", [:make, :mix], [{:elixir_make, "~> 0.6", [hex: :elixir_make, repo: "hexpm", optional: false]}], "hexpm", "1c09d71d883d82177c5627c97baec7c0f140743b019a75fa10861d740763df99"}, + "circuits_i2c": {:hex, :circuits_i2c, "2.0.2", "ed1bac41cca0b777e11e2105c08dc7cad67a221e0d7eec1680a644eba677f9f5", [:make, :mix], [{:elixir_make, "~> 0.6", [hex: :elixir_make, repo: "hexpm", optional: false]}], "hexpm", "b8cf6ef783f9184bf4e45a1a4fa0a72523aa4e3c2fa980f94a45336c92d95178"}, + "circuits_sim": {:git, "https://github.com/elixir-circuits/circuits_sim.git", "8561bc01ab616e1fbd70f00a0ec0295fe0ee673e", []}, + "circuits_spi": {:hex, :circuits_spi, "2.0.1", "c5e0aa5480e668caba338aa7a5cabd032d0476d2c46782189278145da9b820f4", [:make, :mix], [{:elixir_make, "~> 0.6", [hex: :elixir_make, repo: "hexpm", optional: false]}], "hexpm", "3c95bf7cfabb663d9364bcef341ad5ec42ad44a3a7c1a85beb1e98345497f5ce"}, + "credo": {:hex, :credo, "1.7.3", "05bb11eaf2f2b8db370ecaa6a6bda2ec49b2acd5e0418bc106b73b07128c0436", [:mix], [{:bunt, "~> 0.2.1 or ~> 1.0", [hex: :bunt, repo: "hexpm", optional: false]}, {:file_system, "~> 0.2 or ~> 1.0", [hex: :file_system, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "35ea675a094c934c22fb1dca3696f3c31f2728ae6ef5a53b5d648c11180a4535"}, + "dialyxir": {:hex, :dialyxir, "1.4.3", "edd0124f358f0b9e95bfe53a9fcf806d615d8f838e2202a9f430d59566b6b53b", [:mix], [{:erlex, ">= 0.2.6", [hex: :erlex, repo: "hexpm", optional: false]}], "hexpm", "bf2cfb75cd5c5006bec30141b131663299c661a864ec7fbbc72dfa557487a986"}, + "earmark_parser": {:hex, :earmark_parser, "1.4.39", "424642f8335b05bb9eb611aa1564c148a8ee35c9c8a8bba6e129d51a3e3c6769", [:mix], [], "hexpm", "06553a88d1f1846da9ef066b87b57c6f605552cfbe40d20bd8d59cc6bde41944"}, + "elixir_make": {:hex, :elixir_make, "0.7.8", "505026f266552ee5aabca0b9f9c229cbb496c689537c9f922f3eb5431157efc7", [:mix], [{:castore, "~> 0.1 or ~> 1.0", [hex: :castore, repo: "hexpm", optional: true]}, {:certifi, "~> 2.0", [hex: :certifi, repo: "hexpm", optional: true]}], "hexpm", "7a71945b913d37ea89b06966e1342c85cfe549b15e6d6d081e8081c493062c07"}, "erlex": {:hex, :erlex, "0.2.6", "c7987d15e899c7a2f34f5420d2a2ea0d659682c06ac607572df55a43753aa12e", [:mix], [], "hexpm", "2ed2e25711feb44d52b17d2780eabf998452f6efda104877a3881c2f8c0c0c75"}, - "ex_doc": {:hex, :ex_doc, "0.29.4", "6257ecbb20c7396b1fe5accd55b7b0d23f44b6aa18017b415cb4c2b91d997729", [:mix], [{:earmark_parser, "~> 1.4.31", [hex: :earmark_parser, repo: "hexpm", optional: false]}, {:makeup_elixir, "~> 0.14", [hex: :makeup_elixir, repo: "hexpm", optional: false]}, {:makeup_erlang, "~> 0.1", [hex: :makeup_erlang, repo: "hexpm", optional: false]}], "hexpm", "2c6699a737ae46cb61e4ed012af931b57b699643b24dabe2400a8168414bc4f5"}, - "file_system": {:hex, :file_system, "0.2.10", "fb082005a9cd1711c05b5248710f8826b02d7d1784e7c3451f9c1231d4fc162d", [:mix], [], "hexpm", "41195edbfb562a593726eda3b3e8b103a309b733ad25f3d642ba49696bf715dc"}, - "jason": {:hex, :jason, "1.4.0", "e855647bc964a44e2f67df589ccf49105ae039d4179db7f6271dfd3843dc27e6", [:mix], [{:decimal, "~> 1.0 or ~> 2.0", [hex: :decimal, repo: "hexpm", optional: true]}], "hexpm", "79a3791085b2a0f743ca04cec0f7be26443738779d09302e01318f97bdb82121"}, - "makeup": {:hex, :makeup, "1.1.0", "6b67c8bc2882a6b6a445859952a602afc1a41c2e08379ca057c0f525366fc3ca", [:mix], [{:nimble_parsec, "~> 1.2.2 or ~> 1.3", [hex: :nimble_parsec, repo: "hexpm", optional: false]}], "hexpm", "0a45ed501f4a8897f580eabf99a2e5234ea3e75a4373c8a52824f6e873be57a6"}, + "ex_doc": {:hex, :ex_doc, "0.31.1", "8a2355ac42b1cc7b2379da9e40243f2670143721dd50748bf6c3b1184dae2089", [:mix], [{:earmark_parser, "~> 1.4.39", [hex: :earmark_parser, repo: "hexpm", optional: false]}, {:makeup_c, ">= 0.1.1", [hex: :makeup_c, repo: "hexpm", optional: true]}, {:makeup_elixir, "~> 0.14", [hex: :makeup_elixir, repo: "hexpm", optional: false]}, {:makeup_erlang, "~> 0.1", [hex: :makeup_erlang, repo: "hexpm", optional: false]}], "hexpm", "3178c3a407c557d8343479e1ff117a96fd31bafe52a039079593fb0524ef61b0"}, + "file_system": {:hex, :file_system, "1.0.0", "b689cc7dcee665f774de94b5a832e578bd7963c8e637ef940cd44327db7de2cd", [:mix], [], "hexpm", "6752092d66aec5a10e662aefeed8ddb9531d79db0bc145bb8c40325ca1d8536d"}, + "jason": {:hex, :jason, "1.4.1", "af1504e35f629ddcdd6addb3513c3853991f694921b1b9368b0bd32beb9f1b63", [:mix], [{:decimal, "~> 1.0 or ~> 2.0", [hex: :decimal, repo: "hexpm", optional: true]}], "hexpm", "fbb01ecdfd565b56261302f7e1fcc27c4fb8f32d56eab74db621fc154604a7a1"}, + "makeup": {:hex, :makeup, "1.1.1", "fa0bc768698053b2b3869fa8a62616501ff9d11a562f3ce39580d60860c3a55e", [:mix], [{:nimble_parsec, "~> 1.2.2 or ~> 1.3", [hex: :nimble_parsec, repo: "hexpm", optional: false]}], "hexpm", "5dc62fbdd0de44de194898b6710692490be74baa02d9d108bc29f007783b0b48"}, "makeup_elixir": {:hex, :makeup_elixir, "0.16.1", "cc9e3ca312f1cfeccc572b37a09980287e243648108384b97ff2b76e505c3555", [:mix], [{:makeup, "~> 1.0", [hex: :makeup, repo: "hexpm", optional: false]}, {:nimble_parsec, "~> 1.2.3 or ~> 1.3", [hex: :nimble_parsec, repo: "hexpm", optional: false]}], "hexpm", "e127a341ad1b209bd80f7bd1620a15693a9908ed780c3b763bccf7d200c767c6"}, - "makeup_erlang": {:hex, :makeup_erlang, "0.1.1", "3fcb7f09eb9d98dc4d208f49cc955a34218fc41ff6b84df7c75b3e6e533cc65f", [:mix], [{:makeup, "~> 1.0", [hex: :makeup, repo: "hexpm", optional: false]}], "hexpm", "174d0809e98a4ef0b3309256cbf97101c6ec01c4ab0b23e926a9e17df2077cbb"}, - "nimble_parsec": {:hex, :nimble_parsec, "1.3.1", "2c54013ecf170e249e9291ed0a62e5832f70a476c61da16f6aac6dca0189f2af", [:mix], [], "hexpm", "2682e3c0b2eb58d90c6375fc0cc30bc7be06f365bf72608804fb9cffa5e1b167"}, + "makeup_erlang": {:hex, :makeup_erlang, "0.1.3", "d684f4bac8690e70b06eb52dad65d26de2eefa44cd19d64a8095e1417df7c8fd", [:mix], [{:makeup, "~> 1.0", [hex: :makeup, repo: "hexpm", optional: false]}], "hexpm", "b78dc853d2e670ff6390b605d807263bf606da3c82be37f9d7f68635bd886fc9"}, + "nimble_parsec": {:hex, :nimble_parsec, "1.4.0", "51f9b613ea62cfa97b25ccc2c1b4216e81df970acd8e16e8d1bdc58fef21370d", [:mix], [], "hexpm", "9c565862810fb383e9838c1dd2d7d2c437b3d13b267414ba6af33e50d2d1cf28"}, } diff --git a/notebooks/basic_usage.livemd b/notebooks/basic_usage.livemd index c74ef14..d3cae99 100644 --- a/notebooks/basic_usage.livemd +++ b/notebooks/basic_usage.livemd @@ -6,10 +6,10 @@ bus_address = 0x10 Mix.install( [ - {:circuits_i2c, github: "elixir-circuits/circuits_i2c", override: true}, + {:circuits_i2c, "~> 2.0"}, {:circuits_sim, github: "elixir-circuits/circuits_sim"}, - {:kino, "~> 0.9.3"}, - {:veml7700, "~> 0.1.2"} + {:kino, "~> 0.12.2"}, + {:veml7700, "0.1.2"} ], config: [ circuits_i2c: [default_backend: CircuitsSim.I2C.Backend],