Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

voltronic_power_interface

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

voltronic_power_interface

  • 1.0.0
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

Voltronic Power Interface

A library to communicate with Voltronic Power inverter/PV products.

NOTE: The author of this library has no association with the above mentioned company

Some public documentation exists of supported commands and how to interpret the output.

Not all commands are supported by all devices

Use

SerialPort

NOTE: Only Ruby Gem serialport is currently supported

Linux/Mac OS X/BSD

Serial ports are typically found in /dev/tty* These devices may require root privilege in which case it is recommended to add a udev rule with less restrictive permissions.

Example udev rule for Prolific devices:

echo 'ATTRS{idVendor}=="067b", ATTRS{idProduct}=="2303", MODE="0666", SYMLINK+="ttyProlific"' > /etc/udev/rules.d/37-prolific.rules

require 'voltronic/protocol'
# => true

proto = Voltronic::Protocol.for_serialport('/dev/tty_usbserial')
# => Protocol(IO)

proto.execute 'QPI'
#=> '(PI30'

timeout = 0.5 # 500 milliseconds
proto.execute 'QPI', timeout
#=> '(PI30'

Windows

require 'voltronic/protocol'
# => true

proto = Voltronic::Protocol.for_serialport('COM1')
# => Protocol(IO)

proto.execute 'QPI'
#=> '(PI30'

timeout = 0.5 # 500 milliseconds
proto.execute 'QPI', timeout
#=> '(PI30'

USB

The implementation currently only support Linux using HIDRaw

To avoid running as root, execute the following to add a symlink with less restricted privileges

echo 'ATTRS{idVendor}=="0665", ATTRS{idProduct}=="5161", SUBSYSTEMS=="usb", ACTION=="add", MODE="0666", GROUP="root", SYMLINK+="hidVoltronic"' > /etc/udev/rules.d/35-voltronic.rules

require 'voltronic/protocol'
# => true

proto = Voltronic::Protocol.for_usb('/dev/hidVoltronic')
# => Protocol(IO)

proto.execute 'QPI'
#=> '(PI30'

timeout = 0.5 # 500 milliseconds
proto.execute 'QPI', timeout
#=> '(PI30'

FAQs

Package last updated on 09 Jul 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc