Coder Social home page Coder Social logo

amazon-freertos-ble-android-sdk's Introduction

image DEPRECATED

Announcement:

As of July 31st, 2023, this repository is deprecated. The contents of this repository will remain available but we will no longer provide updates nor accept new contributions and pull requests. We recommend instead that you start here for creating interactions between an Android device and AWS. For Bluetooth Low Energy APIs we recommend you start here.

Since the initial release of this package, several new Android versions have been released bringing with them enhanced security and usability. AWS Amplify has also released dozens of later versions of the AWS SDK with many new features and bug fixes.

The amazon-freertos-ble-android-sdk is being deprecated to remove an example built on outdated code.

Have more questions? Post them in the FreeRTOS forum.

FreeRTOS BLE Mobile SDK for Android

Maven Central

Introduction

Using the Android SDK for FreeRTOS Bluetooth Devices, you can create mobile applications that do the following:

  • Scan for and connect to nearby BLE devices running FreeRTOS

  • Perform WiFi provisioning of the FreeRTOS BLE devices after connecting to them ( Only supported for Espressif ESP32-DevKitC )

  • Act as a proxy for transmitting MQTT messages between a device running FreeRTOS and the AWS IoT cloud

System requirements

  • Android 6.0 (API level 23) or higher

  • Bluetooth 4.2 or higher

  • Android Studio

Setting Up the SDK

  1. Set the SDK as a dependency for the application.

Option 1: install from maven In your app's build.gradle file, add the following into dependencies block: (replace x.y.z with Maven Central)

    implementation('software.amazon.freertos:amazonfreertossdk:x.y.z')

Option 2: Build the sdk locally. In your app's build.gradle file, add the following into dependencies block:

    implementation project(':amazonfreertossdk')

In project's settings.gradle file, add ':amazonfreertossdk'

    include ':app', ':amazonfreertossdk'
  1. In your app's AndroidManifest.xml file, add following permissions:
<uses-permission android:name="android.permission.BLUETOOTH"/>
    <!-- initiate device discovery and manipulate bluetooth settings -->
<uses-permission android:name="android.permission.BLUETOOTH_ADMIN"/>
    <!-- allow scan BLE -->
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />

    <!-- AWS Mobile SDK -->
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
  1. Turn on phone's Location Services.

In addition to adding location permissions, this is required by android to perform a successful BLE scan.

Contents

BLE Helper Functions

The SDK includes some functions that help you perform BLE operations with FreeRTOS devices:

    startScanDevices
    stopScanDevices
    connectToDevice
    disconnectFromDevice

Once the connection to the device is established, you get an AmazonFreeRTOSDevice object, and you can use this object to do WiFi provisioning or Mqtt proxy.

WiFi Provisioning Service

Provision the WiFi credential on the FreeRTOS device through the app. It provides 4 functions:

    ListNetwork
    SaveNetwork
    EditNetwork
    DeleteNetwork

MQTT Proxy Service

The MQTT proxy service controls the MQTT proxy. It allows the device to send and receive MQTT messages from the AWS IoT cloud through the phone, when this feature is enabled.

You can find the API documentation for these functions in the docs directory of this repository and on github pages.

Demo Application

The SDK includes a demo application that demonstrates some of the main features of the SDK. You can find the demo in app.

License

This library is licensed under the Apache 2.0 License.

amazon-freertos-ble-android-sdk's People

Contributors

aggarw13 avatar alexa-noxon avatar bxpan avatar dachalco avatar dgranahan avatar ignasbol avatar jpeddicord avatar kstribrnamzn avatar massi-ang avatar paulbartell avatar ravibhagavandas avatar romaindequidt avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

amazon-freertos-ble-android-sdk's Issues

Older Android versions don't work with BLE Provisioning, Demo & Firmware

Describe the bug
We have tried to use the demo app and the AFR 1.4.7 and 1.5 BLE provisioning demos unsuccessfully with older phones such as Android 6.0 (used by a vast majority of Android users). We are not able to connect to the device via BLE. It seems that we get kicked out of the connection immediately, and we are not able to discover any services. On the device side, we are using an ESP32.

Build info
What is the branch and commit on the device side? previous suggested commit from the ble-beta, 17ba347f for AFR 1.4.7, and I believe 5a201aca for AFR 1.5
What is the branch and tag the SDK side? latest commit from the /beta branch tag v0.9.4
Does pulling the latest code help resolve the issue? No

To Reproduce
What is the frequency of this issue? Every time we try to establish a BLE connection
Steps to reproduce the behavior: Load the app on an older Android phone (we tried with a 6.0) and try to connect to a device

Log
Could you provide log on both the device side and SDK side?
DEVICE (ESP32) LOG:

2079 6157097 [Btc_task] [INFO ][DEMO][61570970] BLE Connected to remote device, connId = 0

E (61572781) BT_SMP: pairing failed - slave requires auth is 0xd but peer auth is 0x5 local auth is 0xd

W (61572791) BT_L2CAP: L2CA_EnableUpdateBleConnParams - unknown BD_ADDR 000000000000

W (61572871) BT_BTM: btm_sec_clr_temp_auth_service() - no dev CB

E (61572871) BT_BTM: Device not found

W (61572871) BT_APPL: BTA got unregistered event id 31

W (61572881) BT_APPL: BTA got unregistered event id 31

2080 6157285 [Btc_task] [INFO ][DEMO][61572850] BLE disconnected with remote device, connId = 0

MOBILE APP DEMO LOG:

05-31 10:00:11.491 19583-19583/software.amazon.freertos.demo D/AmazonFreeRTOSManager: Found ble device: 24:0A:C4:1D:78:AE RSSI: -59

05-31 10:00:13.681 19583-19583/software.amazon.freertos.demo D/ViewRootImpl: ViewPostImeInputStage processPointer 0

05-31 10:00:13.811 19583-19583/software.amazon.freertos.demo D/ViewRootImpl: ViewPostImeInputStage processPointer 1

05-31 10:00:13.811 19583-19583/software.amazon.freertos.demo I/DeviceScanFragment: connect switch isChecked: ON

05-31 10:00:13.821 19583-19583/software.amazon.freertos.demo I/art: Rejecting re-init on previously-failed class java.lang.Class<com.amazonaws.mobile.client.AWSMobileClient$10>

05-31 10:00:13.821 19583-19583/software.amazon.freertos.demo I/art: Rejecting re-init on previously-failed class java.lang.Class<com.amazonaws.mobile.client.AWSMobileClient$10>

05-31 10:00:13.831 19583-19583/software.amazon.freertos.demo I/art: Rejecting re-init on previously-failed class java.lang.Class<com.amazonaws.mobile.client.AWSMobileClient$3>

05-31 10:00:13.831 19583-19583/software.amazon.freertos.demo I/art: Rejecting re-init on previously-failed class java.lang.Class<com.amazonaws.mobile.client.AWSMobileClient$3>

05-31 10:00:13.921 19583-19583/software.amazon.freertos.demo D/BluetoothGatt: connect() - device: 24:0A:C4:1D:78:AE, auto: true

05-31 10:00:13.921 19583-19583/software.amazon.freertos.demo D/BluetoothGatt: registerApp()

05-31 10:00:13.921 19583-19583/software.amazon.freertos.demo D/BluetoothGatt: registerApp() - UUID=001c5cff-940f-400d-b060-6f1ae591bb27

05-31 10:00:13.961 19583-19598/software.amazon.freertos.demo D/BluetoothGatt: onClientRegistered() - status=0 clientIf=10

05-31 10:00:13.991 19583-19595/software.amazon.freertos.demo D/BluetoothGatt: onAutoConnectionStatusCb()status =0

05-31 10:00:15.121 19583-19695/software.amazon.freertos.demo I/AmazonFreeRTOSManager: Stopping ble device scan

05-31 10:00:15.121 19583-19695/software.amazon.freertos.demo D/BluetoothAdapter: STATE_ON

05-31 10:00:15.121 19583-19695/software.amazon.freertos.demo D/BluetoothAdapter: STATE_ON

05-31 10:00:15.121 19583-19695/software.amazon.freertos.demo D/BluetoothLeScanner: Stop Scan

05-31 10:00:17.671 19583-19595/software.amazon.freertos.demo D/BluetoothGatt: onClientConnectionState() - status=0 clientIf=10 device=24:0A:C4:1D:78:AE

05-31 10:00:17.681 19583-19595/software.amazon.freertos.demo I/FRD: BLE connection state changed: 0; new state: BLE_CONNECTED

05-31 10:00:17.711 19583-19595/software.amazon.freertos.demo I/FRD: Connected to GATT server.

05-31 10:00:17.721 19583-19595/software.amazon.freertos.demo D/FRD: Processing BLE command: DISCOVER_SERVICES remaining mqtt queue 0, network queue 0

05-31 10:00:17.721 19583-19595/software.amazon.freertos.demo D/BluetoothGatt: discoverServices() - device: 24:0A:C4:1D:78:AE

05-31 10:00:17.741 19583-19595/software.amazon.freertos.demo D/BluetoothGatt: onClientConnParamsChanged() - Device=24:0A:C4:1D:78:AE interval=6 status=0

05-31 10:00:17.741 19583-19595/software.amazon.freertos.demo D/BluetoothGatt: onClientConnParamsChanged() - Device=24:0A:C4:1D:78:AE interval=39 status=0

05-31 10:00:17.791 19583-19583/software.amazon.freertos.demo D/FRD: Bond state changed from 10 to 11

05-31 10:00:17.791 19583-19598/software.amazon.freertos.demo D/BluetoothGatt: onSearchComplete() = Device=24:0A:C4:1D:78:AE Status=0

05-31 10:00:17.791 19583-19598/software.amazon.freertos.demo I/FRD: Discovered Ble gatt services successfully. Bonding state: 11

05-31 10:00:17.791 19583-19598/software.amazon.freertos.demo D/FRD: GattService: 00001801-0000-1000-8000-00805f9b34fb

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: 00002a05-0000-1000-8000-00805f9b34fb

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD: GattService: 00001800-0000-1000-8000-00805f9b34fb

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: 00002a00-0000-1000-8000-00805f9b34fb

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: 00002a01-0000-1000-8000-00805f9b34fb

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: 00002aa6-0000-1000-8000-00805f9b34fb

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD: GattService: 8a7f1168-48af-4efb-83b5-e679f932ff00

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: DEVICE_VERSION

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: IOT_ENDPOINT

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: DEVICE_MTU

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD: GattService: 3113a187-4b9f-4f9a-aa83-c614e11bff00

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: 3113a187-4b9f-4f9a-aa83-c614e11bff01

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: 3113a187-4b9f-4f9a-aa83-c614e11bff02

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: 3113a187-4b9f-4f9a-aa83-c614e11bff03

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: 3113a187-4b9f-4f9a-aa83-c614e11bff04

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD: GattService: a9d7166a-d72e-40a9-a002-48044cc3ff00

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: a9d7166a-d72e-40a9-a002-48044cc3ff01

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: a9d7166a-d72e-40a9-a002-48044cc3ff02

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: a9d7166a-d72e-40a9-a002-48044cc3ff03

05-31 10:00:17.801 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: a9d7166a-d72e-40a9-a002-48044cc3ff04

05-31 10:00:17.811 19583-19598/software.amazon.freertos.demo D/FRD:  |-characteristics: a9d7166a-d72e-40a9-a002-48044cc3ff05

05-31 10:00:17.811 19583-19598/software.amazon.freertos.demo D/FRD: There's no ble command in the queue.

05-31 10:00:18.161 19583-19594/software.amazon.freertos.demo D/BluetoothGatt: onClientConnectionState() - status=19 clientIf=10 device=24:0A:C4:1D:78:AE

05-31 10:00:18.171 19583-19594/software.amazon.freertos.demo I/FRD: BLE connection state changed: 19; new state: BLE_DISCONNECTED

05-31 10:00:18.171 19583-19594/software.amazon.freertos.demo I/FRD: Disconnected from GATT server.

05-31 10:00:18.171 19583-19583/software.amazon.freertos.demo D/FRD: Bond state changed from 11 to 10

