Same issue for me.
I played around a bit with the implementation in esphome and then chose the path of writing a component for the ādialā. At the moment I am concentrating on implementing the main functions for all entity types. When these functions are ready, I will continue with the layout of the screens.
Maybe the component will already help someone:
Great work, will try to compile on my M5dial
would be nice to emulate on the M5 physical HW the native esphome āclimate componentā and sync with HA UI
great! I did a few adjustments and submitted a pull request. Only thing that is not nice about this GUI is the fontā¦ Anything better available maybe?
First and foremost, great job and thanks you for the effort!
Iāve managed to install it and configure the m5dial, but I cannot get the entities listed in HA (only the firmware version appears)
What Iāve tried:
- renaming the dial
- adding a totally unrelated entity (sensor) to esphome yaml and this worked
- removing all the devices from shys_m5_dial: and leaving only one switch
- renaming the entities
- console logs show activity when using the dial (like changing the temperature or color etc.)
- firmware version entity gets updated normally
Yaml Config:
substitutions:
name: "esphome-web-d4a004"
wifi_ssid: !secret wifi_ssid
wifi_password: !secret wifi_password
esphome:
name: ${name}
name_add_mac_suffix: false
project:
name: smarthomeyourself.m5_dial
version: "1.0"
platformio_options:
lib_deps:
- WiFi
- SPI
- FS
- Wire
- EEPROM
- ArduinoJson
- m5stack/M5Unified
- m5stack/M5Dial
external_components:
- source:
type: git
url: https://github.com/SmartHome-yourself/m5-dial-for-esphome/
ref: main
components: [shys_m5_dial]
dashboard_import:
package_import_url: github://SmartHome-yourself/m5-dial-for-esphome/shys-m5-dial.yaml@main
import_full_config: false
esp32:
board: esp32-s3-devkitc-1
framework:
type: arduino
# Enable logging
logger:
level: DEBUG
# Enable Home Assistant API
api:
encryption:
key: "*****"
ota:
password: "*****"
improv_serial:
captive_portal:
wifi:
ssid: ${wifi_ssid}
password: ${wifi_password}
ap:
ssid: "Esphome-Web-D4A004"
password: "*****"
shys_m5_dial:
name: Dial
screen_off_time: 45000
rotary_step_width: 2
long_press_duration: 1200
font: FreeSans12pt7b
font_factor: 1
devices:
lights:
- entity: light.stairs
name: Light 1
modes:
dimm_mode:
enable: true
rotary_step_width: 2
rgb_mode:
enable: true
rotary_step_width: 5
white_mode:
enable: true
rotary_step_width: 10
min_kelvin: 7000
climates:
- entity: climate.house_heating
name: Heater
modes:
temp_mode:
rotary_step_width: 2
min_temperature: 4
max_temperature: 30
Any hints to try and debug / fix the issue would be highly appreciated.
Thanks,
M.
Same for me
I was able to sync the M5dial with my āclimateā component but I was not able to add the device/entity to esphome in HA
No auto discovery by HA and if I try to add manually via IP address in EspHome integation I got an error
Iāve played around with mine a little more, using some of @Squall290586ās code for the arcs. Changed some things around to use scripting rather than directly changes values when the encoder is rotated. A lot smoother now, but I will probably make the jumps in values a little smaller.
i have question, in the original soft.
The m5dial make bip on the rotation.
Have you found the pin to make a sound ?
thank in advance.
Have to define a few things. I didnāt use it because I didnāt find it quick enough, but havenāt gone back now things are a little more efficient
rtttl:
output: my_speaker_output
id: my_rtttl
output:
- platform: ledc
pin: GPIO3
id: my_speaker_output
And using this example, when the RFID is scanned I play a sound
rc522_i2c:
i2c_id: bus_internal
address: 0x28
on_tag:
then:
- rtttl.play: "success:d=24,o=5,b=100:c,g,b"
- homeassistant.tag_scanned: !lambda 'return x;'
Iām not sure if this is the best or only method, as Iāve not really looked into the speaker component. I find the physical click sound from the encoder is enough.
Is there any chance that your going to add the ability to scan RFID? When my dial was in the default firmware I tested scanning a card and it read it but after I installed your code (Thank you for) the RFID doesnāt do anything when I placed it on the dial.
Thank you again for your work.
For everyone following along, the display is now natively supported in esphome
I changed the display code to
- platform: ili9xxx
model: gc9a01a
reset_pin: GPIO8
id: my_lcd
cs_pin: GPIO7
dc_pin: GPIO4
dimensions:
height: 240
width: 240
You still need the custom component for the ft3267 touchscreen.
Shouldnāt model be M5STACK then ?
Didnāt even see it in the list, but thatās the square version, not the dial. When I use m5stack I get this
The native component seems a lot more performant as well, which is great.
Do you mind sharing your yaml file?
I posted it further up, but here it is esphome_files/m4_dial_v2.yaml at f7d57a31d51e24e87bda72b74bbb98e290113182 Ā· dgaust/esphome_files Ā· GitHub
Iāve changed it up so you only need to put the light, climate and cover entity_ids once in the substitutions section
substitutions:
# Add the ids of the devices you want to control here
light_control: light.great_room_dimmer_4
climate_control: climate.doris
cover_control: cover.sunshade
Thank you so much
Also found a handy 3d printable enclosure for it. You can fit a battery and usb-c charge controller in it if you wanted.
Hello. I try to install your yaml code on my m5 dial and stock in file validation. Itās shows me that:
Please help me to understand what itās mean , and how to fix that. Thank you.
Also,if you donāt mind to share some of the images for switches and other devices for this unit. I got a background and QR code , but not the rest of the images yet. Thank you again
Have you added the substitutions section in? Thatās where the delay is defined.
substitutions:
# Add the ids of the devices you want to control here
light_control: light.great_room_dimmer_4
media_player_control: media_player.living_room
climate_control: climate.doris
cover_control: cover.sunshade
script_delay: 1s
All the other images are MDI files, so you shouldnāt need to download them. Since Iām running a few dials now, I moved them to a separate file and use the include function to bring those into the device settings
<<: !include common/colors.yaml
<<: !include common/images.yaml
My mistake, I took a delay out some hoe when copy and paste your code. Thank you.
I create a colors.yaml and images.yaml files in esphome /common directory
Working now. Playing with settings and devices. Thank you very much for you hard work.