port crypto buildable with our code base

This commit is contained in:
hathach committed 2018-01-09 17:24:25 +07:00
1 parent a721478f1e
commit b152e84a2f
5 files changed
+36 -15

No files matched your search

@@ -181,7 +181,20 @@ static HAPResponse_t* pairing_setup_write_cb (HAPCharacteristic& chr, ble_gatts_
break;
case PAIRING_TYPE_STATE:
LOG_LV2("HAP", "State = M%d", *((uint8_t const*)ktlv.value));
{
uint8_t state = *((uint8_t const*)ktlv.value);
LOG_LV2("HAP", "State = M%d", state);
switch (state)
{
case 1: // M1
// if paired return PAIRING_ERROR_UNAVAILABLE
// tries more than 100 time return PAIRING_ERROR_MAX_TRIES
// pairing with other iOS return PAIRING_ERROR_BUSY
break;
}
}
break;
// ignore other type