GithubHelp home page GithubHelp logo

m5-dial-for-esphome's Introduction

Language Selection:

en de

M5 Stack Dial Custom Component for ESPHome

image
More information about the M5 Stack Dial

This component turns the M5 Stack Dial into a universal remote control for Home Assistant.

Currently supported entities are:

  • climate
  • cover
  • fan
  • light
  • switch
  • media_player
  • lock

Video

M5 Stack Dial

 

Discord

For quick exchanges, suggestions, and updates on the current development status, our Discord is also available.
Invite Link: https://discord.gg/pN7SpK7

 

Example Configuration:

substitutions:
  name: "m5-dial"
  wifi_ssid: !secret wifi_ssid
  wifi_password: !secret wifi_password  

packages:
  m5_tough_package:
    url: https://github.com/SmartHome-yourself/m5-dial-for-esphome
    ref: main
    file: shys-m5-dial.yaml
    refresh: 1h

shys_m5_dial:
  name: Dial
  screen_off_time: 45000
  rotary_step_width: 5
  long_press_duration: 1200
  font: FreeSans12pt7b
  font_factor: 1

  devices:
    lights:
      - entity: light.my_light1
        name: Light 1
        modes:
          dimm_mode:
            enable: true
            rotary_step_width: 10
          rgb_mode: 
            enable: true
            rotary_step_width: 30
          white_mode: 
            enable: true
            rotary_step_width: 100
            min_kelvin: 2500
            max_kelvin: 7000
            
      - entity: light.my_light2
        name: Light 2

    switches:
      - entity: switch.my_switch
        name: Switch 1
        
    climates:
      - entity: climate.my_climate1
        name: Heater
        modes:
          temp_mode:
            rotary_step_width: 1
            min_temperature: 4
            max_temperature: 30
            
    covers:
      - entity: cover.my_cover1
        name: Cover 1
        modes:
          position_mode:
            rotary_step_width: 5

    fans:
      - entity: fan.my_fan1
        name: Fan 1
        modes:
          speed_mode:
            changeable_direction: true
            rotary_step_width: 10

    media_player:
      - entity: media_player.my_player1
        name: MediaPlayer 1
        modes:
          play_mode:
            rotary_step_width: 10
          source_mode:
            rotary_step_width: 1
            sources:
              - name: 1Live
                content_id: 1Live
                content_type: TUNEIN
              - name: WDR2
                content_id: "http://wdr-wdr2-bergischesland.icecast.wdr.de/wdr/wdr2/bergischesland/mp3/128/stream.mp3"
                content_type: custom

    lock:
      - entity: lock.my_lock1
        name: Lock 1
        modes:
          lock_mode:
            rotary_step_width: 1
            open_on_button: false

 

Configuration

In substitutions, the devicename must be specified.
The wireless network connection must be fully configured either through the normal wifi: section, or alternatively, you can simply specify the WLAN SSID and WLAN password in the substitutions.

Substitutions

substitutions:
  name: "m5-dial"
  wifi_ssid: !secret wifi_ssid
  wifi_password: !secret wifi_password

name
The hostname of the device. (default: m5-dial)

wifi_ssid
The hostname of the device. (default: !secret wifi_ssid)

wifi_password
The hostname of the device. (default: !secret wifi_password)

 


Custom-Component


General Attributes

General attributes are all parameters available directly under the custom component "shys_m5_dial".

Code:

shys_m5_dial:
  name: Dial
  screenOffTime: 45000
  rotaryStepWidth: 5
  longPressDuration: 1200

name
Sets the name of the component.

screenOffTime (optional) (Default: 30000)
Indicates after how many milliseconds the display automatically turns off.

rotaryStepWidth (optional) (Default: 10)
Specifies the general step width by which the value changes per step when using the rotary encoder.
The value set here applies to all modes where no different step width is specified.

longPressDuration (optional) (Default: 1200)
Indicates the duration, in milliseconds, after which a button press is considered a long press.

font (optional) (Default: FreeSans12pt7b)
Specifies the font to be used.
All available fonts are defined in a map in globals.h.

font_factor (optional) (Default: 1)
Specifies the factor to be applied to the font size.
Valid values: 0.1 - 10.0

 


devices

Under Devices, all entities to be controlled with the M5 Dial are specified.
The entities are specified in individual lists per device type (domain) such as lights, switches, covers, etc.

Code:

shys_m5_dial:
  ...
  devices:

 


LIGHTS

Under "devices - lights" all light entities are specified.
Without further specifications, the lamp can only be turned on/off via the Dial.
To adjust color, brightness, or white value, the respective mode must be activated.

Code:

shys_m5_dial:
  ...
  devices:
    lights:
      - entity: light.my_light1
        name: Light 1  

entity
Specifies the Light Entity ID from Home Assistant to be controlled.

name
The name of the entity displayed on the screen.

modes (optional)

dimm_mode

The Dimm Mode allows regulating the brightness of the light entity.
When Dimm Mode is active, it replaces the standard On/Off Mode.
Brightness can be controlled both via the rotary encoder and touch.
A press on the button turns the light on/off.

Code:

shys_m5_dial:
  ...
  devices:
    lights:
      - entity: light.my_light1
        name: Light 1  
        modes:
          dimm_mode:
            enable: true
            rotary_step_width: 10

enable (Default: false)
Setting to true activates the mode for the entity.

rotary_step_width (optional)
Specifies the general step width by which the value changes per step when using the rotary encoder.
The value set here overrides the general setting and applies only to the brightness mode of this light entity.
Valid values: 1 - 100

 

white_mode

The White Mode allows regulating the white tone for the light entity in Kelvin.
The white tone can be controlled both via the rotary encoder and touch.
A press on the button turns the light on/off.

Code:

shys_m5_dial:
  ...
  devices:
    lights:
      - entity: light.my_light1
        name: Light 1  
        modes:
          white_mode: 
            enable: true
            rotary_step_width: 100
            min_kelvin: 2500
            max_kelvin: 7000

enable (Default: false)
Setting to true activates the mode for the entity.

rotary_step_width (optional)
Specifies the general step width by which the value changes per step when using the rotary encoder.
The value set here overrides the general setting and applies only to the white tone mode of this light entity.
Valid values: 1 - 500

min_kelvin (optional) (Default: 2000)
Specifies the minimum value in Kelvin for white tone control. Valid values: 1000 - 10000

max_kelvin (optional) (Default: 6500)
Specifies the maximum value in Kelvin for white tone control. Valid values: 1000 - 10000

 

rgb_mode

The RGB Mode (color selection) allows selecting the color for the light entity.
Color can be controlled both via the rotary encoder and touch.
A press on the button turns the light on/off.

Code:

shys_m5_dial:
  ...
  devices:
    lights:
      - entity: light.my_light1
        name: Light 1  
        modes:
          rgb_mode: 
            enable: true
            rotary_step_width: 30

enable Default: false
Setting to true activates the mode for the entity.

rotary_step_width (optional)
Specifies the general step width by which the value changes per step when using the rotary encoder.
The value set here overrides the general setting and applies only to the color selection mode of this light entity.
Valid values: 1 - 100

 


CLIMATES

Under "devices - climates" all climate entities are specified.

Code:

shys_m5_dial:
  ...
  devices:
    climates:
      - entity: climate.my_climate1
        name: Heater

entity
Specifies the Climate Entity ID from Home Assistant to be controlled.

name
The name of the entity displayed on the screen.

modes (optional)

temp_mode

The Temp Mode allows regulating the temperature of the climate entity.
Temperature can be controlled both via the rotary encoder and touch.
A press on the button turns the heater on/off.

Code:

shys_m5_dial:
  ...
  devices:
    climates:
      - entity: climate.my_climate1
        name: Heater
        modes:
          temp_mode:
            rotary_step_width: 1
            min_temperature: 4
            max_temperature: 30

rotary_step_width (optional) Default: 1
Specifies the general step width by which the value changes per step when using the rotary encoder.
For climates, 1 is the default, regardless of what is set as the general standard in the component.
Valid values: 1 - 100

min_temperature (optional) Default: 4
Sets the minimum temperature that can be set for this climate entity on the Dial.

max_temperature (optional) Default: 30
Sets the maximum temperature that can be set for this climate entity on the Dial.

 


COVER

Under "devices - cover" all cover entities are specified.

Code:

shys_m5_dial:
  ...
  devices:
    covers:
      - entity: cover.my_cover1
        name: Cover 1

entity
Specifies the Cover Entity ID from Home Assistant to be controlled.

name
The name of the entity displayed on the screen.

modes (optional)

position_mode

The Position Mode allows controlling the position of the cover entity.
Position can be controlled both via the rotary encoder and touch.

Code:

shys_m5_dial:
  ...
  devices:
    covers:
      - entity: cover.my_cover1
        name: Cover 1
        modes:
          position_mode:
            rotary_step_width: 5

rotary_step_width (optional)
Specifies the general step width by which the value changes per step when using the rotary encoder.
The value set here overrides the general setting and applies only to the position mode of this cover entity.
Valid values: 1 - 100

 


FANS

Under "devices - cover" all fan entities are specified.

Code:

shys_m5_dial:
  ...
  devices:
    fans:
      - entity: fan.my_fan1
        name: Fan 1

entity
Specifies the Fan Entity ID from Home Assistant to be controlled.

name
The name of the fan displayed on the screen.

modes (optional)

speed_mode

The Speed Mode allows controlling the speed of the fan entity.
Speed can be controlled both via the rotary encoder and touch.
A press on the button turns the fan on/off.

Code:

shys_m5_dial:
  ...
  devices:
    fans:
      - entity: fan.my_fan1
        name: Fan 1
        modes:
          speed_mode:
            changeable_direction: true
            rotary_step_width: 10

changeable_direction (optional) (Default: false)
Indicates whether the fan has two directions of rotation and can therefore be switched between forward and reverse.
False = Only one direction of rotation. Turning right increases the speed, turning left reduces the speed. True = Two directions of rotation. Turning right increases the speed for forward, turning left reduces the speed for forward.
However, you can now turn past 0 and thus change the direction of rotation.
If the fan is running in reverse, turning left increases the speed and turning right reduces it. Valid values: true / false

rotary_step_width (optional)
Specifies the general step width by which the value changes per step when using the rotary encoder.
The value set here overrides the general setting and applies only to the speed mode of this fan entity.
Valid values: 1 - 100

 


MEDIA PLAYER

Under "devices - media_player" all MediaPlayer entities are specified.

Code:

shys_m5_dial:
  ...
  devices:
    media_player:
      - entity: media_player.my_player1
        name: MediaPlayer 1

entity
Specifies the MediaPlayer Entity ID from Home Assistant to be controlled.

name
The name of the MediaPlayer displayed on the screen.

modes (optional)

play_mode

The Play Mode allows adjusting the volume via the rotary encoder, as well as starting/pausing playback or skipping to the next or previous track via touch.
A press on the button toggles between play and pause.

Code:

shys_m5_dial:
  ...
  devices:
    media_player:
      - entity: media_player.my_player1
        name: MediaPlayer 1
        modes:
          play_mode:
            rotary_step_width: 10

rotary_step_width (optional)
Specifies the general step width by which the value changes per step when using the rotary encoder.
The value set here overrides the general setting and applies only to the play mode of this MediaPlayer entity.
Valid values: 1 - 100

 

source_mode

The Source Mode allows selecting a source from the stored "Sources" using the rotary encoder for playback.
A press on the button starts playback of the selected source.

Code:

