pyvesync icon indicating copy to clipboard operation
pyvesync copied to clipboard

Add Support for Levoit Smart Fan Air Circulator 432S- LPF-R432S

Open Mars455 opened this issue 1 year ago • 22 comments

Could support be added for this fan to the library? [https://community.home-assistant.io/t/vesync-integration-lpf-r432s-auk-levoit-smart-fan-air-circulator-432s/892762/9?u=mars455]

Useful Notes Fan Speed: 1-12 Modes: Normal, Turbo, Eco, Advanced Sleep Extra: Mute mode

[https://github.com/orgs/home-assistant/discussions/96]

Mars455 avatar Jul 16 '25 14:07 Mars455

Can you post the debug output when getting devices?

webdjoe avatar Jul 16 '25 22:07 webdjoe

I'm not particular versed with things like this, apologies. How would I go about testing this? Glad to give it a go today :)

Mars455 avatar Jul 18 '25 08:07 Mars455

Hello, I've the same modell and was able to extract some data from the fan:

{ "deviceRegion": "EU", "isOwner": true, "authKey": null, "deviceName": "Ventilator", "deviceImg": "https://image.vesync.com/defaultImages/deviceDefaultImages/VS_WFON_STF_LPF-R432S-AEU_EU.png", "cid": "##REDACTED##", "deviceStatus": null, "connectionStatus": null, "connectionType": "WiFi+BTOnboarding+BTNotify", "deviceType": "LPF-R432S-AEU", "type": "wifi-air", "uuid": "##REDACTED##", "configModule": "VS_WFON_STF_LPF-R432S-AEU_EU", "macID": "##REDACTED##", "mode": null, "speed": null, "currentFirmVersion": null, "subDeviceNo": null, "subDeviceType": null, "deviceFirstSetupTime": "Jul 5, 2025 12:34:41 PM", "subDeviceList": null, "extension": null, "deviceProp": { "wifiMac": "xx:xx:xx:xx:xx:xx", "isTimerSupportPowerOn": 1, "workMode": "advancedSleep", "BTMac": "xx:xx:xx:xx:xx:xx", "verticalOscillation": 0, "childLock": 0, "screenSwitch": 0, "fanSpeedLevel": -1, "wifiRssi": -71, "horizontalOscillation": 0, "oscillationCoordinate": { "yaw": 20, "pitch": 90 }, "tempInF": 779, "smartCleaningReminder": 1, "sleepPreferenceType": "default", "powerSwitch": 0, "oscillationRange": { "left": 30, "right": 55, "top": 20, "bottom": 120 }, "connectionStatus": "online" }

hesral avatar Jul 18 '25 12:07 hesral

Hi there,

I recently bought the same fan. I would like to have it available in Home Assistant through VeSync and would be happy to help on this subject.

Let me know if you require any assistance.

tobliug avatar Jul 25 '25 11:07 tobliug

Thank you for posting! This is next on the list after I fix the authentication method, likely a week for me to integrate into pyvesync.

webdjoe avatar Jul 25 '25 13:07 webdjoe

Amazing thank you!

Mars455 avatar Jul 25 '25 16:07 Mars455

+1 Any progress on this? I bought the fan wrongly believing it would work with HA. My bad.

jaydee256 avatar Aug 25 '25 06:08 jaydee256

@jaydee256 We're all patiently waiting

ventrue101 avatar Aug 27 '25 11:08 ventrue101

+1 on awaiting the update ;)

Organizer21 avatar Aug 28 '25 15:08 Organizer21

I am working on this now. Can you post captures of the fan controls and status? If you don't want to post here, I'll send you a discord message.

webdjoe avatar Aug 30 '25 01:08 webdjoe

I am working on this now. Can you post captures of the fan controls and status? If you don't want to post here, I'll send you a discord message.

What do you need exactly? I've provided some information in this comment: https://github.com/webdjoe/pyvesync/issues/330#issuecomment-3089367375

hesral avatar Aug 30 '25 11:08 hesral

I need the device status request and response and action requests and responses. Here is a high level overview of the steps needed to capture packets or you can share the device temporarily with me and I can capture on my end:

What you will need to install:

  1. Mumu Emulator

  2. Charles Proxy - You can use the free trial

  3. Android Platform Tools (CLI tools) - https://developer.android.com/studio scroll to bottom "Command Line Tools Only"

  4. Install Applications, create a new project directory

  5. Get Charles Proxy certificate from Help--> SSL Proxying --> Save Root Certificate --> cert format. Then move to project directory and rename to cert-der.crt

  6. Download VeSync APK from apk pure, xapk is fine

  7. Create a virtual python environment in one terminal in project working directory

  8. Download latest frida-server for android x64 and extract into project directory. Probably need to click show all assets on the release page and look for the frida-server-X.X.X-android-x86_64.xz. The release page is https://github.com/frida/frida/releases.

  9. Ensure adb is installed. If you installed command line tools, try to restart the terminal you are using and if you are on windows ensure C:\Users\YOUR_USERNAME\AppData\Local\Android\Skd\platform-tools is on your system path

  10. Run Mumu

  11. Install VeSync xapk/apk from Mumu interface through down arrow at top right

  12. Once Mumu starts, in the second terminal run adb connect localhost:7555 to connect adb to Mumu

  13. On the second terminal run adb root

  14. In the python virtual environment on the first terminal run pip install frida-tools

  15. In the second terminal (where adb commands were run) push the frida server executable extracted in step 4 to the android device adb push frida-server /data/local/tmp.

  16. In same terminal push Charles proxy certificate adb push cert-der.crt /data/local/tmp

  17. In the same terminal open android shell and run frida server. Leave this terminal running, there should be no output when the server is running.

adb shell
cd /data/local/tmp
chmod +x frida-server
./frida-server
  1. Ensure Charles Proxy is running and SSL proxying is enabled. Set proxy in wireless android settings in Mumu.
  2. In the terminal with the python virtual environment activated, run frida -U --codeshare akabe1/frida-multiple-unpinning -f com.etekcity.vesyncplatform
  3. The prior command should trigger the VeSync app to open. Log in, selecting the correct country.
  4. Check Charles Proxy and filter for smartapi. Check that the login requests have been successfully decoded and you can see the request and response body.
  5. Go back to VeSync and go to the device. Change settings, modes and speeds, moving to the device list and then back into the device for each command. Please include all possible settings, including the timer/schedule.
  6. Export the Charles Proxy capture and email me at webdjoe at gmail

webdjoe avatar Sep 22 '25 01:09 webdjoe

Ouch that sounds above my head as to easily help. That aside, did I see someone provide (share) account details in another thread as for this to be debugged for progress - or is that just something I misunderstood? Maybe it that was for adding another device than the 432S fan in either case, or login issues.

Organizer21 avatar Oct 12 '25 20:10 Organizer21

I think that was for login issues. Someone did share an account that helped the login issue get solved. I would be willing to do the captures if you would be willing to share the device with my account.

cdnninja avatar Oct 13 '25 02:10 cdnninja

I think that was for login issues. Someone did share an account that helped the login issue get solved. I would be willing to do the captures if you would be willing to share the device with my account.

Can I share the device and then revoke that sharing? If so, I'm all game. I can do the steps above, but I need to find some free time (work, kids, etc)

sirmeili avatar Oct 14 '25 13:10 sirmeili

Yes that is correct.

cdnninja avatar Oct 17 '25 01:10 cdnninja

Yes that is correct.

Let me know how to share with you and we can collaborate a time (I don't keep the air fryer plugged in all the time, but I can keep it plugged in for a few days if need be so you can take your time)

sirmeili avatar Oct 20 '25 11:10 sirmeili

Could you ping me on discord? Same username as here.

cdnninja avatar Oct 25 '25 01:10 cdnninja

Could you ping me on discord? Same username as here.

I added you, but my name there starts with Frank so that you know who it is

sirmeili avatar Oct 25 '25 01:10 sirmeili

As a note, the above device wasn't different so still looking for captures from someone with that exact model of air circulator.

cdnninja avatar Nov 01 '25 20:11 cdnninja