- Notifications
You must be signed in to change notification settings - Fork8
Kajkac/ZTE-MC-Home-assistant
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
This part will stop being developed i am switching to Home assistant custom_integration so from now on i will be releasing on this repo :https://github.com/Kajkac/ZTE-MC-Home-assistant-repo
Whoever wanna something to add or propose let me know and i will see if i can put that into integration
ZTE Home assistant addon
Supported models :
MC801AMC889MC888
You can add home assistant sensors and SMS parsing from Zte MC801A router
UPDATE : modified configuration to support new versions of Home assistant
- Add command line merge directory : command_line: !include_dir_merge_list command_line/ to configuration.yaml
- Adjust sensors.py
- Add command_line directory from repo
- Comment out ZTE switches
- Restart and test
You need to create folder inside Home Assistant (under/root/config/
) named :
python_scripts sensors switch
After that you need to add toconfiguration.yaml
:
sensor: !include_dir_merge_list sensors/switch: !include_dir_merge_list switch/command_line: !include_dir_merge_list command_line/ to configuration.yaml
in filezte_tool.py
you need to replace ip and password with your own values:
zteInstance = zteRouter("IP OF ROUTER", "PASSWORD")
After all that reboot HA and all sensors in Home assistant will be created
SMS SENDER : (for anyone who has like me need to send sms-s after you spend your data plan, or you just need sms :)
Edit lines inzte_tool.py
need for sending sms :
phoneNumber = 'PHONENUMBER' # enter phone number heremessage = 'MESSAGE' # enter your message herezteInstance = zteRouter("192.168.0.1", "PASSWORD") # enter your router IP nad password here
Switch for send (you can create that from switches)
Home assistant part :
Look in switches configuration...
Automation for send SMS (you can put toautomations.yaml
): are in repo as yaml with clean and reboot automations
UPDATE : modified configuration to support new versions of Home assistant
From 2023.8.0 Command line is moving so you need to adjust the configuration like
FURTHER INFO : I switch all to python and next step is to try to pack it like Hassio addon or integration, but for now this is functioning for me, anyone wanna contribute u can use this code and expand the funcionalities, like i use lot of code from guys bellow to achieve any functionalites so big thanks to them to share code.
And also i will try to pull all the parameter out of onfiguration files so that all stuff will be at one place.
Special thanks to:
https://github.com/ngarafol - for providig fixes along the way to this repohttps://github.com/gediz/Superbox-Helperhttps://github.com/paddy-314/zteRouterReboot/blob/1e3977979ae2dfb6bb05dc28fb9cda233174f437/README.mdpaulo-correia/ZTE_API_and_Hack - for list of Requests and PHP ClassMohammad Aghazadeh - for MD5 hash and UTF8 EncodingBehzad Ebrahimi - for encode unicode string in "UCS2" formatgediz/trivial-tools-n-scripts/blob/superbox-hacks - for AD calculating algorithmhttps://habr.com/en/post/277637/andhttp://www.bez-kabli.pl/viewtopic.php?f=12&t=62164for providing me a solution to autheticating and parsing data from ZTE router
About
ZTE MC801A, MC888, MC889 Home assistant addon
Topics
Resources
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Packages0
Uh oh!
There was an error while loading.Please reload this page.