• Stars
    star
    3
  • Rank 3,866,121 (Top 79 %)
  • Language
    Perl
  • License
    Other
  • Created about 12 years ago
  • Updated over 9 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Perl modules for controlling Onkyo/Integra AV Receivers
NAME
    Device::Onkyo - Perl module to control Onkyo/Integra AV equipment

VERSION
    version 1.143640

SYNOPSIS
      my $onkyo = Device::Onkyo->new(device => 'discover');
      $onkyo->power('on'); # switch on

      $onkyo = Device::Onkyo->new(device => '/dev/ttyS0');
      $onkyo->write('PWR01'); # switch on
      while (1) {
        my $message = $onkyo->read();
        print $message, "\n";
      }

      $onkyo = Device::Onkyo->new(device => 'hostname:port');
      $onkyo->write('PWR01'); # switch on

DESCRIPTION
    Module for controlling Onkyo/Intregra AV equipment.

    IMPORTANT: This is an early release and the API is still subject to
    change. The serial port usage is entirely untested.

METHODS
  "new(%parameters)"
    This constructor returns a new Device::Onkyo object. The supported
    parameters are:

    device
        The name of the device to connect to. The value can be a tty device
        name or "hostname:port" for TCP. It may also be the string
        'discover' in which case automatic discovery will be attempted. This
        value defaults to 'discover'.

    filehandle
        The name of an existing filehandle to be used instead of the
        'device' parameter.

    type
        Whether the protocol should be 'ISCP' or 'eISCP'. The default is
        'ISCP' if a tty device was given as the 'device' parameter or
        'eISCP' otherwise.

    baud
        The baud rate for the tty device. The default is 9600.

    port
        The port for a TCP device. The default is 60128.

    broadcast_source_ip
        The source IP address that the discovery process uses for its
        broadcast. The default, '0.0.0.0', should work in most cases but
        multi-homed hosts might need to specify the correct local interface
        address.

    broadcast_dest_ip
        The IP address that the discovery process uses for its broadcast.
        The default, '255.255.255.255', should work in most cases.

  "device()"
    Returns the device used to connect to the equipment. If a filehandle was
    provided this method will return undef.

  "type()"
    Returns the type of the device - either 'ISCP' or 'eISCP'.

  "baud()"
    Returns the baud rate only makes sense for 'ISCP'-type devices.

  "port()"
    Returns the TCP port for the device only makes sense for 'eISCP'-type
    devices.

  "filehandle()"
    This method returns the file handle for the device.

  "read([$timeout])"
    This method blocks until a new message has been received by the device.
    When a message is received the message string is returned. An optional
    timeout (in seconds) may be provided.

  "read_one(\$buffer)"
    This method attempts to remove a single message from the buffer passed
    in via the scalar reference. When a message is removed a data structure
    is returned that represents the data received. If insufficient data is
    available then undef is returned.

  "discover()"
    This method attempts to discover available equipment. It returns a list
    reference of list references of ip and port pairs.

    Currently only the first responding device is returned.

  "write($command, $callback)"
    This method queues a command for sending to the connected device. The
    first write will be written immediately, subsequent writes are queued
    until a response to the previous message is received.

  "pack($command)"
    This method takes a command and formats it for sending to the device.
    The format depends on the device type.

  "command($command, [$callback])"
    This method takes a command and queues it for sending to the device.

AUTHOR
    Mark Hindess <[email protected]>

COPYRIGHT AND LICENSE
    This software is copyright (c) 2014 by Mark Hindess.

    This is free software; you can redistribute it and/or modify it under
    the same terms as the Perl 5 programming language system itself.

More Repositories

1

celtic-knot-scad

Celtic Knot Library for Openscad
OpenSCAD
23
star
2

xpl-perl

Perl modules for the xPL Home Automation Protocol
Perl
19
star
3

anyevent-mqtt-perl

Perl modules for MQTT protocol (http://mqtt.org/) using AnyEvent
Perl
13
star
4

net-mqtt-perl

Perl implementation of MQTT Protocol (http://mqtt.org)
Perl
11
star
5

net-pachube-perl

Perl Interface to Pachube
Perl
7
star
6

device-rfxcom-perl

Perl modules to make use of devices from RFXCOM (http://www.rfxcom.com/).
Perl
4
star
7

slic3r-http

Simple web interface for slic3r
Perl
3
star
8

anyevent-rfxcom-perl

Perl modules for using RFXCOM devices (http://www.rfxcom.com/) with AnyEvent.
Perl
3
star
9

camelnews

Perl port for lamernews that uses the same redis data structures
Perl
3
star
10

advent

Advent of Code
Rust
2
star
11

plack-app-mqtt-perl

Perl Plack Web Application to provide an AJAX to MQTT bridge
Perl
2
star
12

device-current-cost-perl

Perl modules to read from Current Cost devices (http://www.currentcost.com/)
Perl
2
star
13

things

Objects and shapes
1
star
14

sms-send-csoft-perl

SMS::Send driver to send SMS messages via the Connection Software (http://www.csoft.co.uk/) SMS service
Perl
1
star
15

qfwfq

Dummy Project For Testing
1
star
16

zenah-perl

Zen Automated Home - Rules engine for the xPL Home Automation Protocol
Perl
1
star
17

anyevent-mocktcpserver-perl

Perl modules for mock TCP server using AnyEvent
Perl
1
star
18

anyevent-datetime-perl

Perl modules for creating AnyEvent timers from DateTime Events
Perl
1
star
19

metric-cerberus

Metric derivative of the Cerberus 3D delta printer
OpenSCAD
1
star
20

dzil-base

Dist::Zilla template for my perl projects
1
star
21

sms-send-smsdiscount-perl

SMS::Send driver to send SMS messages via smsdiscount.com
Perl
1
star
22

m-bot-scad

D-Bot-style 3d printer with MGN rails
OpenSCAD
1
star
23

anyevent-ownet-perl

Perl modules for One-Wire FileSystem (http://www.owfs.org) client using AnyEvent.
Perl
1
star
24

anyevent-onkyo-perl

AnyEvent Perl module for controlling Onkyo/Integra AV equipment
Perl
1
star
25

anyevent-current-cost-perl

Perl modules to read from Current Cost devices (http://www.currentcost.com/) using AnyEvent
Perl
1
star