shys_m5_dial:
  ...
  devices:
    media_player:
      - entity: media_player.my_player1
        name: MediaPlayer 1
        modes:
          play_mode:
            rotary_step_width: 10
          source_mode:
            rotary_step_width: 1
            sources:
              - name: 1Live
                content_id: 1Live
                content_type: TUNEIN
              - name: WDR2
                content_id: "http://wdr-wdr2-bergischesland.icecast.wdr.de/wdr/wdr2/bergischesland/mp3/128/stream.mp3"
                content_type: custom

rotary_step_width (optional) (Default: 1)
Specifies the general step width by which the value changes per step when using the rotary encoder.
For source_mode of media_player, 1 is the default, regardless of what is set as the general standard in the component.
Valid values: 1 - 100

sources (optional) A list of audio sources available for playback selection.
Entries must always include the attributes "name", "content_id", and "content_type"!

Example for Amazon Echo (Alexa):

              - name: 1Live
                content_id: 1Live
                content_type: TUNEIN

              - name: Metallica
                content_id: metallica
                content_type: AMAZON_MUSIC

              - name: Nothing else matters
                content_id: play metallica nothing else matters
                content_type: custom				

Example for DLNA Player:

              - name: 1Live
                content_id: "https://wdr-1live-live.icecastssl.wdr.de/wdr/1live/live/mp3/128/stream.mp3"
                content_type: custom

 


LOCKS

Under "devices - lock" all lock entities are listed.

Code:

shys_m5_dial:
  ...
  devices:
    lock:
      - entity: lock.my_lock1
        name: Lock 1

entity
Specifies the lock entity ID from Home Assistant to be controlled.

name
The name of the lock displayed on the screen.

modes (optional)

lock_mode

With the lock mode, the state of the lock entity can be controlled.
The lock can be unlocked, locked, and opened using the rotary encoder. A press on the button usually unlocks or locks the lock depending on the current state. However, if open_on_button is set to true, pressing the button will open the lock directly instead of just unlocking it.

Code:

shys_m5_dial:
  ...
  devices:
    lock:
      - entity: lock.my_lock1
        name: Lock 1
        modes:
          lock_mode:
            open_on_button: true
            rotary_step_width: 10

open_on_button (optional) (Default: false)
Setting to true will directly open the lock when pressing the button instead of just unlocking it.
If the parameter is set to false (or not specified), the lock will only be unlocked but not fully opened. Valid values: true / false

rotary_step_width (optional) (Default: 1)
Specifies the general step width by which the value changes when using the rotary encoder per step.
For lock mode of lock, 1 is the default value, regardless of what is set as the general standard in the component.
If a step width of 2 is specified here, turning the encoder will not only unlock the lock but also automatically fully open it.
Valid values: 1 - 2

 

 



Advanced

The following attributes are present, but generally should not need to be changed.

send_value_delay
Specifies the delay in milliseconds to wait after a value change before transmitting the change to Home Assistant.
This is especially important when using the rotary encoder to avoid generating unnecessary API calls. (Default: 1200)

send_value_lock
Specifies how long to wait after an API call before the next API call can be made. (Default: 3000)



 

m5-dial-for-esphome's People

Contributors

danielscheidler avatar heman avatar lboue avatar

Stargazers

Josh J avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar Sven Dowideit avatar  avatar  avatar Leonardo Grade avatar Oskar Flath avatar Anton Sergunov avatar Yevgeniy Bolembakh avatar  avatar  avatar  avatar James Hodgkinson avatar Tao Zhou avatar InflatedBoi avatar Sam Dolt avatar Avi Miller avatar Wolfram avatar T©M avatar Nikolaus Wagner avatar rabautz avatar SL70 avatar Barney Mattox avatar disruptive pattern material avatar Bjørn avatar  avatar G8YTZ avatar  avatar  avatar  avatar  avatar Matt Peterson avatar  avatar Volker Bohne avatar  avatar Dirk avatar  avatar  avatar Stephan Heuel avatar Stefan Le Breton avatar John P. Hoke avatar  avatar  avatar  avatar nkxuyin avatar Lee Coates avatar  avatar Prashant Sinha avatar  avatar Maximilian Scherk avatar  avatar  avatar  avatar

