- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
===
SDK: 2.1.
Tag: 920737.
app: hello-sensor.
===
Problem:
When enable hello_sensor_cfg's
encr_required = SECURITY_ENABLED | SECURITY_REQUEST
--> when phone button disconnection, device can not get plan_air_connection_down() from lower-layer
so the re-connection can not be successful.
but if
encr_required = 0
--> The disconnection from phone is ok and we can re-connect with device again.
it seems to be related with codes below,
if (bleprofile_p_cfg->encr_required != 0)
{
if (emconninfo_deviceBonded())
{
ble_trace0("device bonded");
}
else
{
ble_trace0("device not bonded");
lesmp_pinfo->pairingParam.AuthReq |= LESMP_AUTH_FLAG_BONDING;
lesmp_sendSecurityRequest();
}
return;
}
so any other places go wrong??
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi, J.T,
I re-tried the SDK 2.2 and the can not scan problem is ok now.
But for the security mechanism, still not workable in some android phone as described before.
Now we use another approach to do our SW requirement. It's ok now.
Thx.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Did you always do a security request when you do a connection? Try doing this and see if it helps.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi, boont,
I use SDK2.1.1 version with default HelloSensor codes with security enabled, which means,
from every central connection attempt, slave will call the lesmp_sendSecurityRequest()
so it should be fine but after phone (with installed BLE APK) button disconnection, I can see
there is no dis-link message from lower-layer to app layer of device. So device is still in connection state.
This is why user can not make a connection again and in user site, phone displays dis-connected already.
Can u reproduce it?
if (bleprofile_p_cfg->encr_required != 0)
{
if (emconninfo_deviceBonded())
{
ble_trace0("device bonded");
}
else
{
ble_trace0("device not bonded");
lesmp_pinfo->pairingParam.AuthReq |= LESMP_AUTH_FLAG_BONDING;
lesmp_sendSecurityRequest();
}
return;
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
i am using a s4 installed with wiced smart explorer to talk to my hello sensor. i can always connect back to the sensor after a power reboot to the phone's bluetooth. how do you do a disconnect from your phone?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
power- reboot of Bluetooth?
Hi boont,
I use a S3 and install free web apk of BLE4.0 scanner and
when phone button with disconnection (if device firmware enables with security)
and then phone button with connection again WITHOUT re-power the bluetooth.
The connection is failed always. It seems dont need to re-power the bluetooth,
only disconnect and then re-scan it but in my case, when phone rescan BLE device,
it can not find this device.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Leo Su,
Have you tried SDK 2.2.
Thanks
JT
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi, J.T,
I re-tried the SDK 2.2 and the can not scan problem is ok now.
But for the security mechanism, still not workable in some android phone as described before.
Now we use another approach to do our SW requirement. It's ok now.
Thx.