API / Commands / Query Layer Property
Query Layer Property
Query Layer Property
Overview
Read parameters of designated layer
Device Supported
Q Series: Q16pro Gen 2 X Series: X2, X3, X7, X8, X14
Command Structure
- Query layer property
| Element | Attribute | Detail |
|---|---|---|
| HEAD | < | |
| TYPE | T | |
| ADDR | 0x00 | default |
| SEQN | 0x00 | default |
| CMMD | 0xF3 | Query |
| DAT1 | 0x00 | default |
| DAT2 | 0x00~0x9F | layer 1~160 |
| DAT3 | 0x00 | Unused |
| DAT4 | 0x00 | Unused |
| CHKS | Check sum=ADDR+SEQN+CMD+DAT1+DAT2+DAT3+DAT4 | |
| END | > |
- Response
| Element | Attribute | Detail |
|---|---|---|
| DATA BLOCK | [ | the string stats with "[" |
| crop_posx | layer cropping value: X horizontal position | |
| crop_posy | layer cropping value: Y Vertical position | |
| crop_width | layer cropping value: width | |
| crop_height | layer cropping value: Height | |
| scale_posx | layer scale value: X horizontal position | |
| scale_posy | layer scale value: Y Vertical position | |
| scale_width | layer scale value: width | |
| scale_height | layer scale value: height | |
| input | Signal source 0~79 (eg. 0 = input 1, 1 = input 2, 79 = input 80 | |
| alpha | Layer alpha value, 0-128 | |
| pos | layer order, top layer is 0 | |
| lock | layer lock value | |
| group | layer group value | |
| container | the screen group of the layer | |
| ] | the string ends with "]" |
Example Transmit
- read properties of layer 2
| Command | HEAD | TYPE | ADDR | SEQN | CMMD | DAT1 | DAT2 | DAT3 | DAT4 | CHKS | END |
|---|---|---|---|---|---|---|---|---|---|---|---|
| ASCII | < | T | 00 | 00 | F3 | 00 | 01 | 00 | 00 | F4 | > |
| HEX | 3C | 54 | 30 30 | 30 30 | 46 33 | 30 30 | 30 31 | 30 30 | 30 30 | 46 34 | 3E |
Command Sample
<T0000F300010000F4> //read layer 2 properties
<F0000F300010000F4>[crop_posx=0, crop_posy=0, crop_width=1920, crop_height=1080, scale_posx=0, scale_posy=0, scalewidth=1920, scaleheight=1080,input=0, alpha=128, pos=1, lock=0, Group=0, container=0] //response: all parameters of layer 2