Watchers

Sven Dowideit avatar  avatar  avatar Sam Dolt avatar  avatar  avatar Yevgeniy Bolembakh avatar  avatar

m5-dial-for-esphome's Issues

Fan speeds for... fans.

I have a 6 speed fan as indeed most fans are these days.

This translate to roughly 16.6667% per step. The ability to set floats would be really cool. Presently, I've only had to make each step at 16%. This results in Speed 3 coming in at 48% instead of 50%. Then HA will take its time and round it up to the nearest step that it knows off before finally updating the dial that it's now at 50%.

Floats would be cool. Alternatively, mapping steps would also be cool. e.g. Dial displays 1 but sends 16.6667% to HA.

In addition, the fan speed moves to quickly per #25

My aircon has 0.5 degree temperature setting steps

I'd love the step width to have a non-integer size - perhaps a single decimal is enough, but i don't know the tradeoffs between changing to a float, vs adding a rotary_step_width_scaler int, so both settings could be ints

for eg, to get 0.5, rotary_step_width=1 & rotary_step_width_scaler=2

or to enable 0.1, rotary_step_width=1 & rotary_step_width_scaler=10

Multiple light modes; how does it work?

In the example configuration, it is possible to enable dimm_mode, rgb_mode, white_mode all at the same time.

How does one change between modes from the dial itself? Is it possible?

Where can i find the options flow?

... rejected; If you trust this device and want to allow access for it to make Home Assistant service calls, you can enable this functionality in the options flow

Screen Brightness

It's not an issue, just a question. Is it possible to reduce M5-dial screen brightness? I use this device in our bedroom and when it's dark in the room the display is so bright. TY

M5Dial loosing connection to HA or HA disconnecting

Im aktuellen Developer Code verliert der M5Dial immer wieder die Verbindung zu HA, nach sleep eigentlich immer. In diesem Fall bleibt das Display auf "DISCONNECTED", auch wenn HA wieder verbunden ist. Der M5Dial reagiert nach kurzer Zeit meistens wieder auf Input:

[13:40:00][D][api.connection:197]: Home Assistant 2024.3.3 (❌❌❌) requested disconnected
[13:40:00][D][HA_API:264]: API is not connected
[13:40:07][D][api:102]: Accepted ❌❌❌
[13:40:07][I][DEVICE:056]: Rotary right
[13:40:07][D][DEVICE:150]: HaDevice.onRotary: right
[13:40:07][I][DISPLAY:070]: refreshInnerMenu( ,4) = 60 °
[13:40:07][D][api.connection:1121]: Home Assistant 2024.3.3 (❌❌❌): Connected successfully

Ich habe den Eindruck, dass sich das im aktuellen DEV verschlechtert hat bzw. erstmals auftritt.

Display Sensor Values

Hi Daniel,

first of all: Nice work! It took me like 10min to get it running!

I had multiple ideas how to make this custom component even better:

  • would it be possible for you to make the UI colors configurable?
  • and would it be possible to add some more devices, like sensors? I am thinking about temperature/humidity/CO2?

Would be great to see those things in this amazing projects.

Greetings from Austria,
Christian

class ArduinoJson::V704PB2::StaticJsonDocument' is deprecated: use JsonDocument instead

Hi,
when compiling with ESPHome I get the following errors

Compiling .pioenvs/m5-dial-01/src/esphome/core/scheduler.cpp.o
In file included from src/esphome.h:39,
                 from src/esphome/components/shys_m5_dial/shys_m5_dial.h:2,
                 from src/esphome/components/shys_m5_dial/shys_m5_dial.cpp:2:
src/esphome/components/shys_m5_dial/ha_device.h:19:17: warning: 'template<unsigned int N> class ArduinoJson::V704PB2::StaticJsonDocument' is deprecated: use JsonDocument instead [-Wdeprecated-declarations]
                 StaticJsonDocument<bufferSize> jsonBuffer;
                 ^~~~~~~~~~~~~~~~~~
