solar-pv:用于查询和存储来自 Solarmax 逆变器的太阳能光伏发电数据到 mySQL 数据库的代码

  • D1_111023
    了解作者
  • 25.9KB
    文件大小
  • zip
    文件格式
  • 0
    收藏次数
  • VIP专享
    资源类型
  • 0
    下载次数
  • 2022-06-14 12:41
    上传日期
太阳能光伏 用于查询和存储来自 Solarmax 逆变器的太阳能光伏发电数据到 mySQL 数据库的代码 这是经过测试并在我家运行的,它在 4kW 系统中有一个 Solarmax 2000S 逆变器。 与逆变器通信的原始脚本可在以下位置找到: : 我已经将它翻译成 PHP,然后对其进行了一些编辑。 太阳位置的计算来自: : 我使用了电子表格并将方程式转换为 PHP。 安装/配置: 本地 将 solarmax 文件夹放在您家中的 *nix 服务器上(!); 我有一个 Ubuntu 服务器作为本地测试服务器和文件服务器,它运行 cron 作业。 在 config.php 中设置本地配置变量(见下文) 设置定时任务:*/5 * * * * php /path/to/pv.php >/dev/null 远程 该工作是基于 CodeIgniter 安装站点完成的,因此如果您将其放在
solar-pv-master.zip
  • solar-pv-master
  • CI_components
  • view.php
    1.5KB
  • controller.php
    1.1KB
  • pv_model.php
    8.2KB
  • .gitattributes
    483B
  • solmax
  • pv.php
    24.4KB
  • config.php
    643B
  • LICENSE.md
    34.3KB
  • README.md
    1.7KB
  • .gitignore
    1.9KB
内容介绍
solar-pv ======== Code for interrogating and storing solar pv generated data from a Solarmax inverter to a mySQL database This is tested and is operational at my house, which has a Solarmax 2000S inverter in a 4kW system. The original script for communicating with the inverter can be found at: http://blog.dest-unreach.be/2009/04/15/solarmax-maxtalk-protocol-reverse-engineered and I have translated it into PHP and then edited it a bit. The calculations for solar position are from: http://www.srrb.noaa.gov/highlights/sunrise/calcdetails.html where I used the http://www.srrb.noaa.gov/highlights/sunrise/NOAA_Solar_Calculations_day.xls spreadsheet and translated the equations to PHP. To install/configure: Locally ------------------------------------------------------------------------------ Put the solarmax folder onto a *nix server in your house (!); I have an Ubuntu Server as a local test server and file server, which runs the cron job. Setup the local configuration variables in config.php (see below) Setup the cron job: */5 * * * * php /path/to/pv.php >/dev/null Remotely ------------------------------------------------------------------------------ The work was done based on a CodeIgniter installation site, so you will have to rework this if you put it elsewhere. Copy controller.php -> your CI controllers folder pv_model.php -> your CI models folder view.php -> your CI views folder To do: ------------------------------------------------------------------------------ Re-work the entire dashboard for multiple pretty graphs and output data, with an ajax auto-update feature Tidy up the functions, wrap the whole lot into a class, possibly Enable recording of OPSTATES
评论
    相关推荐