05-31 10:00:18.171 19583-19594/software.amazon.freertos.demo I/DeviceScanFragment: BLE connection status changed to: BLE_DISCONNECTED

05-31 10:00:18.171 19583-19583/software.amazon.freertos.demo I/DeviceScanFragment: connect switch isChecked: OFF

Additional context
N/A

Getting issue with release v1.1.0

I am trying to build the release v1.1.0 , amazonfreertossdk project code but getting some gradle issue and when i tried to build the app project, code getting build successfully but when i run the application in the android phone, i am getting some issue. After running the mobile application, blank screen appeared and after that app got crashed.

My objective is to test the OTA Demo application with nordic nrf52840 OTA firmware.

Device Info:
Xiaomi Redmi Note 7 Pro
Android 9.0

BLE connection is not possible with nrf52840 Device

Hello.

I am trying to do MQTT communication with AWS with nRF52840 Device.
https://docs.aws.amazon.com/freertos/latest/userguide/getting_started_nordic.html
I am doing this while looking at the guide of this link.
However, it seems that the Android SDK Demo App and BLE are not connected.

Debug Log on Android SDK App is as follows. :

I/DeviceScanFragment: connect switch isChecked: ON
D/BluetoothAdapter: STATE_ON
D/BluetoothGatt: connect() - device: C3:CF:94:B6:44:6E, auto: true
D/BluetoothAdapter: isSecureModeEnabled
D/BluetoothGatt: registerApp()
D/BluetoothGatt: registerApp() - UUID=334c5136-bbdf-41c8-8b27-ec70512c459e
D/BluetoothGatt: onClientRegistered() - status=0 clientIf=13
D/BluetoothGatt: onClientConnectionState() - status=0 clientIf=13 device=C3:CF:94:B6:44:6E
I/FRD: BLE connection state changed: 0; new state: BLE_CONNECTED
I/FRD: Connected to GATT server.
D/FRD: Processing BLE command: DISCOVER_SERVICES remaining mqtt queue 0, network queue 0
D/BluetoothGatt: discoverServices() - device: C3:CF:94:B6:44:6E
I/BluetoothDevice: createBond() for device C3:CF:94:B6:44:6E called by pid: 23382 tid: 23581
D/FRD: Bond state changed from 10 to 11
D/ViewRootImpl@deeedda[DeviceScanActivity]: MSG_WINDOW_FOCUS_CHANGED 0 1
D/InputMethodManager: prepareNavigationBarInfo() DecorView@13bfaca[DeviceScanActivity]
D/InputMethodManager: getNavigationBarColor() -855310
D/BluetoothGatt: onConnectionUpdated() - Device=C3:CF:94:B6:44:6E interval=6 latency=0 timeout=500 status=0
D/BluetoothGatt: onSearchComplete() = Device=C3:CF:94:B6:44:6E Status=0
I/FRD: Discovered Ble gatt services successfully. Bonding state: 11
D/FRD: GattService: 00001800-0000-1000-8000-00805f9b34fb
D/FRD:  |-characteristics: 00002a00-0000-1000-8000-00805f9b34fb
D/FRD:  |-characteristics: 00002a01-0000-1000-8000-00805f9b34fb
     |-characteristics: 00002a04-0000-1000-8000-00805f9b34fb
D/FRD:  |-characteristics: 00002aa6-0000-1000-8000-00805f9b34fb
    GattService: 00001801-0000-1000-8000-00805f9b34fb
D/FRD: GattService: 8a7f1168-48af-4efb-83b5-e679f932ff00
D/FRD:  |-characteristics: DEVICE_VERSION
     |-characteristics: IOT_ENDPOINT
D/FRD:  |-characteristics: DEVICE_MTU
D/FRD:  |-characteristics: DEVICE_PLATFORM
     |-characteristics: DEVICE_ID
D/FRD: GattService: a9d7166a-d72e-40a9-a002-48044cc30000
D/FRD:  |-characteristics: MQTT_CONTROL
     |-characteristics: MQTT_TX
D/FRD:  |-characteristics: MQTT_RX
D/FRD:  |-characteristics: MQTT_TXLARGE
D/FRD:  |-characteristics: MQTT_RXLARGE
D/FRD: GattService: c6f2d9e3-49e7-4125-9014-bfc6d669ff00
D/FRD:  |-characteristics: c6f2d9e3-49e7-4125-9014-bfc6d669ff01
D/FRD:  |-characteristics: c6f2d9e3-49e7-4125-9014-bfc6d669ff02
    There's no ble command in the queue.
D/BluetoothGatt: onConnectionUpdated() - Device=C3:CF:94:B6:44:6E interval=39 latency=0 timeout=500 status=0
D/ViewRootImpl@deeedda[DeviceScanActivity]: MSG_WINDOW_FOCUS_CHANGED 1 1
D/InputMethodManager: prepareNavigationBarInfo() DecorView@13bfaca[DeviceScanActivity]
    getNavigationBarColor() -855310
D/ViewRootImpl@deeedda[DeviceScanActivity]: stopped(false) old=false
I/AmazonFreeRTOSManager: Stopping ble device scan
D/BluetoothAdapter: STATE_ON
D/BluetoothLeScanner: Stop Scan with callback
D/BluetoothGatt: onConnectionUpdated() - Device=C3:CF:94:B6:44:6E interval=24 latency=0 timeout=400 status=0
D/BluetoothGatt: onClientConnectionState() - status=19 clientIf=13 device=C3:CF:94:B6:44:6E
I/FRD: BLE connection state changed: 19; new state: BLE_DISCONNECTED
    Disconnected from GATT server.
I/DeviceScanFragment: BLE connection status changed to: BLE_DISCONNECTED
I/DeviceScanFragment: connect switch isChecked: OFF
D/FRD: Bond state changed from 11 to 10
D/InputMethodManager: prepareNavigationBarInfo() DecorView@13bfaca[DeviceScanActivity]
D/InputMethodManager: getNavigationBarColor() -855310
V/InputMethodManager: Starting input: tba=software.amazon.freertos.demo ic=null mNaviBarColor -855310 mIsGetNaviBarColorSuccess true , NavVisible : true , NavTrans : false
D/InputMethodManager: startInputInner - Id : 0
I/InputMethodManager: startInputInner - mService.startInputOrWindowGainedFocus
D/InputTransport: Input channel destroyed: 'ClientS', fd=77
D/ViewRootImpl@deeedda[DeviceScanActivity]: stopped(true) old=false
D/OpenGLRenderer: makeCurrent EglSurface : 0x6fb6b3ce80 -> 0x0
D/OpenGLRenderer: destroyEglSurface : 0x6fb6b3ce80
I/mali_egl: eglDestroySurface() in
I/mali_winsys: delete_surface() [1080x2280] return
I/mali_egl: eglDestroySurface() out
W/libEGL: EGLNativeWindowType 0x6fb3af6dd0 disconnect failed

I think BLE connect is disconnected due to Timeout because'y' msg does not come from Android App. Is that correct?
Can you solve this problem? Please.

CBOR Decodes List Network Value Incorrectly

The Android demo compiles, finds and connects to the device successfully, but crashes when parsing the CBOR notification payload from the list networks characteristic. No error is thrown on decoding, but the object is returning { null: null } in the decoded CBOR payload. This causes the demo app to crash. I am running on the beta branch.

Not able to fetch Wifi List after second time ble connection

Describe the bug
There is an issue when we do ble connection second time the wifi list is not getting fetched.

image

Error
More is disabled and when trying to get the list of networks it getting failed

Build info
What is the branch and tag the SDK side?
master

System info
What is the Android version?
11

Logs
2021-12-14 21:01:07.598 23943-23943/software.amazon.freertos.demo I/ViewRootImpl@9690e65[DeviceScanActivity]: ViewPostIme pointer 0
2021-12-14 21:01:07.659 23943-23943/software.amazon.freertos.demo I/ViewRootImpl@9690e65[DeviceScanActivity]: ViewPostIme pointer 1
2021-12-14 21:01:07.685 23943-23943/software.amazon.freertos.demo I/DeviceScanFragment: Connect switch isChecked: ON
2021-12-14 21:01:07.686 23943-23943/software.amazon.freertos.demo I/BluetoothAdapter: STATE_ON
2021-12-14 21:01:07.691 23943-23943/software.amazon.freertos.demo D/BluetoothGatt: connect() - device: 75:11:D0:3A:E8:AB, auto: false
2021-12-14 21:01:07.691 23943-23943/software.amazon.freertos.demo I/BluetoothAdapter: isSecureModeEnabled
2021-12-14 21:01:07.692 23943-23943/software.amazon.freertos.demo D/BluetoothGatt: registerApp()
2021-12-14 21:01:07.693 23943-23943/software.amazon.freertos.demo D/BluetoothGatt: registerApp() - UUID=c46b8139-ce9b-4a10-b170-6e662cb1813d
2021-12-14 21:01:07.699 23943-4958/software.amazon.freertos.demo D/BluetoothGatt: onClientRegistered() - status=0 clientIf=14
2021-12-14 21:01:08.552 23943-4958/software.amazon.freertos.demo D/BluetoothGatt: onClientConnectionState() - status=0 clientIf=14 device=75:11:D0:3A:E8:AB
2021-12-14 21:01:08.563 23943-4958/software.amazon.freertos.demo I/FRD: BLE connection state changed: 0; new state: BLE_CONNECTED
2021-12-14 21:01:08.563 23943-4958/software.amazon.freertos.demo I/FRD: Connected to GATT server.
2021-12-14 21:01:08.564 23943-4958/software.amazon.freertos.demo D/FRD: Processing BLE command: DISCOVER_SERVICES remaining mqtt queue 0, network queue 0
2021-12-14 21:01:08.564 23943-4958/software.amazon.freertos.demo D/BluetoothGatt: discoverServices() - device: 75:11:D0:3A:E8:AB
2021-12-14 21:01:09.018 23943-4958/software.amazon.freertos.demo D/BluetoothGatt: onConnectionUpdated() - Device=75:11:D0:3A:E8:AB interval=6 latency=0 timeout=500 status=0
2021-12-14 21:01:09.410 23943-4958/software.amazon.freertos.demo D/BluetoothGatt: onSearchComplete() = Device=75:11:D0:3A:E8:AB Status=0
2021-12-14 21:01:09.411 23943-4958/software.amazon.freertos.demo I/FRD: Discovered Ble gatt services successfully. Bonding state: 12
2021-12-14 21:01:09.411 23943-4958/software.amazon.freertos.demo D/FRD: GattService: 00001800-0000-1000-8000-00805f9b34fb
2021-12-14 21:01:09.411 23943-4958/software.amazon.freertos.demo D/FRD: |-characteristics: 00002a00-0000-1000-8000-00805f9b34fb
2021-12-14 21:01:09.412 23943-4958/software.amazon.freertos.demo D/FRD: |-characteristics: 00002a01-0000-1000-8000-00805f9b34fb
2021-12-14 21:01:09.412 23943-4958/software.amazon.freertos.demo D/FRD: GattService: 00001801-0000-1000-8000-00805f9b34fb
2021-12-14 21:01:09.412 23943-4958/software.amazon.freertos.demo D/FRD: |-characteristics: 00002a05-0000-1000-8000-00805f9b34fb
2021-12-14 21:01:09.412 23943-4958/software.amazon.freertos.demo D/FRD: GattService: 8a7f1168-48af-4efb-83b5-e679f932ff00
2021-12-14 21:01:09.412 23943-4958/software.amazon.freertos.demo D/FRD: |-characteristics: DEVICE_VERSION
2021-12-14 21:01:09.412 23943-4958/software.amazon.freertos.demo D/FRD: |-characteristics: IOT_ENDPOINT
2021-12-14 21:01:09.413 23943-4958/software.amazon.freertos.demo D/FRD: |-characteristics: DEVICE_MTU
2021-12-14 21:01:09.413 23943-4958/software.amazon.freertos.demo D/FRD: |-characteristics: DEVICE_PLATFORM
2021-12-14 21:01:09.413 23943-4958/software.amazon.freertos.demo D/FRD: |-characteristics: DEVICE_ID
2021-12-14 21:01:09.413 23943-4958/software.amazon.freertos.demo D/FRD: GattService: a9d7166a-d72e-40a9-a002-48044cc30100
2021-12-14 21:01:09.413 23943-4958/software.amazon.freertos.demo D/FRD: |-characteristics: NETWORK_CONTROL
2021-12-14 21:01:09.414 23943-4958/software.amazon.freertos.demo D/FRD: |-characteristics: NETWORK_TX
2021-12-14 21:01:09.414 23943-4958/software.amazon.freertos.demo D/FRD: |-characteristics: NETWORK_RX
2021-12-14 21:01:09.414 23943-4958/software.amazon.freertos.demo D/FRD: |-characteristics: NETWORK_TXLARGE
2021-12-14 21:01:09.414 23943-4958/software.amazon.freertos.demo D/FRD: |-characteristics: NETWORK_RXLARGE
2021-12-14 21:01:09.414 23943-4958/software.amazon.freertos.demo D/FRD: Getting ble software version on device.
2021-12-14 21:01:09.415 23943-4958/software.amazon.freertos.demo D/FRD: Ble operation is in progress. mqtt queue: 0 network queue: 1
2021-12-14 21:01:09.415 23943-4958/software.amazon.freertos.demo D/FRD: Processing BLE command: READ_CHARACTERISTIC remaining mqtt queue 0, network queue 0
2021-12-14 21:01:09.415 23943-4958/software.amazon.freertos.demo D/FRD: <-<-<- Reading from characteristic: DEVICE_VERSION
2021-12-14 21:01:09.438 23943-4958/software.amazon.freertos.demo D/FRD: ->->-> onCharacteristicRead status: 12
2021-12-14 21:01:09.438 23943-4958/software.amazon.freertos.demo D/FRD: There's no ble command in the queue.
2021-12-14 21:01:09.514 23943-4958/software.amazon.freertos.demo D/BluetoothGatt: onConnectionUpdated() - Device=75:11:D0:3A:E8:AB interval=36 latency=0 timeout=500 status=0

