About Transfer Data Client - Server GATT


Hi Everyone, I have two device nrf51822 and i want send data of button state from Client to Server GATT. Anyone did made it ? Can help me a tutorial or example ?


Hi kaitou26698,
You can look into the ticket for communication via BLE. In fact, you can pass the state of button to Server GATT using notification or indication.In Arduino, you can refer to BLE_HRM and BLE_CENTRAL


I did made BLE HRM and BLE CENTRAL, But it just work when i have 1 data, if we transfer 2 data it’s just connect but not transfer


I did transfer 2 data using ble.updateCharacteristicValue() with lightblue app to debug. So you can transfer data with this notification way.


I did, thanks lucian, have you use Facebook or Email ? Can i get that ?


I don’t have a Facebook account but email: [email protected]. If you have question you can post on the forum so that others can do a favor


Okay, ah more question, i’m making about BLE Scan Report, I try to get Package Advertise (Major, Minor) from Beacon Device and send this to other device connected, how can i get that, i see :
uint8_t len;
uint8_t adv_name[31];
if( NRF_SUCCESS == ble_advdata_decode(BLE_GAP_AD_TYPE_SHORT_LOCAL_NAME, params->advertisingDataLen, (uint8_t *)params->advertisingData, &len, adv_name) ) {
Serial.print(" The length of Short Local Name : “);
Serial.println(len, DEC);
Serial.print(” The Short Local Name is : ");
Serial.println((const char *)adv_name);
It’s get the Local Name but i don’t know " BLE_GAP_AD_TYPE_SHORT_LOCAL_NAME " is what function