Coder Social home page Coder Social logo

dabbsson_control's Introduction

Dabbsson_control

This repository is about getting access to your Dabbsson DBS2300 and Dabbsson DBS3000B powerstation via WiFi without using the official app. This is not a ready-made solution but only an approach.

Why?

From my point of view, the DBS2300 and DBS3000B are good products and I am very happy them. The only disadvantage is that only the official app can be used for communication.

Using the powerstation just with the Dabbsson app (pressing stupid buttons) is not what I needed. I wanted to automate switching the power outputs according to the current inputs and battery state of charge.

In addition to that I don´t want my devices "calling home". That was something I observed while I did my first investigations using Wireshark. Unfortunately all traffic was encrypted and therefore not helpful.

Setup

After getting control (see "What to do?") I was using a Raspberry Pi Zero W to control the powerstation. The Rpi creates an WiFi Access Point to which the DBS2300 connects. The Rpi does not provide internet access over the wifi interface. The Rpi is connected over a usb-to-ethernet-adapter to my home network and provides a HTTP-server to access the data or to control the device. You do not need to do this. You just can connect the DBS2300 directly to your network.

What to do?

After a while with Wireshark I figured out that the DBS2300 is using Tuya. To do the first steps you can follow the instructions of TinyTuya. Basically getting an developers Account and connect your DBS2300 with the official Tuya Smart app to generate a local key and get the device id. Without a local key, you can no communicate with your device. You do not need the official Tuya app afterwards. But you need it to get the key.

Be aware the official Dabbsson app will not work anymore after that! I haven´t tried to go back to the official app. All you do is at your own risk!

You can use TinyTuya to control your device as shown in this repository.

Example data from the DBS2300 looks like this:

{'protocol': 4, 't': 63848, 'data': {'dps': {'156': 'zQAAAADOAAAAANAAAAAA0QAAAADcExwhAN0AAAAB3gAAABs='}}}

{'protocol': 4, 't': 63848, 'data': {'dps': {'1': 9, '2': 4761, '10': 19, '103': 0, '104': 0, '105': 0, '106': 0, '110': 0, '108': 0, '138': 25, '139': 0}}, 'dps': {'1': 9, '2': 4761, '10': 19, '103': 0, '104': 0, '105': 0, '106': 0, '110': 0, '108': 0, '138': 25, '139': 0}}

Example key-value pairs (there are more)

key value
1 State of charge DBS2300 in %
10 Temperature of DBS2300
103 DC-Input of DBS2300
105 DC-Output of DBS3000B
108 Output of DBS2300
109 AC-Out on/off
111 5V-Out on/off
112 12V-Out on/off
123 A/C input power
138 State of charge DBS3000B in %
156 Base64 encoded information of DBS3000B (including keys 205, 206, 208, 209, 220, 221, 222)

The HTTP-Server (see checkDBS2300.py) will give you on http://localhost:9980/status some of the information:

{"timestamp": 64138, "battery_1_load": 9, "battery_2_load": 25, "battery_1_temp": 18, "battery_2_temp": 27, "battery_1_solar_input": 0, "battery_2_input": 0, "battery_1_output": 0, "battery_2_output": 0, "ac_on": false, "dc_on": false, "v12_on": false}

With http://localhost:9980/set you can toggle the AC-Output. In addition the AC-Output is turned off if the state of charge gets below 10%.

References

Legal Disclaimer

As mentioned before:

This is not a ready-made solution but only an approach! All you do is at your own risk!

The information and tools provided in this repository are intended for educational and research purposes only. The author is not responsible for any misuse or damage resulting from the use or misuse of the information or software provided here.

This project is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY. Use this software at your own risk.

dabbsson_control's People

Contributors

nilsti avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

dabbsson_control's Issues

Setup

Ich habe am Wochenende angefangen und iobroker den API-Zugriff mit Javascript umgesetzt und versuche das erst einmal ohne produktive Daten umzusetzen. Ich habe mir zusätzlich noch einen Raspberry Zero bestellt und werde dann am nächsten Wochenende dann diesen bestücken und lauffähig machen.

{'protocol': 4, 't': 63848, 'data': {'dps': {'1': 9, '2': 4761, '10': 19, '103': 0, '104': 0, '105': 0, '106': 0, '110': 0, '108': 0, '138': 25, '139': 0}}, 'dps': {'1': 9, '2': 4761, '10': 19, '103': 0, '104': 0, '105': 0, '106': 0, '110': 0, '108': 0, '138': 25, '139': 0}}

1 | State of charge DBS2300 in %
2???
10 | Temperature of DBS2300
103 | DC-Input of DBS2300
104????
105 | DC-Output of DBS3000B
106 ????
108 | Output of DBS2300
109 | AC-Out on/off
110????
111 | 5V-Out on/off
112 | 12V-Out on/off
123 | A/C input power
138 | State of charge DBS3000B in %
139????
156 | Base64 encoded information of DBS3000B (including keys 205, 206, 208, 209, 220, 221, 222)

Ich habe vor, die Eingangsleistung in Watt dynamisch zu steuern und zwar auf Basis der aktuell vorhandenen Kapazitäten und die Ausgangsleistung in Watt.

Das fehlt mir bisher. und kann die Beladung und die Einspeisung bisher per schaltbarer Steckdose steuern.
Das reicht mir aber nicht, weil ich bisher die Eingangsleistung in Watt vorgeben muss in der App.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.