Unable to access gatt characterstice

I want to add callback or indication of service discovery and all. Right now there is no way in sdk in which I can trigger now discover service this services are discovered perform this operation write or notify custom characteristics.
How to enable those ?

Can't build with master branch 040dc15

Describe the bug
In newest commit 040dc15 on master branch:

if (connectionStatus == AmazonFreeRTOSConstants.BleConnectionState.BLE_INITIALIZED) {

BLE_INITIALIZED is not part of AmazonFreeRTOSConstants.BleConnectionState in release 1.1.0/1.0.0.

Do we have any plan to update build.gradle file for app?

implementation ('software.amazon.freertos:amazonfreertossdk:1.0.0')

Or we have to roll back until next release is ready?

Build info
SDK commit id: 040dc15

System info
API 29

To Reproduce
Clone repository and build the demo app

PIN Based Bluetooth Connection

I am trying to connect to a Bluetooth device which is restricted with Pin Authentication but cannot see an option to pass that PIN via the Android SDK.

System info
Android version: 13

To Reproduce
Frequency: No Support
Steps to reproduce the behavior: Connect with Bluetooth device restricted with pin

ESP32 wifi provisioning

I am using ESP32 DevkitC as IoT thing. Also, I am using the app from amazon-freertos-ble-android-sdk/app at master · aws/amazon-freertos-ble-android-sdk (github.com). My intention is to do WiFi provisioning of ESP32 using BLE.
The android app lists the ESP32 device. And it prompts for bluetooth pairing as well. But after that I am not able to see the next options to do network config. I am using Android version 9 on the phone.
Attaching the screenshot of the android app.

In android studio I could see this error in logcat:
2021-06-23 17:34:43.253 911-1084/software.amazon.freertos.demo D/com.amazonaws.request: Received error response: com.amazonaws.services.iot.model.InvalidRequestException: Empty Target (Service: null; Status Code: 400; Error Code: InvalidRequestException; Request ID: 94c40124-4070-423c-a250-522e47d30f41)
2021-06-23 17:34:43.256 911-1084/software.amazon.freertos.demo E/AuthActivity: Exception caught:
com.amazonaws.services.iot.model.InvalidRequestException: Empty Target (Service: AWSIot; Status Code: 400; Error Code: InvalidRequestException; Request ID: 94c40124-4070-423c-a250-522e47d30f41)
at com.amazonaws.http.AmazonHttpClient.handleErrorResponse(AmazonHttpClient.java:730)
at com.amazonaws.http.AmazonHttpClient.executeHelper(AmazonHttpClient.java:405)
at com.amazonaws.http.AmazonHttpClient.execute(AmazonHttpClient.java:212)
at com.amazonaws.services.iot.AWSIotClient.invoke(AWSIotClient.java:9226)
at com.amazonaws.services.iot.AWSIotClient.attachPolicy(AWSIotClient.java:589)
at software.amazon.freertos.demo.AuthenticatorActivity.signinsuccessful(AuthenticatorActivity.java:116)
at software.amazon.freertos.demo.AuthenticatorActivity.access$000(AuthenticatorActivity.java:24)
at software.amazon.freertos.demo.AuthenticatorActivity$2.run(AuthenticatorActivity.java:68)
at android.os.Handler.handleCallback(Handler.java:873)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:193)
at android.os.HandlerThread.run(HandlerThread.java:65)
2021-06-23 17:34:43.300 911-967/software.amazon.freertos.demo D/AWS4Signer: AWS4 Canonical Request: '"PUT
/target-policies/mypolicy

Also attaching full logcat.
app_screen
logcat.txt

Issue with version 0.9.3 for Samsung S10e.

I am trying to connect esp32 using my Samsung S10e device with freetos ble android sdk version 0.9.3

Esp32 firmware details is:
AFR V1.4.7 released on 02/18/2019

I am able successfully connect/pair ble, After that I fire list command successfully get wifi list as well.
but when i try to fire save command to esp32 it's not successfully execute command and network is not save in device.

This one also not work in AWS demo for 0.9.3 sdk.

Device info:
Samsung s10e
Os: Android 10
Android security patch: March 1, 2020

MQTT proxy no longer working.