In file included from .piolibdeps/m5-dial-01/ArduinoJson/src/ArduinoJson.hpp:53,
                 from .piolibdeps/m5-dial-01/ArduinoJson/src/ArduinoJson.h:9,
                 from src/esphome/components/shys_m5_dial/ha_device.h:6,
                 from src/esphome.h:39,
                 from src/esphome/components/shys_m5_dial/shys_m5_dial.h:2,
                 from src/esphome/components/shys_m5_dial/shys_m5_dial.cpp:2:
.piolibdeps/m5-dial-01/ArduinoJson/src/ArduinoJson/compatibility.hpp:63:58: note: declared here
 class ARDUINOJSON_DEPRECATED("use JsonDocument instead") StaticJsonDocument
                                                          ^~~~~~~~~~~~~~~~~~
Compiling .pioenvs/m5-dial-01/src/esphome/core/string_ref.cpp.o
Compiling .pioenvs/m5-dial-01/src/esphome/core/time.cpp.o
Compiling .pioenvs/m5-dial-01/src/esphome/core/util.cpp.o

and

Compiling .pioenvs/m5-dial-01/lib622/EEPROM/EEPROM.cpp.o
In file included from src/esphome.h:39,
                 from src/main.cpp:3:
src/esphome/components/shys_m5_dial/ha_device.h:19:17: warning: 'template<unsigned int N> class ArduinoJson::V704PB2::StaticJsonDocument' is deprecated: use JsonDocument instead [-Wdeprecated-declarations]
                 StaticJsonDocument<bufferSize> jsonBuffer;
                 ^~~~~~~~~~~~~~~~~~
In file included from .piolibdeps/m5-dial-01/ArduinoJson/src/ArduinoJson.hpp:53,
                 from .piolibdeps/m5-dial-01/ArduinoJson/src/ArduinoJson.h:9,
                 from src/esphome/components/shys_m5_dial/ha_device.h:6,
                 from src/esphome.h:39,
                 from src/main.cpp:3:
.piolibdeps/m5-dial-01/ArduinoJson/src/ArduinoJson/compatibility.hpp:63:58: note: declared here
 class ARDUINOJSON_DEPRECATED("use JsonDocument instead") StaticJsonDocument
                                                          ^~~~~~~~~~~~~~~~~~
Compiling .pioenvs/m5-dial-01/libbbe/M5GFX/M5GFX.cpp.o

It stimm get the firmware, and connects to the local wifi, but in HomeAssistant the dial cannot be registered.

Display says "Disconnected"

But at the commandline I see

WARNING m5-dial-01 @ 192.168.90.65: Connection error occurred: m5-dial-01 @ 192.168.90.65: Connection lost
INFO Successfully connected to m5-dial-01 @ 192.168.90.65 in 0.047s
WARNING m5-dial-01 @ 192.168.90.65: Connection error occurred: [Errno 54] Connection reset by peer
INFO Successfully connected to m5-dial-01 @ 192.168.90.65 in 0.004s
WARNING m5-dial-01 @ 192.168.90.65: Connection error occurred: [Errno 54] Connection reset by peer
INFO Successfully connected to m5-dial-01 @ 192.168.90.65 in 0.004s

I can ping the device, but ESPHOme at HomeAssistant is not wanting to register, as it cannot get the API connectedt to.

any ideas?
thanks
Juergen

Nordic fonts

Are there possible to add support for Nordic fonts? Something like this:

  • file: 'your_font.ttf'
    glyphs:
    ['&', '@', '!', ',', '.', '?', '"', '%', '(', ')', '+', '-', '_', ':', '°', '0',
    '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E',
    'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S',
    'T', 'U', 'V', 'W', 'X', 'Y', 'Z', ' ', 'a', 'b', 'c', 'd', 'e', 'f',
    'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't',
    'u', 'v', 'w', 'x', 'y', 'z','å', 'Å', 'ä', 'Ø', 'ø', 'Ü', 'ü', '/']

MissingPackageManifestError

Whenever I try to install a new M5Dial, I get the error message described in the title... Any suggestions?

Fan is still reversible

Setting changeable direction in the fan entity to false, or even omitting the option entirely (to utilise the default false) still results in a changeable direction setting in the fan page

Change colors in Mediaplayer

How can I Change the background-color and the font-color in Mediaplayer? I would Like to have a black Background and White font-color...
Thanks for Help in advance

Clock not show right time

Hello Daniel. After last esphome update, my screensaver showing wrong time. Exactly 4 hours different.
I try to change code, but no luck.
time:

  • platform: homeassistant
    id: homeassistant_time
    timezone: USA/New-York (USA/EDT or USA/EST or USA/ UDT-4)
    Of course I use one of them.
    Any Idea why and what to do.
    Thank you

Using the pressable button as a page turner

The swiping function, while cool, does result in a lot of accidental presses. An option to use the physical tact button to change pages would be nice. Tapping on the screen could simulate the same effect the physical button previously had

Implement a LVGL UI

I would like to keep the way i integrate a new device in the YAML that you made but implement a custom LVGL UI is that possible ? thanks a lot

Rotary encoder is way too sensitive

The rotary encoder is way too sensitive. Would be nice to allow say 5 clicks clockwise to be required in half a second to count as 1 actionable click

Facing a error when I try to use this code

Hello

Thank you for this code !

I'm facing a issue when I try to use this code on the ESP Dashboard for the M5 Dial device:

INFO ESPHome 2024.3.0
INFO Reading configuration /config/esphome/m5stack-rotatory-knob.yaml...
ERROR Error while reading config: Invalid YAML syntax:

´´´
Duplicate key "min_kelvin"
in "/config/esphome/m5stack-rotatory-knob.yaml", line 36, column 13
NOTE: Previous declaration here:
in "/config/esphome/m5stack-rotatory-knob.yaml", line 35, column 13
´´´
Can you please help me in order to solve this ?

Thank you

After the last ESP update to version 2024.6.1 Stop Working

Hello

After the last ESP update to version 2024.6.1 my M5 Dial Stop Working

I changed the YAML code as needed

ota:

  • platform: esphome
    password: "My Password"

But the device Still Offline And not connected ...

Can some one please help me in order to try solve this issue? Thank you in advance

LD2410 and main page support

Hi, Daniel
Thank you so much for this great project. I install your project in 15 minutes without any problem.
3 questions:

  1. Is it possible to make a climate card looks like a HA card?
  2. I try to add LD2410 sensor for backlight to turn ON when some one close to M5 dial( around 2 feet or so) but don't know how.
    @dgaust add this to his code: https://github.com/dgaust/esphome_files.
uart:
  tx_pin: GPIO2
  rx_pin: GPIO1
  baud_rate: 256000
  parity: NONE
  stop_bits: 1

ld2410:

spi:
  mosi_pin: GPIO6
  clk_pin: GPIO5

number:

  - platform: ld2410
    timeout:
      name: timeout
    light_threshold:
      name: light threshold
    max_move_distance_gate:
      name: max move distance gate
    max_still_distance_gate:
      name: max still distance gate
    g0:
      move_threshold:
        name: g0 move threshold
      still_threshold:
        name: g0 still threshold
    g1:
      move_threshold:
        name: g1 move threshold
      still_threshold:
        name: g1 still threshold
    g2:
      move_threshold:
        name: g2 move threshold
      still_threshold:
        name: g2 still threshold
    g3:
      move_threshold:
        name: g3 move threshold
      still_threshold:
        name: g3 still threshold
    g4:
      move_threshold:
        name: g4 move threshold
      still_threshold:
        name: g4 still threshold
    g5:
      move_threshold:
        name: g5 move threshold
      still_threshold:
        name: g5 still threshold
    g6:
      move_threshold:
        name: g6 move threshold
      still_threshold:
        name: g6 still threshold
    g7:
      move_threshold:
        name: g7 move threshold
      still_threshold:
        name: g7 still threshold
    g8:
      move_threshold:
        name: g8 move threshold
      still_threshold:
        name: g8 still threshold

binary_sensor:
  - platform: ld2410
    has_target:
      name: Presence
    has_moving_target:
      name: Moving Target
    has_still_target:
      name: Still Target

sensor:
  - platform: ld2410
    detection_distance:
      name: Detection Distance
      id: ddistance
      filters:
        - throttle: 0.5s
      on_value: 
        then:
          if:
            condition:
              - lambda: 'return id(ddistance).state < 150;'  
            then:
              if:
                condition:
                  - light.is_off: backlight
                then:              
                  - light.turn_on: backlight
            else:
              - light.turn_off: 
                  id: backlight
                  transition_length: 1s     
    light:
      name: light
    moving_distance:
      name : Moving Distance
    still_distance:
      name: Still Distance
    moving_energy:
      name: Move Energy
    still_energy:
      name: Still Energy
    g0:
        move_energy:
          name: g0 move energy
        still_energy:
          name: g0 still energy
    g1:
      move_energy:
        name: g1 move energy
      still_energy:
        name: g1 still energy
    g2:
      move_energy:
        name: g2 move energy
      still_energy:
        name: g2 still energy
    g3:
      move_energy:
        name: g3 move energy
      still_energy:
        name: g3 still energy
    g4:
      move_energy:
        name: g4 move energy
      still_energy:
        name: g4 still energy
    g5:
      move_energy:
        name: g5 move energy
      still_energy:
        name: g5 still energy
    g6:
      move_energy:
        name: g6 move energy
      still_energy:
        name: g6 still energy
    g7:
      move_energy:
        name: g7 move energy
      still_energy:
        name: g7 still energy
    g8:
      move_energy:
        name: g8 move energy
      still_energy:
        name: g8 still energy

text_sensor:
   - platform: ld2410
    version:
      name: "firmware version"
    mac_address:
      name: "mac address"
switch:
  - platform: ld2410
    engineering_mode:
      name: "engineering mode"
    bluetooth:
      name: "control bluetooth"
light:
  - platform: monochromatic
    id: backlight
    name: "Backlight"
    output: oledbacklight
    default_transition_length: 250ms

output:
  - id: oledbacklight
    platform: ledc
    pin: GPIO9
    max_power: 1
    min_power: 0

using B-plug on the back of the M5 dail.
3) Any plans to add main page with icons for shortcuts to pages of the devices.
Thank you again. You are ROCK.
Screenshot 2024-04-23 175749

Example configuration problems

Wrong naming in the example config. Replacing the names with the suggestions worked.

  [screenOffTime] is an invalid option for [shys_m5_dial]. Did you mean [screen_off_time]?
  screenOffTime: 45000
  
  [rotaryStepWidth] is an invalid option for [shys_m5_dial]. Did you mean [rotary_step_width]?
  rotaryStepWidth: 5
  
  [longPressDuration] is an invalid option for [shys_m5_dial]. Did you mean [long_press_duration]?
  longPressDuration: 1200

After fixing those, I can install the software successfully, however the Dial screen stays black and it is not working.

Failed to upload a new .yaml

Whenever I try to upload a new or changed yaml onto the M5Dial, I get this information:

INFO Successfully compiled program.
INFO Connecting to 192.168.188.80
INFO Uploading /data/build/esphome-web-12c2f0/.pioenvs/esphome-web-12c2f0/firmware.bin (1311408 bytes)
Uploading: [============================================================] 100% Done...

INFO Upload took 13.83 seconds, waiting for result...
ERROR Error Update end: Error: Finishing update failed. See the MQTT/USB logs for more information.

I have to reflash the device at all, then it works again for first time, after the first try I get back to this fail...
Anybody has got an idea?

Discord link is inaccessible

As per above.

It's a direct link to a channel though. So maybe it should be a server invite? Not too sure myself

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.