Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

Smart Bluetooth

Anonymous
Not applicable

Hello,

SDK:2.1.1

Hardware:Tag board + iPhone

I want to send variable data from client(iPhone) to the tag-board.

I have checked some samples and documents, and I found a description of setting "LEGATTDB_PERM_VARIABLE_LENGTH" in MMP920732SW-AN103-R application note, P12, table2.

Does any body know how to set this setting?

The samples just have the setting function CHARACTERISTIC_UUID128_WRITABLE () for write characteristic, and it need the length information like this.


CHARACTERISTIC_UUID128_WRITABLE (HDLC_VSP_VSP_TX,

  HDLC_VSP_VSP_TX_VALUE,

__UUID_VSP_VSP_TX,

LEGATTDB_CHAR_PROP_WRITE_NO_RESPONSE,

LEGATTDB_PERM_WRITE_CMD,

16), ect...

It sets the data length, so the length is always 16 or something even iPhone sent other length data.

I want to like this,

When I sent data

0x00 0x00

then I want to get two byte of 0x00.

When I sent

0x00 0x00 0x00

then I want to get three byte of 0x00.

I changed the setting LEGATTDB_PERM_WRITE_CMD to LEGATTDB_PERM_VARIABLE_LENGTH.


I want to get 16byte data paket, so I can not add a length data in the data.

0 Likes
1 Solution
MichaelF_56
Moderator
Moderator 250 sign-ins 25 comments on blog 10 comments on blog
Moderator

I believe you already asked a similar question here: Characteristic of variable-length write

We have a meeting with the developers this week and will discuss, then respond to the original thread.

View solution in original post

0 Likes
1 Reply