After pulling the latest commit on the beta branch the MQTT proxy will no longer connect to my device. I am using the Nordic NRF52840DK with the Android SDK running on a Samsung Galaxy S10. I have no modifications to the Android SDK except adding my AWS information.

I can connect to BLE but after clicking MQTT it seems to crash back to the BLE connection page of the app. From the log it looks like MQTT cannot see there is a device connected on BLE.

Here is the Android log trying to open an mqtt connection:

2019-05-16 09:56:53.457 22341-23332/com.amazon.aws.freertosandroid D/AWSMobileClient: hasFederatedToken: true provider: cognito-idp.us-west-2.amazonaws.com/us-west-2
2019-05-16 09:56:53.526 22341-22991/com.amazon.aws.freertosandroid D/AWSMobileClient: Inspecting user state details
2019-05-16 09:56:53.728 22341-22991/com.amazon.aws.freertosandroid D/AWSMobileClient: hasFederatedToken: true provider: cognito-idp.us-west-2.amazonaws.com/us-west-2
2019-05-16 09:56:53.728 22341-22991/com.amazon.aws.freertosandroid D/AuthActivity: onResult: SIGNED_IN
2019-05-16 09:56:53.729 22341-22991/com.amazon.aws.freertosandroid I/AuthActivity: logged in!
2019-05-16 09:56:53.956 22341-22991/com.amazon.aws.freertosandroid D/AWSMobileClient: Inspecting user state details
2019-05-16 09:56:54.187 22341-22991/com.amazon.aws.freertosandroid D/AWSMobileClient: hasFederatedToken: true provider: cognito-idp.us-west-2.amazonaws.com/us-west-2
2019-05-16 09:56:54.188 22341-22991/com.amazon.aws.freertosandroid D/AWSMobileClient: waitForSignIn: userState:SIGNED_IN
2019-05-16 09:56:54.188 22341-22991/com.amazon.aws.freertosandroid D/AWSMobileClient: getCredentials: Validated user is signed-in
2019-05-16 09:56:54.280 22341-22991/com.amazon.aws.freertosandroid I/System.out: (HTTPLog)-Static: isSBSettingEnabled false
2019-05-16 09:56:54.281 22341-22991/com.amazon.aws.freertosandroid I/System.out: (HTTPLog)-Static: isSBSettingEnabled false
2019-05-16 09:56:54.680 22341-22991/com.amazon.aws.freertosandroid I/AuthActivity: Iot policy attached successfully.
2019-05-16 09:56:54.689 22341-22341/com.amazon.aws.freertosandroid D/ViewRootImpl@5e666f4[AuthenticatorActivity]: dispatchDetachedFromWindow
2019-05-16 09:56:54.689 22341-22341/com.amazon.aws.freertosandroid D/ViewRootImpl@5e666f4[AuthenticatorActivity]: Surface release. android.view.ViewRootImpl.doDie:7944 android.view.ViewRootImpl.die:7912 android.view.WindowManagerGlobal.removeViewLocked:497 android.view.WindowManagerGlobal.removeView:435 android.view.WindowManagerImpl.removeViewImmediate:124 android.app.ActivityThread.handleDestroyActivity:4747 android.app.servertransaction.DestroyActivityItem.execute:39 android.app.servertransaction.TransactionExecutor.executeLifecycleState:145
2019-05-16 09:56:54.691 22341-22991/com.amazon.aws.freertosandroid D/AWSMobileClient: run: showSignIn completed
2019-05-16 09:56:54.701 22341-22341/com.amazon.aws.freertosandroid D/InputTransport: Input channel destroyed: fd=120
2019-05-16 09:56:57.106 22341-22341/com.amazon.aws.freertosandroid D/ViewRootImpl@24a3b87[MqttProxyActivity]: ViewPostIme pointer 0
2019-05-16 09:56:57.181 22341-22341/com.amazon.aws.freertosandroid D/ViewRootImpl@24a3b87[MqttProxyActivity]: ViewPostIme pointer 1
2019-05-16 09:56:57.591 22341-22341/com.amazon.aws.freertosandroid D/ViewRootImpl@24a3b87[MqttProxyActivity]: ViewPostIme pointer 0
2019-05-16 09:56:57.673 22341-22341/com.amazon.aws.freertosandroid D/ViewRootImpl@24a3b87[MqttProxyActivity]: ViewPostIme pointer 1
2019-05-16 09:56:57.678 22341-22341/com.amazon.aws.freertosandroid I/MqttProxyFragment: mqtt proxy switch isChecked: ON
2019-05-16 09:56:57.678 22341-22341/com.amazon.aws.freertosandroid E/MqttProxyFragment: There's no connected device: null

Unable to customise gatt characteristics operation

Hi ,
I am developing an application and using this freetos sdk for it. I want to apply some security features before sending the data over cloud. And for that I need to apply some customized code before sending the data .
But for that I need some call back on app side about characteristics scan or read or modify in app side. So how to perfrom any code in gatt profile ?

BLE Disconnect while doing wifi Provisioning with Samsung galaxy S10 Mobile having Android 10

Issue Description
While Doing wifi provisioning, Ble pairing working properly, List Network is working properly, while calling Save Network with router details, it disconnect from BLE every time, we have tried on multiple s10 devices and seen the same behaviour.

