This sample shows how to send serial signals to a device, using a Global Caché extender.
Click here for sample specific documentation
Global Caché ip address | |
Global Caché port | |
Serial module | ser1 ser2 |
To send serial commands to a Global Caché extender, by default you have to use ports 4999 (ser1) and 5000 (ser2).
If you have modified the port of the extender through its web interface, the serial port is available at <ir port> + 1 and <ir port> + 2.
When you use the gc class, this is taken care of for you, so you only have to specify the ir port.
This command allows to set the volume of a Bose Lifestyle up to 48, and V20 and V30 series
The Set Volume button reads the value of the first text box, sends it to the Bose system. The Get Volume button reads the current value from the Bose system.
The next samples show how to send an arbitrary serial command to the ser1 or ser2 port (see radio buttons above).
The response is printed below the button
In this case, the value from the input field must be converted, because otherwise the value is encoded incorrectly.