Here is a self recommendation, I made a custom integration for XGIMI projector:
New XGIMI system seems to turn off the ADB access and I can not find an easy way to turn on ADB to use Android TV integration.
Details are in the readme of github repo. This integration is in very early stage, suggestions and contributions are welcome! Stars are welcome if you find it useful.
I was so glad to find this integration. It’s definitely frustrating to not be able to turn the projector on directly with HA, but i’ve kinda worked around it be sticking a Switchbot next to the power button, but would love to figure out how to manage the states in HA with that.
The power status(ON/OFF) is the state of the entity (e.g. remote.z6x) if you refering to that. Other status like the screen ON/OFF or media playing status is possible, but I am still working on that. BTW, an another alternative for powering ON is to turn on the auto-start-when-plug-in option in the system setting and use a smart plug to control.
Updates:
The newest XGIMI mobile app now has feature to turn on the projector through bluetooth. There is no pairing required in this procedure, it seems like a BLE advertisement. If so, it is possible to simulate the bluetooth signal to turn on the projector from HA. I tried to analysis btsnoop_hci.log by wireshark but no luck.
If anyone is familar with bluetooth protocol and willing to help please DM me
I did some experimentation with adding a bluetooth keyboard to the projector. I found I can use most of the remove functions using a keyboard. However I could not find a way to turn off the projector with the keyboard. If there is such a key that can emulate the power button then it might be possible to build a device using esp32 and GitHub - dmamontov/esphome-blekeyboard: ESPHome BLE Keyboard to emulate key presses and power on the projector.
UPDATE: it appears that the power button is not sending a typical keyboard press. The keyboard that I connected to the projector has a Bluetooth connection indicator light. The the projector is sleeping the indicator light is flashing meaning there’s no connection, so no button presses will be sent to the projector while it’s sleeping. The Xgimi remote must be sending some kind of broadcast. I don’t have the tools or knowledge to sniff the BLE messages to fingers out the messages, so hoping that somebody the does can figure this out and share with all of us.
Ok, after some searching and experimentation I managed to find a way to turn on Xgimi Halo+ using a BLE message sent from another device (in my case it was an Android phone using “nRF Connect for Mobile” app).
Well done and thank you for your contribution!
Maybe you can figure out how to send from the Bluetooth module of RPI directly, instead of ESPHome dongle.
@alexbeatle I suspect the Bluetooth module in RPI will be already used by Home Assistant’s Bluetooth integration.
Perhaps Home Assistant allows use of the BT module from a custom integration, but it’s a much steeper learning curve for me, compared to using ESP32, for which I have already played with BT stack and created a virtual BT keyboard, with which I can control the projector (except the power button).
For my use case I already have an ESP32 device near the projector (I’ve built it into the projector screen actually) so it seems logical to use it for powering on the projector.
@bachoo786 No I have not had a chance to experiment with it.
so if my xgimi elfin is powered off via the remote which I always do, how would the communication with Bluetooth even work?
If the device is completely powered off then the BT remote won’t work. The device needs to be in Standby mode. In standby it does disconnected any BT devices connected to it (such as BT keyboard), but does listed to special BT advertisement messages, which the remote power button sends. See more details: ios - How can I clone a non-paired BLE signal from a remote to trigger a device? - Stack Overflow
Power-on has been supported in the latest release of the Xgimi-4-Home-Assistant
Please see this issue
Currently, the ble advertisement is done through HA host(in my case RPI4), but it seems possible with esphome
Any way to use this to toggle Game Mode on and off? Would like to avoid scripting out all of the button presses to get there manually, if at all possible, to avoid all the obvious variables in doing that.