Displaycontrol

Package to control displays and projectors via serial and ethernet connection.


License
CC-BY-NC-SA-2.5
Install
pip install Displaycontrol==0.0.3.dev1

Documentation

Displaycontrol

python package to control projectors and displays via serial or ethernet connection.

short track

The package could be used to control displays and projectors by all supported vendors either via serial connection or ethernet.

Connections

As of now, the package only allows communication via serial interface but since the package is refactored from an already existing internal package with working ethernet connection, this will be added shortly.

Vendors

Currently supported:

  • BenQ (especially the LU9235 projector)
  • Philips professional displays (respecting the weird change in the SICP platform history)
  • Samsung signage displays (only basic stuff)

Installation

Simply install via pip install Displaycontrol

Example

Basic usage

The package is designed around connections and control classes. To communicate to a projector or display, you have to new up a control class like so:

# import all available vendors
from displaycontrol.vendors import * 

# Create instance of the BenQ LU9235 controller class with default settings
control = BenQLU9235()

# Print the current input channel as human readable string
print control.get_input_channel_hr() 

Custom connection settings

Since the controller is created without a connection, it uses the default SerialConnection on COM1 with 9600 baud / 8N1. You could override this like so:

# import all available vendors
from displaycontrol.vendors import *

# Create a connection with custom values
connection = SerialConnection()
connection.port = '/dev/tty.usbserial' # yeah, we are on a mac
connection.baudrate = 38400 
 
# Create instance of the BenQ LU9235 controller class with overriden custom settings
control = BenQLU9235(connection)

# Print the current input channel as human readable string
print control.get_input_channel_hr() 

Commands

The base class for all vendors is the DisplayGeneric class. All dictionaries as well as commands are defined there so that you could easily use the same codeset for all display and only change the connector class (maybe in a config file that is unique for every pc in your rollout). Whenever a vendor controller class does not implement a certain command, a CommandNotImplementedError exception will be raised.

from displaycontrol.vendors import *
control = BenQLU9235()

# This will work, since the benq control class implements getting the current input channel
current_input = control.get_input_channel_hr()

# This will throw a CommandNotImplementedError exception, since the BenQ interface does not provide a way to get the serial number
projectors_serial = control.get_serialnumber() 
 

Roadmap

  • Version 0.0.5 - Finalize BenQ, Philips and Samsung packages.
  • Version 0.1.0 - Migrate existing Ethernet connection into this project.