Mobile App LogCat:
2020-08-10 13:34:57.658 20599-20693/AppID D/AmazonFreeRTOSDevice: Processing BLE command: WRITE_CHARACTERISTIC queue size: 0
2020-08-10 13:34:57.659 20599-20693/AppId D/AmazonFreeRTOSDevice: <-<-<- Writing to characteristic: SAVE_NETWORK with data: a561624614ae85ef3be96167
2020-08-10 13:35:00.666 20599-21084/App Id W/AmazonFreeRTOSDevice: Ble command failed to be sent OR timeout after 3000ms
2020-08-10 13:35:00.666 20599-21084/AppId D/AmazonFreeRTOSDevice: There's no ble command in the queue.
2020-08-10 13:35:02.764 20599-20619/AppID D/AmazonFreeRTOSDevice: onCharacteristicWrite for: SAVE_NETWORK; status: 133; value: a561624614ae85ef3be96167
2020-08-10 13:35:02.764 20599-20619/AppId E/AmazonFreeRTOSDevice: Unknown characteristic 3113a187-4b9f-4f9a-aa83-c614e11bff02
2020-08-10 13:35:02.764 20599-20619/AppId D/AmazonFreeRTOSDevice: There's no ble command in the queue.
2020-08-10 13:35:02.765 20599-20619/AppID D/BluetoothGatt: onClientConnectionState() - status=8 clientIf=12 device=4C:11:AE:EB:7F:86
2020-08-10 13:35:02.770 20599-20619/AppID I/AmazonFreeRTOSDevice: BLE connection state changed: 8; new state: BLE_DISCONNECTED
2020-08-10 13:35:02.770 20599-20619/AppID I/AmazonFreeRTOSDevice: Disconnected from GATT server.
2020-08-10 13:35:02.770 20599-20619/AppID D/RNAfrmodule: Ble StatusBLE_DISCONNECTED
2020-08-10 13:35:02.771 20599-20619/AppIID D/BluetoothGatt: close()
2020-08-10 13:35:02.775 20599-20692/AppID I/ReactNativeJS: 'afrBleStatus res ', { connectionStatus: 0 }
2020-08-10 13:35:02.792 20599-20619/APPID D/BluetoothGatt: unregisterApp() - mClientIf=12
2020-08-10 13:35:02.822 20599-20599/AppID D/Dialog: mIsSamsungBasicInteraction = false

Analysis on Other Phone
it is working on other android phones.

Kindly help us with this issue, as it is impacting our customers.

Recommended way to disconnect during pairing/bonding

Describe the bug
Exception occurs in AmazonFreeRTOSDevice disconnect() mContext.unregisterReceiver(mBondStateBroadcastReceiver); when using AmazonFreeRTOSManager disconnectFromDevice() while waiting for a connection. The line mBluetoothGatt.close() never gets closed due to the exception, but it's not clear whether the close() call would adequately clean things up.

Build info
What is the branch and commit on the device side? Not sure; device is using Pin pairing.
What is the branch and tag the SDK side? v1.1.0
Does pulling the latest code help resolve the issue? Using Gradle, did not pull latest version.

System info
What is the Android version? 10
What is the bluetooth version? 4.2

To Reproduce
What is the frequency of this issue? Every time
Steps to reproduce the behavior: Disconnect before connection is fully established.

Log
Could you provide log on both the device side and SDK side?
Device had not output anything pertinent to the connection when the exception occurred in the app. Here is the app stacktrace:

    java.lang.IllegalArgumentException: Receiver not registered: software.amazon.freertos.amazonfreertossdk.AmazonFreeRTOSDevice$1@3572ecd
        at android.app.LoadedApk.forgetReceiverDispatcher(LoadedApk.java:1429)
        at android.app.ContextImpl.unregisterReceiver(ContextImpl.java:1543)
        at android.content.ContextWrapper.unregisterReceiver(ContextWrapper.java:664)
        at software.amazon.freertos.amazonfreertossdk.AmazonFreeRTOSDevice.disconnect(AmazonFreeRTOSDevice.java:170)
        at software.amazon.freertos.amazonfreertossdk.AmazonFreeRTOSManager.disconnectFromDevice(AmazonFreeRTOSManager.java:216)
        at com.ghsp.uvc.managers.UvcProvisioningManager.disconnect(UvcProvisioningManager.kt:79)
        at com.ghsp.uvc.ui.MainActivity.onSupportNavigateUp(MainActivity.kt:45)
        at androidx.appcompat.app.AppCompatActivity.onMenuItemSelected(AppCompatActivity.java:226)
        at androidx.appcompat.view.WindowCallbackWrapper.onMenuItemSelected(WindowCallbackWrapper.java:109)
        at androidx.appcompat.widget.ToolbarWidgetWrapper$1.onClick(ToolbarWidgetWrapper.java:188)
        at android.view.View.performClick(View.java:7140)
        at android.view.View.performClickInternal(View.java:7117)
        at android.view.View.access$3500(View.java:801)
        at android.view.View$PerformClick.run(View.java:27351)
        at android.os.Handler.handleCallback(Handler.java:883)
        at android.os.Handler.dispatchMessage(Handler.java:100)
        at android.os.Looper.loop(Looper.java:214)
        at android.app.ActivityThread.main(ActivityThread.java:7356)
        at java.lang.reflect.Method.invoke(Native Method)
        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:492)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:930)

Additional context
Add any other context about the problem here.

onClientConnectionState() - status=133 clientIf=7

Facing this error while connecting to ble in some android devices. Majorly it is in motorola, samsung and redmi. Specifically for OS 7.0 and 7.1.1

Other OS and device it is working perfect.

When I am trying to connect, it immediately calls onClientConnectionStatus with gatt error 133.

Any solution for this?

D/BluetoothGatt: onClientConnectionState() - status=133 clientIf=7 device={deviceId} I/AmazonFreeRTOSDevice: BLE connection state changed: 133; new state: BLE_DISCONNECTED

Require a button to refresh the wifi AP list

Describe the bug
There is an issue that no all surrounding wifi APs are listed in network setting UI. Require a button to request the wifi provisioning example to rescan surrounding WIFI APs.
Please refer to the following picture,

WeChat Image_20210623114436

cannot open wifi provisioning

hye, im new to this and i have face problem where i open WiFi provisioning.
I already connect the esp32 with my device but i cannot do the WiFi provisioning. when i try to open WiFi provisioning it just blank page. Can someone help me.

How to use keyStore?

esp32ListView.setOnItemClickListener(new AdapterView.OnItemClickListener() {
            @Override
            public void onItemClick(AdapterView<?> parent, View view, int position, long id) {

                if(amazonFreeRTOSDevice != null){
                    amazonFreeRTOSManager.disconnectFromDevice(amazonFreeRTOSDevice);
                    amazonFreeRTOSDevice = null;
                }
                // esp32List.get(position).getBluetoothDevice().createBond() // 최후의 수단

                try {
                    amazonFreeRTOSDevice = amazonFreeRTOSManager
                            .connectToDevice(
                                    esp32List.get(position).getBluetoothDevice(),
                                    connectionStatusCallback,
                                    KeyStore.getInstance("String"),
                                    false);

                } catch (KeyStoreException e) {
                    e.printStackTrace();
                }
            }
        });

