Packages

Driver for the ROHM BH1745 RGB color/ambient light sensor.

Current section

Files

Jump to
Raw

README.md

# BH1745Luminance
Elixir/Nerves driver for the ROHM BH1745 RGB color/ambient light sensor.
Board: [switch-science product page](https://www.switch-science.com/products/9644).
Target machine: [BeagleBone Green](https://www.beagleboard.org/boards/seeedstudio-beaglebone-green).
## Installation
The package can be installed by adding `bh1745luminance` to your list of
dependencies in `mix.exs`:
```elixir
def deps do
[
{:bh1745luminance, "~> 0.1.0"}
]
end
```
## Usage
```elixir
{:ok, ref} = BH1745Luminance.open()
{r, g, b, clear} = BH1745Luminance.read_rgbw(ref)
BH1745Luminance.close(ref)
```
Documentation is generated with [ExDoc](https://github.com/elixir-lang/ex_doc)
and published on [HexDocs](https://hexdocs.pm) at
<https://hexdocs.pm/bh1745luminance>.