Our website is under construction. Please stay tuned!

dwm_pos_get

Obtains the actual position of the node.

void dwm_pos_get(dwm_pos_t *pos);
Parameters

C code example

dwm_pos_t pos;
dwm_pos_get(&pos);
printf(%ld \n, pos.x);
printf(%ld \n, pos.y);
printf(%ld \n, pos.z);
printf(%u \n, pos.qf);

SPI/UART example

TLV Request

Type

Length

0x02

0x00

Type 0x02 means command pos_get

TLV Response

Type

Length

Value (see error codes)

Type

Length

Value

0x40

0x01

0x00

0x41

0x0D

in t32_t -in l ittle e ndian is x co ordin ate in mil limet ers

in t32_t -in l ittle e ndian is y co ordin ate in mil limet ers

in t32_t -in l ittle e ndian is z co ordin ate in mil limet ers

ui nt8_t -pos ition qu ality f actor in pe rcent s (0 -100)

0x4b 0x0a 0x00 0x00 0x1f 0x04

0x00 0x00 0x9c 0x0e 0x00

0x00 0x64

Type 0x40 means err_code of previous command

Type 0x41 means position (x,y,z,pqf)