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

will we have an apk? #1

Open
carborundum7 opened this issue Feb 20, 2024 · 17 comments
Open

will we have an apk? #1

carborundum7 opened this issue Feb 20, 2024 · 17 comments

Comments

@carborundum7
Copy link

Tried to buid from source with my limited skills with no luck. can we have an apk for old android devices? like android 8?

@Fabi019
Copy link
Owner

Fabi019 commented Feb 20, 2024

Hi, thanks for your interest. I will create a release which will contain an signed apk to download.
In theory the app should be compatible and installable on devices as low as android 7.0 (maybe even lower). However since I don't have such a device I haven't tested it out.

@carborundum7
Copy link
Author

that would be very nice! I appreciate so much your work, it will help me and other in the future to self host data from meross devices

@Fabi019
Copy link
Owner

Fabi019 commented Feb 21, 2024

I just published the release. If you want to try it out, let me know if everything works or if there are any problems

@carborundum7
Copy link
Author

you're a boss!! thanks!
so downloaded, installed. i have the mss305zt smart plug and i can see it with the app via bluetooth, without device info. for some reason i cant load wifi ssid list. it seems that the device does not answer back
i was wondering, do i need to pass trough home assistant or connect directly to an mqtt broker?
again, thank you very much

@Fabi019
Copy link
Owner

Fabi019 commented Feb 22, 2024

Does the device answer if you press the read button for the device info or only for the wifi list not?
To better look into this, it would be help me if you could tell me what android version your device runs. Also if possible, a (partial) screenshot of the log window inside the app.

@Fabi019
Copy link
Owner

Fabi019 commented Feb 22, 2024

I was able to fix a bug that affected devices with android version lower than 12 and caused them to not receive any data. You can try out the latest release to see if that fixed the problem.

@carborundum7
Copy link
Author

Hi! Thank you for updates, very appreciated. Right now, with the updated app I can connect to the device and read its info, set up Matt server and port and the userID stuff (that I'm still figuring out). When I try to set the wifi configuration, i can read all wifi connections but somehow it wont accept them. Tried with 2 2.4ghz connections but nothing. From logs the only things that I can see is a crc error. Everything is shown in screenshots. My system is an android 9
A question: is there any way to just set the mqtt broker, login and password for the mqtt, connecting straight to the broker?
Again, thank you very much

Screenshot_20240223-092914_MerossBLE
Screenshot_20240223-092832_MerossBLE

@Fabi019
Copy link
Owner

Fabi019 commented Feb 23, 2024

From the logs I can see, that the switch responded with a SETACK. This would mean that it sucessfully received the wifi configuration.

What is the behaviour of the led on the switch? Normally after writing the wifi it should start blinking only green while trying to connect to the wifi.

When this was successful, the light should stay on.

  • Solid green then means that it connected to the MQTT
  • Solid red means it couldn't connect to the MQTT

If the connection to the wifi was not possible, it should go back to the alternating color blink mode. That would mean it couldn't connect to the wifi. As a first attempt, I would recomment double checking the password and also if your wifi maybe has some sort of mac filter that blocks unknown devices.

@carborundum7
Copy link
Author

I have alternating blinking color. Will double check and update you
Thank you🤙

@carborundum7
Copy link
Author

i'm back! so i found 2 issues:
-my wifi password is like 70 caracters long, for some reason is not working. changing it to something like 11111111 works but i'm not comfortable reducing wifi security
-when connected, i have solid red light. i have tried several combination of ip adresses and hostnames to point to my mqtt server but no luck. maybe you can tell me more about the structure of the input data, please

@Fabi019
Copy link
Owner

Fabi019 commented Feb 24, 2024

Thanks for reporting back. Good to hear that it worked at least with shorter passwords. I will try to find the reason why it doesn't works with longer ones.

Regarding the mqtt server. It is important, that it is a encrypted mqtt server. The normal one over port 1883 won't work as the device will not connect with it. You will need a seperate server listener eg. on port 8883. When using mosquitto as the broker you can define multiple interfaces (port 1883 and 8883). A good guide on how to setup the server/certificates can be found here https://github.com/bytespider/Meross/wiki/MQTT. In the end you mosquitto.conf could look like this:

allow_anonymous true

listener 8883
require_certificate false

cafile   ../certs/ca.crt
certfile ../certs/server.crt
keyfile  ../certs/server.key

listener 1883

@carborundum7
Copy link
Author

hi, thanks for the update. i have kinda implemented all the certificate stuff but still the main issue is the password lenght with special caracters. same password works well with the meross official app
anyway, have a nice day :)

@Fabi019
Copy link
Owner

Fabi019 commented Feb 25, 2024

I was able to fix a bug in the password encryption calculation that affected passwords longer that 16 characters in the latest version. This might solve your password issue.

@carborundum7
Copy link
Author

woohoo!!! works! now i has connected to my router without issues. you're the best! :D
now i have the red static light and i can see the meross device from the router list of devices. so now i will try to configure mqtt with port 8883 and report my progress here, for people that would want to do the same
thank you, your're the BOSS!!

@carborundum7
Copy link
Author

hi, i'm giving up. your app is perfect but i can't make the device connect to my mqtt server. i have tried everything: using different computers, generating certificates with different common names, reading left and right for every solution, changing permissions but the device just refuses to turn green. it happened once yesterday but i have no idea on how to replicate that behaviour..
i will open the device, remove the microcontroller, connect an esp8266 directly to the power sensor and read all the data that way
i'm really grateful for your work, thank you a lot!!!

@Fabi019
Copy link
Owner

Fabi019 commented Feb 25, 2024

Did you also look into the logs of the mqtt server to comfirm that it doesn't connect? For me it also was the case for one switch that was on red but actually connected sucessfully and I was able to control the device in home assistant. After some time then it turned itself green.

@carborundum7
Copy link
Author

now i have discovered that it does connect and puplishes a strange json. what i'm looking for is the power value but from mqtt explorer, i just get the bind info... i'm searching on how to send commands to the device but for now no luck. will update on progress

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

No branches or pull requests

2 participants