Searches for a specified byte sequence in the RXD (receiver) buffer.
The RXD buffer size is 128 bytes.
The function uses the RXD buffer
Function Menu | Block Diagram |
---|---|
![]() |
![]() |
Name | Type | Description |
---|---|---|
index |
int32 |
Position in the RXD buffer from which the search begins. The first buffer element has an index of 0. |
Name | Type | Description |
---|---|---|
result |
int32 |
Search result: ≥0 — Data found, index of the buffer element immediately following the found sequence. -1 — Data not found. |
Name | Description |
---|---|
Data | The sequence to search for in the RXD buffer. Specified in HEX or ASCII (text). The following is an example of the same data recorded in HEX and ASCII: HEX: 3120322033 ASCII: 1 2 3 |
If RXD = [01,02,03,04,05,06...]
, index = 0, data = 0203
, then result = 3
If RXD = [01,02,03,04,05,06...]
, index = 2, data = 0203
, then result = -1
If RXD = [01,02,03,04,05,06...]
, index = 0, data = 3322
, then result = -1