Hi, Let me first start with thanking everyone in putting effort in these initiatives!
A year ago we had a power failure, Everything was switched back on except the switch of the Converter. after a few month I found out that we did not make any electricity. Therefore now I want to use SBFspot on my raspberry pi. Found a how to and followed this.
Fist test:
/usr/local/bin/sbfspot.3/SBFspot -v -finq -nocsv
Resulted in:
SBFspot V3.4.0
Yet another tool to read power production of SMA solar inverters
(c) 2012-2018, SBF (https://github.com/SBFspot/SBFspot)
Compiled for Linux (LE) 32 bit with SQLite support
Commandline Args: -v -finq -nocsv
Reading config '/usr/local/bin/sbfspot.3/SBFspot.cfg'
Sat Dec 1 14:32:21 2018: INFO: Starting...
sunrise: 08:24
sunset : 16:39
Connecting to 00:80:25:A4:52:A5 (1/10)
Initializing...
SUSyID: 125 - SessionID: 812858049 (0x30733AC1)
SMA netID=01
Serial Nr: 7EF5DEC0 (2130042560)
BT Signal=64.3%
Logon OK
Local Host Time: 01/12/2018 14:32:22
Plant Time : 18/08/2008 10:47:09 (-324621913 sec)
TZ offset : 3600 sec - DST: On
Last Time Set : 21/04/2013 17:58:57
The time difference between inverter/host is more than 3600 seconds.
As a precaution the plant time won't be adjusted.
To overrule this behaviour, execute SBFspot -settime
SUSyID: 138 - SN: 2130042560
Device Name: SN: 2130042560
Device Class: Solar Inverters
Device Type: SB 5000TL-21
Software Version: 02.00.21.R
Serial number: 2130042560
SUSyID: 138 - SN: 2130042560
Device Status: Ok
SUSyID: 138 - SN: 2130042560
Device Temperature: 27.8°C
SUSyID: 138 - SN: 2130042560
GridRelay Status: Closed
SUSyID: 138 - SN: 2130042560
Pac max phase 1: 4600W
Pac max phase 2: 4600W
Pac max phase 3: 4600W
SUSyID: 138 - SN: 2130042560
Energy Production:
EToday: 3.327kWh
ETotal: 28747.763kWh
Operation Time: 24707.50h
Feed-In Time : 24044.81h
SUSyID: 138 - SN: 2130042560
DC Spot Data:
String 1 Pdc: 0.083kW - Udc: 357.15V - Idc: 0.234A
String 2 Pdc: 0.080kW - Udc: 357.15V - Idc: 0.228A
SUSyID: 138 - SN: 2130042560
AC Spot Data:
Phase 1 Pac : 0.101kW - Uac: 238.61V - Iac: 0.426A
Phase 2 Pac : 0.000kW - Uac: 0.00V - Iac: 0.000A
Phase 3 Pac : 0.000kW - Uac: 0.00V - Iac: 0.000A
Total Pac : 0.101kW
SUSyID: 138 - SN: 2130042560
Grid Freq. : 49.98Hz
SUSyID: 138 - SN: 2130042560
Current Inverter Time: 18/08/2008 10:47:09
Inverter Wake-Up Time: 18/08/2008 04:20:49
Inverter Sleep Time : 18/08/2008 10:47:09
********************
* ArchiveDayData() *
********************
startTime = 5C01C0F0 -> 01/12/2018 00:00:00
**********************
* ArchiveMonthData() *
**********************
startTime = 5C0269B0 -> 01/12/2018 12:00:00
**********************
* ArchiveMonthData() *
**********************
startTime = 5BDADCB0 -> 01/11/2018 12:00:00
Reading events: 2018-Dec-01
Sat Dec 1 14:32:24 2018: INFO: Done.
Then
cd /home/pi/smadata
sqlite3 SBFspot.db
SQLite version 3.16.2 2017-01-06 16:32:41
Enter ".help" for usage hints.
sqlite> select * from vwspotdata;
2018-12-01 14:35:05|2018-12-01 14:35:00|SN: 2130042560|SB 5000TL-21|2130042560|77|75|0.215|0.214|361.33|352.96|97|0|0|0.41|0.0|0.0|237.39|0.0|0.0|152|97|63.8|3332|28747768|49.98|24707.5|24044.9|64.3|OK|Closed|27.8
2018-12-01 14:32:24|2018-12-01 14:30:00|SN: 2130042560|SB 5000TL-21|2130042560|83|80|0.234|0.228|357.15|357.15|101|0|0|0.426|0.0|0.0|238.61|0.0|0.0|163|101|62.0|3327|28747763|49.98|24707.5|24044.8|64.3|OK|Closed|27.8
2018-12-01 14:30:05|2018-12-01 14:30:00|SN: 2130042560|SB 5000TL-21|2130042560|86|85|0.246|0.237|352.96|361.35|117|0|0|0.494|0.0|0.0|238.32|0.0|0.0|171|117|68.4|3323|28747759|49.99|24707.5|24044.8|65.1|OK|Closed|27.8
2018-12-01 12:45:04|2018-12-01 12:45:00|SN: 2130042560|SB 5000TL-21|2130042560|338|339|0.905|0.909|373.93|373.93|589|0|0|2.477|0.0|0.0|238.06|0.0|0.0|677|589|87.0|2800|28747236|49.99|24705.7|24043.0|69.0|OK|Closed|29.5
2018-12-01 12:40:04|2018-12-01 12:40:00|SN: 2130042560|SB 5000TL-21|2130042560|382|382|1.011|1.022|378.13|373.93|682|0|0|2.856|0.0|0.0|238.98|0.0|0.0|764|682|89.3|2746|28747183|50.01|24705.6|24042.9|69.4|OK|Closed|29.6
2018-12-01 12:35:03|2018-12-01 12:35:00|SN: 2130042560|SB 5000TL-21|2130042560|405|414|1.073|1.108|378.13|373.93|736|0|0|3.087|0.0|0.0|238.68|0.0|0.0|819|736|89.9|2688|28747124|50.0|24705.5|24042.9|69.4|OK|Closed|29.6
2018-12-01 12:30:05|2018-12-01 12:30:00|SN: 2130042560|SB 5000TL-21|2130042560|512|532|1.342|1.406|382.3|379.14|952|0|0|4.017|0.0|0.0|237.23|0.0|0.0|1044|952|91.2|2618|28747055|50.0|24705.5|24042.8|69.0|OK|Closed|29.4
2018-12-01 10:00:04|2018-12-01 10:00:00|SN: 2130042560|SB 5000TL-21|2130042560|182|363|0.446|0.891|408.12|408.1|514|0|0|2.2|0.0|0.0|233.82|0.0|0.0|545|514|94.3|324|28744761|50.02|24703.0|24040.3|65.1|OK|Closed|24.5
2018-12-01 09:55:03|2018-12-01 09:55:00|SN: 2130042560|SB 5000TL-21|2130042560|164|235|0.42|0.603|391.36|391.32|374|0|0|1.6|0.0|0.0|233.52|0.0|0.0|399|374|93.7|289|28744725|50.04|24702.9|24040.2|65.9|OK|Closed|24.3
2018-12-01 09:50:04|2018-12-01 09:50:00|SN: 2130042560|SB 5000TL-21|2130042560|216|308|0.537|0.79|403.29|390.71|452|0|0|1.913|0.0|0.0|236.31|0.0|0.0|524|452|86.3|255|28744691|50.03|24702.8|24040.1|66.3|OK|Closed|24.2
2018-12-01 09:45:04|2018-12-01 09:45:00|SN: 2130042560|SB 5000TL-21|2130042560|184|227|0.473|0.59|390.71|386.51|338|0|0|1.439|0.0|0.0|235.09|0.0|0.0|411|338|82.2|221|28744657|50.03|24702.7|24040.0|65.1|OK|Closed|24.0
2018-12-01 09:40:04|2018-12-01 09:40:00|SN: 2130042560|SB 5000TL-21|2130042560|162|200|0.434|0.529|373.93|378.13|291|0|0|1.245|0.0|0.0|234.65|0.0|0.0|362|291|80.4|196|28744632|50.03|24702.6|24039.9|66.7|OK|Closed|23.9
2018-12-01 09:35:04|2018-12-01 09:35:00|SN: 2130042560|SB 5000TL-21|2130042560|133|161|0.353|0.426|378.78|378.72|271|0|0|1.155|0.0|0.0|234.66|0.0|0.0|294|271|92.2|172|28744609|50.0|24702.5|24039.9|66.3|OK|Closed|23.8
2018-12-01 09:30:03|2018-12-01 09:30:00|SN: 2130042560|SB 5000TL-21|2130042560|157|208|0.407|0.537|387.17|387.12|339|0|0|1.431|0.0|0.0|236.86|0.0|0.0|365|339|92.9|148|28744584|50.01|24702.5|24039.8|66.3|OK|Closed|23.5
2018-12-01 09:25:04|2018-12-01 09:25:00|SN: 2130042560|SB 5000TL-21|2130042560|190|243|0.498|0.626|389.84|395.96|373|0|0|1.582|0.0|0.0|236.33|0.0|0.0|433|373|86.1|117|28744553|49.98|24702.4|24039.7|66.3|OK|Closed|23.3
2018-12-01 09:20:04|2018-12-01 09:20:00|SN: 2130042560|SB 5000TL-21|2130042560|168|190|0.437|0.494|386.51|386.51|283|0|0|1.246|0.0|0.0|236.43|0.0|0.0|358|283|79.1|90|28744526|50.01|24702.3|24039.6|65.5|OK|Closed|22.9
2018-12-01 09:15:04|2018-12-01 09:15:00|SN: 2130042560|SB 5000TL-21|2130042560|146|160|0.392|0.431|373.93|373.76|230|0|0|0.983|0.0|0.0|234.71|0.0|0.0|306|230|75.2|68|28744504|50.01|24702.2|24039.5|65.5|OK|Closed|22.6
2018-12-01 09:10:04|2018-12-01 09:10:00|SN: 2130042560|SB 5000TL-21|2130042560|115|127|0.313|0.344|369.74|369.57|172|0|0|0.741|0.0|0.0|233.34|0.0|0.0|242|172|71.1|51|28744487|49.99|24702.1|24039.4|65.1|OK|Closed|22.4
2018-12-01 09:05:04|2018-12-01 09:05:00|SN: 2130042560|SB 5000TL-21|2130042560|99|107|0.27|0.296|369.72|364.62|139|0|0|0.6|0.0|0.0|232.58|0.0|0.0|206|139|67.5|38|28744474|50.02|24702.0|24039.4|65.1|OK|Closed|22.0
2018-12-01 09:00:04|2018-12-01 09:00:00|SN: 2130042560|SB 5000TL-21|2130042560|90|97|0.25|0.264|361.35|369.57|120|0|0|0.514|0.0|0.0|233.86|0.0|0.0|187|120|64.2|27|28744463|50.02|24702.0|24039.3|65.1|OK|Closed|21.7
2018-12-01 08:55:04|2018-12-01 08:55:00|SN: 2130042560|SB 5000TL-21|2130042560|81|87|0.228|0.24|357.15|365.35|100|0|0|0.432|0.0|0.0|234.55|0.0|0.0|168|100|59.5|18|28744454|49.98|24701.9|24039.2|65.1|OK|Closed|21.2
2018-12-01 08:50:03|2018-12-01 08:50:00|SN: 2130042560|SB 5000TL-21|2130042560|78|82|0.217|0.228|361.33|361.18|91|0|0|0.388|0.0|0.0|235.39|0.0|0.0|160|91|56.9|10|28744446|50.0|24701.8|24039.1|65.5|OK|Closed|20.4
2018-12-01 08:45:04|2018-12-01 08:45:00|SN: 2130042560|SB 5000TL-21|2130042560|62|62|0.175|0.175|357.11|356.94|54|0|0|0.23|0.0|0.0|235.57|0.0|0.0|124|54|43.5|4|28744440|49.99|24701.7|24039.0|65.5|OK|Closed|20.0
2018-12-01 08:40:04|2018-12-01 08:40:00|SN: 2130042560|SB 5000TL-21|2130042560|46|45|0.149|0.147|311.02|310.85|27|0|0|0.117|0.0|0.0|236.54|0.0|0.0|91|27|29.7|1|28744437|49.99|24701.6|24038.9|65.1|OK|Closed|19.9
2018-12-01 08:35:03|2018-12-01 08:35:00|SN: 2130042560|SB 5000TL-21|2130042560|0|0|0.0|0.0|381.43|381.37|0|0|0|0.0|0.0|0.0|237.24|0.0|0.0|0|0|0|0|28744436|49.99|24701.5|24038.9|65.5|OK|Open|19.7
2018-12-01 08:30:04|2018-12-01 08:30:00|SN: 2130042560|SB 5000TL-21|2130042560|0|0|0.0|0.0|371.34|371.25|0|0|0|0.0|0.0|0.0|238.06|0.0|0.0|0|0|0|0|28744436|49.97|24701.5|24038.9|64.3|OK|Open|19.4
2018-12-01 08:25:04|2018-12-01 08:25:00|SN: 2130042560|SB 5000TL-21|2130042560|0|0|0.0|0.0|360.0|359.92|0|0|0|0.0|0.0|0.0|237.13|0.0|0.0|0|0|0|0|28744436|49.99|24701.4|24038.9|65.5|OK|Open|19.1
2018-12-01 00:34:33|2018-12-01 00:35:00|SN: 2130042560|SB 5000TL-21|2130042560|0|0|0.0|0.0|0.0|0.0|0|0|0|0.0|0.0|0.0|0.0|0.0|0.0|0|0|0|3765|28744436|0.0|24701.5|24038.9|64.7|OK|N/A|0.0
2018-11-30 23:20:11|2018-11-30 23:20:00|SN: 2130042560|SB 5000TL-21|2130042560|0|0|0.0|0.0|0.0|0.0|0|0|0|0.0|0.0|0.0|0.0|0.0|0.0|0|0|0|3765|28744436|0.0|24701.5|24038.9|65.5|OK|N/A|0.0
sqlite> .quit
sudo chmod +x daydata sudo chmod +x monthdata
then I did this
crontab -e ## Avoid "No MTA installed, discarding output" syslog messages MAILTO="" ## SBFspot */5 6-22 * * * /usr/local/bin/sbfspot.3/daydata 55 05 * * * /usr/local/bin/sbfspot.3/monthdata
And then this
sudo apt-get install libcurl3-dev
cd ~/SBFspot/SBFspotUploadDaemon
make sqlite
sudo make install_sqlite
cd /usr/local/bin/sbfspot.3
sudo cp SBFspotUpload.default.cfg SBFspotUpload.cfg
Then I changed the Config file
sudo nano SBFspotUpload.cfg
################################################################################
# SBFspotUpload.cfg - Configuration file for SBFspotUploadService/Daemon
# (c)2012-2014, SBF (https://sbfspot.codeplex.com)
#
# DISCLAIMER:
# A user of SBFspotUploadService/Daemon software acknowledges that he or she is
# receiving this software on an "as is" basis and the user is not relying on
# the accuracy or functionality of the software for any purpose. The user
# further acknowledges that any use of this software will be at his own risk
# and the copyright owner accepts no responsibility whatsoever arising from
# the use or application of the software.
#
################################################################################
################################
### Log Settings ###
################################
# Windows: C:\Users\Public\SMAdata\Logs
# Linux : /home/pi/smadata/logs
#LogDir=C:\Users\Public\SMAdata\Logs
LogDir=/home/pi/smadata/logs
#LogLevel=debug|info|error (default info)
################################
### PVoutput Upload Settings ###
################################
#PVoutput_SID
#Map inverters to PVoutput System ID's
#PVoutput_SID=SerialNmbrInverter_1:SID_1,SerialNmbrInverter_2:SID_2
#e.g. PVoutput_SID=200212345:4321
PVoutput_SID=2130042560:63374
#PVoutput_Key
#Sets PVoutput API Key
PVoutput_Key=c63122c877e5091fc6b849439cdf082b8112c454
################################
### SQL DB Settings ###
################################
# SQL_Database (Fullpath to SQLite DB)
# Windows: C:\Users\Public\SMAdata\SBFspot.db
# Linux : /home/pi/smadata/SBFspot.db
#SQL_Database=C:\Users\Public\SMAdata\SBFspot.db
SQL_Database=/home/pi/smadata/SBFspot.db
# Reserved for MySQL
#SQL_Database=SBFspot
#SQL_Hostname=<Network Name> or <IP-address>
#SQL_Username=SBFspotUser
#SQL_Password=SBFspotPassword
sudo nano /etc/rc.local
#Start SBFspotUploadDaemon /usr/local/bin/sbfspot.3/SBFspotUploadDaemon
sudo nano /usr/local/bin/sbfspot.3/SBFspotUpload.service
[Unit] Description=SBFspot Upload Daemon After=mysql.service mariadb.service network.target [Service] User=pi Type=simple TimeoutStopSec=10 ExecStart=/usr/local/bin/sbfspot.3/SBFspotUploadDaemon Restart=on-success [Install] WantedBy=multi-user.target
sudo systemctl enable /usr/local/bin/sbfspot.3/SBFspotUpload.service sudo systemctl start SBFspotUpload
Then I get this message and do not know how to proceed:
Exe
cuting: /lib/systemd/systemd-sysv-install enable sudo
Failed to enable unit: File /usr/local/bin/sbfspot.3/SBFspotUpload.service: Bad message
Please can somebody tell me what I’m doing wrong?