Skip to main content

Simple Python server to proxy commands to a JVC projector.

Project description

A tiny server that acts as a proxy between a client and a JVC projector such a projector. JVC projectors insist on an additional 3-way handshake (PJ_OK, PJREQ, PJACK) in addition to the normal TCP 3-way handshake. This means that certain home automation appliances may have timing difficulties communicating with the projector as they lack the protocol knowledge to implement the additional handshake.

See JVC Projector Control codes for the actual codes to effectively manage a JVC projector.

Using the server

Start the server, proxy between localhost and ‘my-projector’ on the usual JVC control port number (20554).

$ jvc_proxy -l DEBUG -r 2 -t 1 my-projector

Binds the server to an IP address / hostname that is accessible external to the machine (i.e. not localhost). Set logging level to DEBUG (will log the actual bytes proxied). Will retry failed connections to the projector twice. Allows 1 second timeout on network operations.

$ jvc_proxy --proxy_host my-pc -l DEBUG -r 2 -t 1 my-projector

Available arguments:

usage: [-h] [--jvc_port JVC_PORT] [--proxy_host PROXY_HOST]
                    [--proxy_port PROXY_PORT] [-t TIMEOUT] [-v VERBOSE]
                    [-l {ERROR,WARNING,INFO,DEBUG}] [-r RETRIES]
                    [-w RETRY_WAIT]

positional arguments:
  jvc_host              JVC host to proxy to. Default: 20554.

optional arguments:
  -h, --help            show this help message and exit
  --jvc_port JVC_PORT   JVC port number to connect to.
  --proxy_host PROXY_HOST
                        Proxy server host/IP to bind to. Default: localhost.
  --proxy_port PROXY_PORT
                        Proxy server port number to listen on. Default: 20554.
  -t TIMEOUT, --timeout TIMEOUT
                        Timeout for network operations (seconds). Default: 2.
  -v VERBOSE, --verbose VERBOSE
                        Whether or not to output proxied data. Default: False.
                        Logging level. Default: ERROR.
  -r RETRIES, --retries RETRIES
                        Number of retries to allow in connection to the JVC
                        host. Default: 0
  -w RETRY_WAIT, --retry_wait RETRY_WAIT
                        Seconds to wait between connection retries. Default:

Starting the server by default

Use the included jvc_proxy.service to start the server as a systemd unit.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for jvc-proxy, version 0.0.1
Filename, size File type Python version Upload date Hashes
Filename, size jvc_proxy-0.0.1-py2.py3-none-any.whl (7.0 kB) File type Wheel Python version py2.py3 Upload date Hashes View
Filename, size jvc_proxy-0.0.1.tar.gz (8.6 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page