CVP streaming from analog device

Here we provide to you a solution for encoding analog input from a sound card to G.711 u-law format that can be delivered to the Helix server for further broadcast to a CVP solution. This encoder utility is not a CVP supported utility.

Providing G.711 u-law format audio streaming from Helix that had originated with input from an analog device:
The below attached AVTransmit3.java file is the code in which made this possible.  The attached Stream.jar is the complied executable of this java code.
Along with this code, Java executables and JMF (Java Media Framework) is required to be installed on the executing machine.

Please download the JMF here:
http://java.sun.com/javase/technologies/desktop/media/jmf/2.1.1/download.html 

This java code will take analog input from the sound card of a server, convert it to G.711 u-law and then broadcast it to an open port on
the Helix server.  Helix can then forward that encoded RTP on to its clients.

The block diagram of our test setup is as follows:

    CD Player -> analog audio cable into Sound card -> Stream.jar Encoder -> Helix Server -> RTP broadcast stream to Client

Due to the fact that the MCS7845 we have a Helix server running on does not have a sound card, we ran the
encoder on a sperate machine.  This encoded stream was then forwarded for Helix for broadcast.
In our example, the encoder ran on the device 161.44.81.63 and Helix ran on 10.86.129.250.

If modifications to the java code are required, please refer to the attached JMF user guide.

Enabling Helix to allow the encoder to connect to it:
Placing an SDP file in the C:\Program Files\Real\Helix Server\Content\rtpencodersdp
of Helix will open a port on Helix to allow an encoder to attach to it. 
This directory is the install directory of Helix, plus Content, plus the location of the Base Mount Point as
defined in the QT & RTP Encoding page of the Helix Administration GUI.
The default value is "\rtpencodersdp\"

The contents of the SDP file will be setup like so:

v=0
o=- <unique value> <unique session ID> IN IP4 <IP-address-of-encoder>
s=JMF
t=0 0
m=audio <Helix-listening-port> RTP/AVP 0
c=IN IP4 <IP-address-of-Helix>
a=MaxPacketSize:integer;160

In our example, these values are:

v=0
o=- 37 614155991 IN IP4 161.44.81.63
s=JMF
t=0 0
m=audio 17008 RTP/AVP 0
c=IN IP4 10.86.129.250
a=MaxPacketSize:integer;160

When creating multiple streams, you must create multiple SDP files each with its own unique session IDs and listening
port values.
For further information about the contents of SDP files, please see the RFC2327.
http://www.ietf.org/rfc/rfc2327.txt 

Running encoder executable:
Attach a device to the analog input of the sound card on a server.  At the command line
of this server in the directory where the Stream.jar is placed, run this command:

    java -jar .\Stream.jar <input-device> <ip-of-Helix> <port-of-Helix>

In our example, the parameters are

    java -jar .\Stream.jar javasound://44100 10.86.129.250 17008

This will run continuously until the program is stopped with a control-C.

ICM script changes:
The address in which clients will connect to hear the broadcast stream will be

    rtsp://<Helix-ip-address>/rtpencoder/<sdp-filename>

Note that the actual SDP file is not served to client, but rather used by Helix to know to forward the stream provided by the encoder.
In our example, the parameters are

    rtsp://10.86.129.250/rtpencoder/jmf.sdp

The path name "rtpencoder" is the value of the Mount Point as defined on the QT & RTP Encoding page of the Helix Adminstration GUI.
The default value is "\rtpencoder\".

The values of parameters within the ICM script that refer to the name of the file being accessed must be changed to now point at the SDP filename on Helix.

0 Attachments
3534 Views
Average (0 Votes)
The average rating is 0.0 stars out of 5.
Comments