Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add optional "Length" parameter to chuangmi_ir.py play_raw(). for "chuangmi.remote.v2" to send some command properly #820

Closed
Dozku opened this issue Sep 19, 2020 · 1 comment · Fixed by #1043

Comments

@Dozku
Copy link
Contributor

Dozku commented Sep 19, 2020

Is your feature request related to a problem? Please describe.
By soldering wire on TX0 and GND pins on the board then connecting them to TTL, the detail log can be seen using serial console(baud rate: 115200). The log contains TOKEN and all IR sent with details.
From the log(sent via HA) , I realized the reason why learned AC commands is not working is because it is lack the "length" parameter
image

If "length" parameter is appended, then the IR for AC is working without any issue.(Tried via miiocli rawcommand)
image

Describe the solution you'd like
By adding the optional length parameter to the function, the HA xiaomi IR component can be quickly enhanced to support AC commands.

PS. When sending IR command from Mi APP, the IR code/length/... will be shown on log; so basically all ir code supported by the Mi APP can be extracted.

Device information:
Model: chuangmi.remote.v2
Hardware version: esp32
Firmware version: 2.0.6_0006

I am not a good python programmer, so filing the issue and hoping someone good can implement it or provide a better soultion.

@Dozku Dozku changed the title Add optional "Length" parameter to chuangmi_ir.py play_raw(). for "chuangmi.remote.v2" to send AC command properly in HA Add optional "Length" parameter to chuangmi_ir.py play_raw(). for "chuangmi.remote.v2" to send some command properly Sep 19, 2020
@mpsOxygen
Copy link
Contributor

mpsOxygen commented Jun 13, 2021

Hello,

Do you have any idea how that length is being calculated? As I have not been able to trigger my AC by sending just the length of the b64 string.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants