This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Last revision Both sides next revision | ||
wiki:v2:protocol_reference [2018/10/10 17:32] pixycam |
wiki:v2:protocol_reference [2019/01/19 18:18] pixycam |
||
---|---|---|---|
Line 56: | Line 56: | ||
|3 |Length of payload |7 | | |3 |Length of payload |7 | | ||
|4 - 5 |16-bit checksum | sum of payload bytes | | |4 - 5 |16-bit checksum | sum of payload bytes | | ||
- | |6 - 7 |Hardware version | (varies) | | + | |6 - 7 |16-bit hardware version | (varies) | |
|8 |Firmware version (major) | (varies) | | |8 |Firmware version (major) | (varies) | | ||
|9 |Firmware version (minor) | (varies) | | |9 |Firmware version (minor) | (varies) | | ||
- | |10 - 11 |Firmware build | (varies) | | + | |10 - 11 | 16-bit firmware build | (varies) | |
|12 |Firmware type (human readable string) | (varies) | | |12 |Firmware type (human readable string) | (varies) | | ||
Line 79: | Line 79: | ||
|3 |Length of payload |2 | | |3 |Length of payload |2 | | ||
|4 - 5 |16-bit checksum | sum of payload bytes | | |4 - 5 |16-bit checksum | sum of payload bytes | | ||
- | |6 - 7 |Frame width | 0 - 511 | | + | |6 - 7 |16-bit frame width | 0 - 511 | |
- | |8 - 9 |Frame height | 0 - 511 | | + | |8 - 9 |16-bit frame height | 0 - 511 | |
==== setCameraBrightness(brightness) ==== | ==== setCameraBrightness(brightness) ==== | ||
Line 94: | Line 94: | ||
^Byte ^Description ^Value(s) ^ | ^Byte ^Description ^Value(s) ^ | ||
|0 - 1 |16-bit sync| 175, 193 (0xc1af)| | |0 - 1 |16-bit sync| 175, 193 (0xc1af)| | ||
- | |2 |Type of packet |17 | | + | |2 |Type of packet |1 | |
|3 |Length of payload |4 | | |3 |Length of payload |4 | | ||
|4 - 5 |16-bit checksum | sum of payload bytes | | |4 - 5 |16-bit checksum | sum of payload bytes | | ||
- | |6 - 9 |Result |0 (???) | | + | |6 - 9 |32-bit result |result value | |
==== setServos(s0, s1) ==== | ==== setServos(s0, s1) ==== | ||
Line 105: | Line 105: | ||
|2 |Type of packet |18 | | |2 |Type of packet |18 | | ||
|3 |Length of payload |4 | | |3 |Length of payload |4 | | ||
- | |4 - 5 |s0 - pan servo value |0 - 511 | | + | |4 - 5 |16-bit s0 - pan servo value |0 - 511 | |
- | |6 - 7 |s1 - tilt servo value |0 - 511 | | + | |6 - 7 |16-bit s1 - tilt servo value |0 - 511 | |
=== Response: === | === Response: === | ||
Line 112: | Line 112: | ||
^Byte ^Description ^Value(s) ^ | ^Byte ^Description ^Value(s) ^ | ||
|0 - 1 |16-bit sync | 175, 193 (0xc1af)| | |0 - 1 |16-bit sync | 175, 193 (0xc1af)| | ||
- | |2 |Type of packet |19 | | + | |2 |Type of packet |1 | |
|3 |Length of payload |4 | | |3 |Length of payload |4 | | ||
|4 - 5 |16-bit checksum | sum of payload bytes | | |4 - 5 |16-bit checksum | sum of payload bytes | | ||
- | |6 - 9 |Result |0 (???) | | + | |6 - 9 |32-bit result/acknowledge |result value | |
==== setLED(r, g, b) ==== | ==== setLED(r, g, b) ==== | ||
Line 131: | Line 131: | ||
^Byte ^Description ^Value(s) ^ | ^Byte ^Description ^Value(s) ^ | ||
|0 - 1 |16-bit sync | 175, 193 (0xc1af)| | |0 - 1 |16-bit sync | 175, 193 (0xc1af)| | ||
- | |2 |Type of packet |21 | | + | |2 |Type of packet |1 | |
|3 |Length of payload |4 | | |3 |Length of payload |4 | | ||
|4 - 5 |16-bit checksum | sum of payload bytes | | |4 - 5 |16-bit checksum | sum of payload bytes | | ||
- | |6 - 9 |Result |0 (???) | | + | |6 - 9 |32-bit result/acknowledge | result value | |
==== setLamp(upper, lower) ==== | ==== setLamp(upper, lower) ==== | ||
Line 149: | Line 149: | ||
^Byte ^Description ^Value(s) ^ | ^Byte ^Description ^Value(s) ^ | ||
|0 - 1 |16-bit sync | 175, 193 (0xc1af)| | |0 - 1 |16-bit sync | 175, 193 (0xc1af)| | ||
- | |2 |Type of packet |23 | | + | |2 |Type of packet |1 | |
|3 |Length of payload |4 | | |3 |Length of payload |4 | | ||
|4 - 5 |16-bit checksum | sum of payload bytes | | |4 - 5 |16-bit checksum | sum of payload bytes | | ||
- | |6 - 9 |Result |0 (???) | | + | |6 - 9 |32-bit result/acknowledge | result value | |
==== getFPS() ==== | ==== getFPS() ==== | ||
Line 166: | Line 166: | ||
^Byte ^Description ^Value(s) ^ | ^Byte ^Description ^Value(s) ^ | ||
|0 - 1 |16-bit sync | 175, 193 (0xc1af)| | |0 - 1 |16-bit sync | 175, 193 (0xc1af)| | ||
- | |2 |Type of packet |25 | | + | |2 |Type of packet |1 | |
|3 |Length of payload |4 | | |3 |Length of payload |4 | | ||
|4 - 5 |16-bit checksum | sum of payload bytes | | |4 - 5 |16-bit checksum | sum of payload bytes | | ||
- | |6 - 9 |Result |0 (???) | | + | |6 - 9 |32-bit result | frames-per-second | |
{{page>wiki:v2:ccc-packets&noindent}} | {{page>wiki:v2:ccc-packets&noindent}} | ||
{{page>wiki:v2:line-packets&noindent}} | {{page>wiki:v2:line-packets&noindent}} | ||
{{page>wiki:v2:video-packets&noindent}} | {{page>wiki:v2:video-packets&noindent}} |