This is the description of the TCP/IP protocol for the Tilt Bricklet. General information and technical specifications for the Tilt Bricklet are summarized in its hardware description.
A general description of the TCP/IP protocol structure can be found here.
BrickletTilt.
get_tilt_state
¶Function ID: |
|
---|---|
Request: |
|
Response: |
|
Returns the current tilt state. The state can either be
The following meanings are defined for the elements of this function:
For state:
BrickletTilt.
get_identity
¶Function ID: |
|
---|---|
Request: |
|
Response: |
|
Returns the UID, the UID where the Bricklet is connected to, the position, the hardware and firmware version as well as the device identifier.
The position can be 'a', 'b', 'c', 'd', 'e', 'f', 'g' or 'h' (Bricklet Port). A Bricklet connected to an Isolator Bricklet is always at position 'z'.
The device identifier numbers can be found here.
BrickletTilt.
enable_tilt_state_callback
¶Function ID: |
|
---|---|
Request: |
|
Response: |
|
Enables the CALLBACK_TILT_STATE
callback.
BrickletTilt.
disable_tilt_state_callback
¶Function ID: |
|
---|---|
Request: |
|
Response: |
|
Disables the CALLBACK_TILT_STATE
callback.
BrickletTilt.
is_tilt_state_callback_enabled
¶Function ID: |
|
---|---|
Request: |
|
Response: |
|
Returns true if the CALLBACK_TILT_STATE
callback is enabled.
BrickletTilt.
CALLBACK_TILT_STATE
¶Function ID: |
|
---|---|
Response: |
|
This callback provides the current tilt state. It is called every time the state changes.
See get_tilt_state
for a description of the states.
The following meanings are defined for the elements of this function:
For state: