<< to CrossControl homepage

Support & Service Center

Sending SubscribeROIVideo through the terminal

Printer-friendly versionPrinter-friendly versionPDF versionPDF version

Note, the following is only valid for i.MX6-based displays

For ETH cameras following the ISO17215 standard you will sometimes need to send a message to the camera for it to start sending video. The message is called SubscribeROIVideo and it takes an index as a parameter. The index is what Region of Interest the camera will stream.

This is the contents of the message:

Byte 00-01 	SOME/IP header
Byte 02-03 	Method (Subscribe ROI video)
Byte 04-07 	Length of message (only header, method och length fields)
Byte 08-09 	ClientID
Byte 10-11 	Packet nbr (if you send more than one packet in the same message, you mus increase the ID so the camera knows in which order to handle it) 
Byte 12-14 	Should always be \x01\x01\x00
Byte 15-18 	Resolution index you want from the camera

One option is to use the ETHCameraSettings library to send messages with a simple interface.
See the following KB article on how to use the ETH Camera library: Using the ETH Camera settings library

The other way is to use the echo command and add that to a script.

The command we will be using is:
echo -n -e '\x43\x3f\x01\x31\x00\x00\x00\x0c\x12\x34\x56\x78\x01\x01\x00\x00\x00\x00\x00\<Index as byte>'>/dev/udp/<Camera IP>/<SOME/IP communication port>
For example to subscribe to ROI 6, on a camera with IP 192.168.40.90 and SOME/IP port 17215:
echo -n -e '\x43\x3f\x01\x31\x00\x00\x00\x0c\x12\x34\x56\x78\x01\x01\x00\x00\x00\x00\x00\x06'>/dev/udp/192.168.40.90/17215

For information on what ROI's are available on your camera and its communication port, check with your camera supplier.

Environment and Versions: 
VS, VI
whatever