Dear community,
I have Xiaomi Gateway with a lot of sensors (temperature, wireless switch, and so on), everything works perfect. Today I got my first Aqara Magic Cube, but there’s no way to discover it in HA.
I properly configured the Magic cube on Mi App, and automations work from that app, but HA cannot discover it. As far I know should be discovered as: binary_sensor.cube_XXXXXXX
Could someone help here?
Thank you
Lucas
Did you try restarting your HA, that is what I had to do.
Sure, restarted lot of time. Btw, I solved updating xiaomi_aqara.py
(3 files) from here:
Now, I can see the Magic Cube in HA.
Take care, with this update xiaomi_aqara.py
files should be updated from the following dirs:
/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/
/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/lock
/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/binary_sensor
DAMN! Spoke too early… I can see the Magic Cube in HA, but automation doesn’t work 
The following will result in no action at all with no error message from HA:
- id: cube_action_flip90
alias: Cube Flip90
trigger:
platform: event
event_type: cube_action
event_data:
entity_id: binary_sensor.cube_158d000231e69e
action_type: flip90
action:
- service: light.toggle
entity_id: light.lucas
Could someone advise?
EDIT: Find issue related to the new Aqara Cube:
https://github.com/home-assistant/home-assistant/pull/14393
That’s why the automation doesn’t work.