Skip to content

645340633/UnitySensor

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

44 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This repository contains the pre-installed ESPHome config and example Arduino code projects for the Unity sensor board. Specifications of the board can be found at https://loopon.tech/products/unity-sensor

Table of Contents

Getting Started

The Unity board comes pre-installed with ESPHome. The configuration can be found here.

Connecting to WiFi

There are two ways to connect the Unity board to your WiFi network:

Using Imrpov

  1. Power up the Unity board.
  2. Go to https://www.improv-wifi.com/ on your phone or a computer with Bluetooth.
  3. Click "Connect device to Wi-Fi".
  4. Select the Unity device.

  1. Input your SSID and password.
  2. Click Save.

Using the Access Point

  1. Power up the Unity board.
  2. On your phone or computer, search for the Unity WiFi network.
  3. Once connected, your phone will be redirected to the WiFi setup page. If you are not redirected, open a browser and go to http://192.168.4.1
  4. Select your WiFi network SSID from the list and input the password if needed.
  5. Click Save.

Home Assistant

Once you have successfully connected to your WiFi network, you can integrate the device to Home Assistant. You must have the ESPHome Add-on installed. If you do not have the Add-on then follow the 'Installing ESPHome Dashboard' guide here.

Discovery

Home Assistant and the ESPHome Add-on will automatically detect the Unity device.

You can find the device in:

  • Integrations: Open your Home Assistant instance and show your integrations.

  • ESPHome Dashboard: Open your Home Assistant instance and Open the ingress URL of a Supervisor add-on.

Note: If the device does not show up then please try restarting Home Assistant. Open your Home Assistant instance and show your server controls.

View Device

You can now view the Unity board in Open your Home Assistant instance and show your devices.

For best results, use the recommended settings in the screenshot below for the human presence sensor.

Modifying ESPHome Config

You can modify the way the device behaves by compiling and flashing the Unity board.

Using ESPHome Dashboard (Easy)

(Work in progress)

Using ESPHome CLI (Medium)

With ESPHome installed on your computer (guide), you can clone and modify the loopon_unity.yaml, compile and flash the Unity board.

To compile and flash use:

# Make sure Unity board is in Flash mode
esphome run ./ESPHome/loopon_unity.yaml --no-logs
# Reset device when done

To monitor logs use:

esphome logs ./ESPHome/loopon_unity.yaml --device=COM19 

You can optionally add the device port to the commands above:

 --device=COM19 

Flashing the Unity Board

To flash the Unity board, it must be put in the correct boot mode. You can do this by:

  1. Holding down the boot button.
  2. Momentarily pressing the reset button.
  3. Then, releasing the boot button.

Once flashing has completed, press the reset button to restart in normal mode.

Arduino Example Projects

PlatformIO

PlatformIO is a cross-platform IDE extension for Visual Studio Code. Use PlatformIO to open, build and upload the example projects to the Unity board. The installation guide can be found here.

This project will blink LEDs on all GPIO ports.

This project will simulate a Bluetooth keyboard and will type a few sentences when connected to a computer or mobile device.

Windows Setup

  1. Go to Settings -> Bluetooth & Devices -> Add device.
  2. Select Bluetooth.
  3. After the scan has completed, the 'Unity Keyboard' should appear. Click and add device.
  4. Open Notepad.exe and watch it type.

Android Setup

  1. Go to Settings -> Device connection -> Pair new device.
  2. Select Unity Keyboard in the list.
  3. Open a notepad app and watch it type.

This project uses the LD2410 sensor to read the distance of a stationary or moving human.

This project cycles through colours of the rainbow using the onboard RGB LED.

This project prints the readings from the HDC1080 (temperature/humidity) and the BH1750 (light) sensors.

This project will scan and print WiFi access points.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • C++ 74.0%
  • Python 26.0%