tristar-mppt-60-pod-openwrt
Toto je starší verze dokumentu!
Ukládání a vizualizace dat z regulátoru Morningstar Tristar MPPT 60 pod OpenWRT
Požadavky na hardware
- regulátor Morningstar Tristar MPPT 60
- router, na kterém běží Linuxová distribuce OpenWRT (nejlépe s USB a rozumným množstvím paměti např. Linksys WRT 160-NL) - viz http://wiki.openwrt.org/toh/start
Instalace a konfigurace
- nejprve nainstalujeme na router OpenWRT (např. upgrade přes webové rozhraní, nebo tftp klientem), více informací lze nalézt na http://wiki.openwrt.org/doc/howto/generic.flashing
- zprovozníme na routeru síť a to jak přístup na internet tak v lokální síti přístup na Morningstar Tristar MPPT 60
- pokud budeme data ukládat na USB, zprovozníme USB storage dle http://wiki.openwrt.org/doc/howto/usb.storage
- nainstalujeme collectd démona společně s modulem pro modbus a ukládání do CSV (samozřejmě můžeme nainstalovat jakýkoliv jiný backend např. collectd-mod-mysql):
opkg update opkg install collectd collectd-mod-modbus collectd-mod-csv
- upravíme konfigurační soubor /etc/collectd.conf
BaseDir "/var/lib/collectd" PIDFile "/var/run/collectd.pid" # data ukládat každých 120 sekund, není-li specifikováno jinak Interval 120 ReadThreads 2 # nahrajeme používáné moduly LoadPlugin modbus LoadPlugin csv # kam ukládat data, v tomto případě do /tmp/csv <Plugin "csv"> DataDir "/tmp/csv" StoreRates true </Plugin> # definice vyčítání dat z regulátoru, adresy dle dokumentace na stránkách výrobce <Plugin modbus> <Data "voltage-input-1"> RegisterBase 0x018 RegisterType Uint16 Type voltage Instance "voltage-battery" </Data> <Data "voltage-input-2"> RegisterBase 0x01b RegisterType Uint16 Type voltage Instance "voltage-array" </Data> <Data "current-input-1"> RegisterBase 0x01c RegisterType Uint16 Type voltage Instance "current-battery" </Data> <Data "kwh-input-1"> RegisterBase 0x039 RegisterType Uint16 Type voltage Instance "kwh-total" </Data> <Data "temp-input-1"> RegisterBase 0x023 RegisterType Uint16 Type voltage Instance "temp-chladic" </Data> <Data "temp-input-2"> RegisterBase 0x025 RegisterType Uint16 Type voltage Instance "temp-battery" </Data> <Data "wh-input-1"> RegisterBase 0x044 RegisterType Uint16 Type voltage Instance "wh-daily" </Data> <Data "wh-input-2"> RegisterBase 0x03A RegisterType Uint16 Type voltage Instance "power-output" </Data> <Data "charge-input-1"> RegisterBase 0x032 RegisterType Uint16 Type voltage Instance "charging-state" </Data> <Data "charge-input-2"> RegisterBase 0x033 RegisterType Uint16 Type voltage Instance "target-voltage" </Data> <Host "modbus"> # IP adresa regulátoru Address 192.168.1.100 # interval ukládání Interval 60 <Slave 0x01> Collect "voltage-input-1" Collect "voltage-input-2" Collect "current-input-1" Collect "kwh-input-1" Collect "temp-input-1" Collect "temp-input-2" Collect "wh-input-1" Collect "wh-input-2" Collect "charge-input-1" Collect "charge-input-2" Instance "tsmppt" </Slave> </Host> </Plugin>
tristar-mppt-60-pod-openwrt.1334688122.txt.gz · Poslední úprava: 2012/04/18 02:42 (upraveno mimo DokuWiki)