i don't know Keystore, help me.. plz

onBleConnectionStatusChanged callback is not called in BLE_CONNECTED case

Describe the bug
The SDK allows clients to register a callback for BLE connection status changes. The callback is not called in the BLE_CONNECTED case.

I believe this behavior was broken in this change: 02e3b23

Specifically this line was removed: 02e3b23#diff-78fe5461821fc69ea3e2b628ae293eb60bd1b34b427f5aef8e4721fb9f95ec91L436

Build info
What is the branch and commit on the device side?
What is the branch and tag the SDK side? https://github.com/aws/amazon-freertos-ble-android-sdk/releases/tag/v1.2.0
Does pulling the latest code help resolve the issue? No

System info
What is the Android version? Android version 10
What is the bluetooth version? Tested on Samsung Galaxy A71 which has Bluetooth v5. I don't believe this is a version/phone specific bug though.

To Reproduce
What is the frequency of this issue? 100%
Steps to reproduce the behavior:

Register a callback and connect to a device. Observe that it is never called in the BLE_CONNECTED case.

 amazonFreeRTOSManager.connectToDevice(bleDevice.getDevice(), new BleConnectionStatusCallback() {
            @Override
            public void onBleConnectionStatusChanged(AmazonFreeRTOSConstants.BleConnectionState connectionStatus) {

...

Log
Could you provide log on both the device side and SDK side?

Additional context
Add any other context about the problem here.

location services must be enabled

Describe the bug
I suggest to indicate clearly in the documentation that location services must be enabled on Android device. Or test it in the app and display a warning when it is not enabled.
If the user didn't enable location services on its Android device, the device will not appear when clicking on "Scan for BLE devices" in the Android application. For the user it is not obvious that the device doesn't appear because location services are disabled.

Build info
What is the branch and commit on the device side? 2201912.00
What is the branch and tag the SDK side? v1.1.0
Does pulling the latest code help resolve the issue? no

System info
What is the Android version? 6.0
What is the bluetooth version? 4.2

To Reproduce
What is the frequency of this issue? always
Steps to reproduce the behavior: on the Android device: in the Settings, disable location services. enable bluetooth. start Amazon FreeRTOS application. click on "Scan for BLE devices".

Log
Could you provide log on both the device side and SDK side?

Additional context
none

[question] app changes

Hi,
i have one question about changes in app. In older version we were able to provide wifi credentials without login with cognito and i liked it, because i am using this app for developing purpose. Now i have to create cognito account just to provide wifi credentials even if i dont want to use mqtt over ble. Is that necessary?

Also i cant use old version because in afr release-1.5 all UUIDs got changed.

Get status in SaveNetworkResp

When building a custom app using the SDK, I've noticed that the SaveNetworkResp does not contain a getStatus() method the same way as the ListNetworkResp does. It is possible to use contains() method on the response.toString() to capture the status required:

@Override
public void onSaveNetworkResponse(final SaveNetworkResp response) {
  if (response.toString().contains("status: 0")) {
    Log.i(TAG, "Network saved successfully");     
  } else {
    Log.i(TAG, "Network not saved");     
  }
}

However it feels more like a workaround, rather than an optimal solution. After investigating, I've noticed that the SaveNetworkResp class is missing a @Getter annotation. Same for DeleteNetworkResp and EditNetworkResp. After adding @Getter to the classes, getStatus() can be used:

@Override
public void onSaveNetworkResponse(final SaveNetworkResp response) {
  if (response.getStatus() == 0) {
    Log.i(TAG, "Network saved successfully");     
  } else {
    Log.i(TAG, "Network not saved");     
  }
}

I've made a commit ignasbol@025a8c1 to solve this.

Network connection closes on any incoming messages from Cloud

Describe the bug
Any time a message is published via AWS IoT on a topic which the system is subscribed to, an error occurs and the connection gets closed. The system's code works entirely in combination with the IOS SDK, it purely gives the error when connected to the cloud via the Android SDK.

Build info
ESP runs the master freertos branch, commit 12d7ad7
Android SDK runs the master branch, commit de66e51

System info
Android 10
Bluetooth 5.0, Bluetooth LE/Smart/4.0+
ESP32 DevKitC 32D

To Reproduce
Issue happens any time a message is sent from the Cloud to a topic the ESP is subscribed to

Log
Log from ESP:

38 18621 [ble] [ERROR] [MQTT_BLE] [iot_ble_mqtt_transport.c:1173] 39 18621 [ble] An error occured when receiving data from the channel. No data was recorded.40 18621 [ble]
41 18871 [ble] [ERROR][MQTT][18871] (MQTT connection 0x3ffdc2bc) Unknown packet type ff received.
42 18871 [ble] [ERROR][MQTT][18871] (MQTT connection 0x3ffdc2bc) Error processing incoming data. Closing connection.
43 18872 [ble] [INFO ][MQTT][18871] (MQTT connection 0x3ffdc2bc) Network connection closed.

Not able to Update awsconfiguration.json

I want to configure AWSConfiguration on app startup.
I want to configure cognito details on login page, but awsconfiguration,json file not able to update because of raw inside file not updated,.
Also app working only when awsconfiguration,json inside raw folder.

Please give me suggestion for AWSconfigation before login process.

Blank screen for a while when opening the Freertos demo android app if the account has been logged in

Describe the bug
Blank screen for a while when opening the Freertos demo android app if the account has been logged in

Build info
What is the branch and commit on the device side?
b3b9cb41f5572f6671f218519ddfa78a7b2b2d50
What is the branch and tag the SDK side?
2449479
Does pulling the latest code help resolve the issue?
No
System info
What is the Android version?
Android 9
What is the bluetooth version?
Bluetooth 4.2
To Reproduce
What is the frequency of this issue?
After kill the app on the cellphone side. And then run it, the blank screen for a while every times.
Steps to reproduce the behavior:

  1. Kill the running APK.
  2. Open the APK again.

Log
Screenshot_20201030_150835_software amazon freertos demo

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.