posts - 19 , comments - 8 , trackbacks - 0

Using a Raspberry Pi For Lanc

Setup

  1. Download the Raspian distribution

    I used the one dated 2015-02-16, kernel version 3.18.

  2. Prepare the distribution

    • $ sudo apt-get update
    • $ sudo apt-get upgrade
  3. Fixup the network interface

    I have an Edimax EW-7811Un which uses the Realtek 8192cu driver. This is configured for a client side connection, and the power saving mode disconnects it from the network after a period of inactivity. I want this to be a server side component so I disabled the power saving mode.

    Create a file "/etc/modprobe.d/8192cu.conf" and add the following:

    # Disable power management

    options 8192cu rtw_power_mgnt=0 rtw_enusbss=0

  4. Install node

    Download the package

    $ wget http://node-arm.herokuapp.com/node_latest_armhf.deb

    Install the package

    $ sudo dpkg -i node_latest_armhf.deb
    $ node -v
    v0.12.0

  5. Install node serial port

    $ sudo npm -g install serialport

Writing the code

  1. Create a folder for the project and add the serialport package.

    $ mkdir lanc-controller
    $ cd lanc-controller
    $ npm install serialport

LANC

The first byte

In the LANC standard the first byte sent usually identifies the device being spoken to. The first nibble is often the type of the device (eg. 1=VTR, 2=Camera), and the second nibble is a unique identifier for the device.

BinaryHexDescription
0001 10000x18Normal command to VTR or video camera
0010 10000x28Special command to video camera
0011 10000x38Special command to VTR
0001 11100x1ENormal command to still video camera

Print | posted on Sunday, March 29, 2015 4:06 PM |

Feedback

Gravatar

# re: Using a Raspberry Pi For Lanc

Hello,

I'm very interested in the proposed solution, but I feel that I don't have access to the entire article.
Is it possible to have the link to the full article?

Thnks a lot !
Emile
3/10/2017 4:04 PM | Cervia
Post A Comment
Title:
Name:
Email:
Comment:
Verification:
 

Powered by: