User Tools

Site Tools


howto:growatt

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
howto:growatt [2023/06/19 00:20] – created Wulf Rajekhowto:growatt [2023/07/09 22:58] (current) – [Download Growatt Data Log History] Wulf Rajek
Line 5: Line 5:
 Initial passwords 12345678 / 1234 Initial passwords 12345678 / 1234
  
 +Dashboard:
 https://server.growatt.com/login https://server.growatt.com/login
 +
 +Warranty details:
 +https://www.ginverter.com/support/warranty
  
  
Line 18: Line 21:
 https://electricianforum.co.uk/threads/growatt-ct-discrepancy.56213/page-2 https://electricianforum.co.uk/threads/growatt-ct-discrepancy.56213/page-2
  
 +
 +Note: the inverter is doing a self test routine when the panels start supplying and when they cease eg sunrise and sunset. It goes into mode of drawing from the grid instead of the battery whilst this is going on, typically between 5 and 7 minutes.
 +
 +
 +===== Change Datalogger interval =====
 +
 +By default, the datalogger upload interval is every 5 minutes. This can be changed either by re-initialising the data-logger through it's Wifi Access point function, but it's a lot easier doing this through the server.growatt.com interface.
 +
 +Steps:
 +  - Log into https://server.growatt.com
 +  - Go to "All Device ->" in the My Photovoltaic Devices list\\ {{:howto:pasted:20230709-181824.png}}
 +  - Open the Data Logger Settings\\ {{:howto:pasted:20230709-181853.png}}
 +  - Click on "Advanced Set"\\ {{:howto:pasted:20230709-181916.png}}
 +  - Enter "4" as Register in the "Read" row, then enter "growatt"+current date in format YYYY-MM-DD as key like "growatt20230709" without the quotes and press "Read". This will return the current setting which is likely 5. This screenshot shows 1:\\ {{:howto:pasted:20230709-182154.png}}
 +  - To change the update interval value, enter 4 in the Register row above the read entry and set 1 as value, then click on 'Yes' at the bottom to save:\\ {{:howto:pasted:20230709-182248.png}}
 +  - Read the value again to confirm, then click cancel to close this window
 +  - Go back to the dashboard and click the (i) next to the Data Logger serial number to confirm the new interval again:\\ {{:howto:pasted:20230709-182507.png}}
 +
 +The graphs on server.growatt.com won't change, but the data logger history can be verified and obtained through a greasemonkey/violentmonkey/tampermonkey script as Growatt removed the button to view the data history from the server, but the underlying functionality is still there.
 +
 +Greasemonkey browser script:
 +<code>
 +// ==UserScript==
 +// @name         Growatt Device History
 +// @namespace    http://tampermonkey.net/
 +// @version      0.2
 +// @description  Adds a button on the main screen under devices to access the detailed historical data
 +// @author       You
 +// @require      https://gist.github.com/raw/2625891/waitForKeyElements.js
 +// @match        http*://*.growatt.com/index
 +// @icon         https://server-us.growatt.com/v3/images/favicon/favicon.ico
 +// @grant        none
 +// ==/UserScript==
 +
 +(function() {
 +    'use strict';
 +
 +    /* globals waitForKeyElements */
 +
 +    var historyButton=document.createElement("input");
 +    historyButton.type="button";
 +    historyButton.value="Get Historical Data";
 +    historyButton.setAttribute("style", "font-size:18px;position:relative;text-align:center");
 +    historyButton.onclick = showHistory;
 +
 +    function insertButton(jNode){
 +        jNode.html(historyButton)
 +    }
 +
 +    waitForKeyElements ("#tb_device_con > div > table > tbody > tr:nth-child(1) > td:nth-child(2)", insertButton);
 +
 +    function showHistory(){
 +        var inv = window.INVS[Object.keys(window.INVS)[0]];
 +        if(inv.deviceTypeName=="inv"){
 +            window.comm.dialogUrl({
 +                skin:"noPadding",
 +                id:"dialog_inverterHistory",
 +                title:"History Data("+inv.sn+")",
 +                url:"/device/getInverterHisPage",
 +                btns:[[window.comm.getI18n("no-more"),function(did,dialog){window.dialog_inverterHistory_search_More(did,dialog);},false,"btn_more dis"],['i18n_common_cancel',window.comm.dialogClose]],
 +                success:function(did,dialog){
 +                    window.dialog_inverterHistory_init(did,dialog,inv.sn);
 +                }
 +            });
 +        }else if(inv.deviceTypeName=="max"){
 +            window.comm.dialogUrl({
 +                skin:"noPadding",
 +                id:"dialog_maxHistory",
 +                title:"History Data("+inv.sn+")",
 +                url:"/device/getMAXHisPage",
 +                btns:[[window.comm.getI18n("no-more"),function(did,dialog){window.dialog_maxHistory_search_More(did,dialog);},false,"btn_more dis"],['i18n_common_cancel',window.comm.dialogClose]],
 +                success:function(did,dialog){
 +                    window.dialog_maxHistory_init(did,dialog,inv.sn,inv.deviceType);
 +                }
 +            });
 +        }else if(inv.deviceTypeName=="storage"){
 +            window.comm.dialogUrl({
 +                skin:"noPadding",
 +                id:"dialog_storageHistory",
 +                title:"History Data("+inv.sn+")",
 +                url:"/device/getStorageHisPage",
 +                btns:[[window.comm.getI18n("no-more"),function(did,dialog){window.dialog_storageHistory_search_More(did,dialog);},false,"btn_more dis"],['i18n_common_cancel',window.comm.dialogClose]],
 +                success:function(did,dialog){
 +                    window.dialog_storageHistory_init(did,dialog,inv.sn,inv.deviceType);
 +                }
 +            });
 +        }else if(inv.deviceTypeName=="mix"){
 +            window.comm.dialogUrl({
 +                skin:"noPadding",
 +                id:"dialog_mixHistory",
 +                title:"History Data("+inv.sn+")",
 +                url:"/device/getMIXHisPage?mixSn="+inv.sn,
 +                btns:[[window.comm.getI18n("no-more"),function(did,dialog){window.dialog_mixHistory_search_More(did,dialog);},false,"btn_more dis"],['i18n_common_cancel',window.comm.dialogClose]],
 +                success:function(did,dialog){
 +                    window.dialog_mixHistory_init(did,dialog,inv.sn);
 +                }
 +            });
 +        }else if(inv.deviceTypeName=="pcs"){
 +            window.comm.dialogUrl({
 +                skin:"noPadding",
 +                id:"dialog_pcsHistory",
 +                title:"History Data("+inv.sn+")",
 +                url:"/device/getPCSHisPage",
 +                btns:[[window.comm.getI18n("no-more"),function(did,dialog){window.dialog_pcsHistory_search_More(did,dialog);},false,"btn_more dis"],['i18n_common_cancel',window.comm.dialogClose]],
 +                success:function(did,dialog){
 +                    window.dialog_pcsHistory_init(did,dialog,inv.sn);
 +                }
 +            });
 +        }else if(inv.deviceTypeName=="hps"){
 +            window.comm.dialogUrl({
 +                skin:"noPadding",
 +                id:"dialog_hpsHistory",
 +                title:"History Data("+inv.sn+")",
 +                url:"/device/getHPSHisPage",
 +                btns:[[window.comm.getI18n("no-more"),function(did,dialog){window.dialog_hpsHistory_search_More(did,dialog);},false,"btn_more dis"],['i18n_common_cancel',window.comm.dialogClose]],
 +                success:function(did,dialog){
 +                    window.dialog_hpsHistory_init(did,dialog,inv.sn);
 +                }
 +            });
 +        }else if(inv.deviceTypeName=="spa"){
 +            window.comm.dialogUrl({
 +                skin:"noPadding",
 +                id:"dialog_spaHistory",
 +                title:"History Data("+inv.sn+")",
 +                url:"/device/getSPAHisPage",
 +                btns:[[window.comm.getI18n("no-more"),function(did,dialog){window.dialog_spaHistory_search_More(did,dialog);},false,"btn_more dis"],['i18n_common_cancel',window.comm.dialogClose]],
 +                success:function(did,dialog){
 +                    window.dialog_spaHistory_init(did,dialog,inv);
 +                }
 +            });
 +        }else if(inv.deviceTypeName=="tlx"){
 +            window.comm.dialogUrl({
 +                skin:"noPadding",
 +                id:"dialog_tlxHistory",
 +                title:"History Data("+inv.sn+")",
 +                url:"/device/getTLXHisPage",
 +                btns:[[window.comm.getI18n("no-more"),function(did,dialog){window.dialog_tlxHistory_search_More(did,dialog);},false,"btn_more dis"],['i18n_common_cancel',window.comm.dialogClose]],
 +                success:function(did,dialog){
 +                    window.dialog_tlxHistory_init(did,dialog,inv);
 +                }
 +            });
 +        }else if(inv.deviceTypeName=="jlInv"){
 +            window.comm.dialogUrl({
 +                skin:"noPadding",
 +                id:"dialog_jlInvHistory",
 +                title:"History Data("+inv.sn+")",
 +                url:"/device/getJlInvHisPage",
 +                btns:[[window.comm.getI18n("no-more"),function(did,dialog){window.dialog_jlInvHistory_search_More(did,dialog);},false,"btn_more dis"],['i18n_common_cancel',window.comm.dialogClose]],
 +                success:function(did,dialog){
 +                    window.dialog_jlInvHistory_init(did,dialog,inv);
 +                }
 +            });
 +        }else if(inv.deviceTypeName=="jfyInv"){
 +            window.comm.dialogUrl({
 +                skin:"noPadding",
 +                id:"dialog_jfyInvHistory",
 +                title:"History Data("+inv.sn+")",
 +                url:"/device/getJfyInvHisPage",
 +                btns:[[window.comm.getI18n("no-more"),function(did,dialog){window.dialog_jfyInvHistory_search_More(did,dialog);},false,"btn_more dis"],['i18n_common_cancel',window.comm.dialogClose]],
 +                success:function(did,dialog){
 +                    window.dialog_jfyInvHistory_init(did,dialog,inv);
 +                }
 +            });
 +        }else if(inv.deviceTypeName=="pbd"){
 +            window.comm.dialogUrl({
 +                skin:"noPadding",
 +                id:"dialog_pbdHistory",
 +                title:"History Data("+inv.sn+")",
 +                url:"/device/getPBDHisPage",
 +                btns:[[window.comm.getI18n("no-more"),function(did,dialog){window.dialog_pbdHistory_search_More(did,dialog);},false,"btn_more dis"],['i18n_common_cancel',window.comm.dialogClose]],
 +                success:function(did,dialog){
 +                    window.dialog_pbdHistory_init(did,dialog,inv);
 +                }
 +            });
 +        }else if(inv.deviceTypeName=="eybondInv"){
 +            window.comm.dialogUrl({
 +                skin:"noPadding",
 +                id:"dialog_eybondInvHistory",
 +                title:"History Data("+inv.sn+")",
 +                url:"/device/getEybondInvHisPage",
 +                btns:[[window.comm.getI18n("no-more"),function(did,dialog){window.dialog_eybondInvHistory_search_More(did,dialog);},false,"btn_more dis"],['i18n_common_cancel',window.comm.dialogClose]],
 +                success:function(did,dialog){
 +                    window.dialog_eybondInvHistory_init(did,dialog,inv.sn);
 +                }
 +            });
 +        }else if(inv.deviceTypeName=="igenInv"){
 +            window.comm.dialogUrl({
 +                skin:"noPadding",
 +                id:"dialog_igenInvHistory",
 +                title:"History Data("+inv.sn+")",
 +                url:"/device/getIgenInvHisPage",
 +                btns:[[window.comm.getI18n("no-more"),function(did,dialog){window.dialog_igenInvHistory_search_More(did,dialog);},false,"btn_more dis"],['i18n_common_cancel',window.comm.dialogClose]],
 +                success:function(did,dialog){
 +                    window.dialog_igenInvHistory_init(did,dialog,inv.sn);
 +                }
 +            });
 +        }else if(inv.deviceTypeName=="pumper"){
 +            window.comm.dialogUrl({
 +                skin:"noPadding",
 +                id:"dialog_pumperHistory",
 +                title:"History Data("+inv.sn+")",
 +                url:"/device/getPumperHisPage",
 +                btns:[[window.comm.getI18n("no-more"),function(did,dialog){window.dialog_pumperHistory_search_More(did,dialog);},false,"btn_more dis"],['i18n_common_cancel',window.comm.dialogClose]],
 +                success:function(did,dialog){
 +                    window.dialog_pumperHistory_init(did,dialog,inv.sn);
 +                }
 +            });
 +        }
 +    };
 +
 +
 +})();
 +</code>
 +https://diysolarforum.com/threads/data-history-removed-from-server-us-growatt-com.34331/
 +
 +The above script will add a "Get Historical Data" button to the server.growatt.com page:\\ 
 +{{:howto:pasted:20230709-181620.png}}
 +
 +Example History showing the change from 5 minute update interval to 1 minute update interval:\\ 
 +{{:howto:pasted:20230709-181511.png}}
 +
 +
 +===== Download Growatt Data Log History =====
 +
 +The following bash script downloads the historic data log into xls files for each day. The file needs start and end date as well as username, password and the serial number of the inverter as configuration options.
 +
 +<code bash growatt_history_download.sh>
 +#!/bin/bash
 +
 +startdate="20230614"
 +enddate="20230709"
 +interval=1
 +username="username"
 +password="password"
 +serialnumber="serialnumber"
 +
 +curl 'http://server-api.growatt.com/login' --compressed -X POST -H 'User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/115.0' -H 'Accept: application/json, text/javascript, */*; q=0.01' -H 'Accept-Language: en-GB,en;q=0.5' -H 'Accept-Encoding: gzip, deflate' -H 'Content-Type: application/x-www-form-urlencoded; charset=UTF-8' -H 'X-Requested-With: XMLHttpRequest' -H 'Origin: http://server-api.growatt.com' -H 'Connection: keep-alive' -H 'Referer: http://server-api.growatt.com/login' --cookie-jar cookies.txt --data-raw "account=${username}&password=${password}&validateCode=&isReadPact=0" --silent
 +
 +while [[ "${startdate}" -le "${enddate}" ]]; do
 +    # echo ${startdate}
 +    formatdate="$(date -d "${startdate}" +'%Y-%m-%d')"
 +    echo "Processing ${formatdate}"
 +
 +    curl 'http://server-api.growatt.com/device/exportMIXHistory' --compressed -X POST -H 'User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/115.0' -H 'Accept: application/json, text/javascript, */*; q=0.01' -H 'Accept-Language: en-GB,en;q=0.5' -H 'Accept-Encoding: gzip, deflate' -H 'Content-Type: application/x-www-form-urlencoded; charset=UTF-8' -H 'X-Requested-With: XMLHttpRequest' -H 'Origin: http://server-api.growatt.com' -H 'Connection: keep-alive' -H 'Referer: http://server-api.growatt.com/index' --cookie cookies.txt --data-raw "mixSn=${serialnumber}&startDate=${formatdate}&endDate=${formatdate}&start=1" -o "growatt-export_${formatdate}.xls" --silent
 +
 +    # set new start date based on interval
 +    startdate="$(date -d "${startdate} + ${interval} days" +'%Y%m%d')"
 +done
 +</code>
  
howto/growatt.1687130425.txt.gz · Last modified: 2023/06/19 00:20 by Wulf Rajek