Mayank
Hi All,
Here i'm facing the issue even after using the full UART (Tx, Rx, RTS, CTS). These 4 pins are connected & configured from both (i.MX6UL & nrf52840_pca10056). Note : nrf52840 chip is flashed with HCI_UART sample app of zephyr. In that i have configured 4 pins and make HWFC enable from nrf5.conf file. Ans still i'm not facing this issue continuously. Lets say i'm keeping beacon scanning on for 4-5 hours then its working fine. It crashes when i keep it running for 2-3 days. Thanks, Mayank
|
|
Chettimada, Vinayak Kariappa
Hi Jamie,
All the disconnects are Host Bluetooth stack initiated. I will need some help from BlueZ guys to throw some light here.
Regards, Vinayak
From: Jamie Mccrae <Jamie.Mccrae@...>
Sent: 06 March 2020 09:04 To: Chettimada, Vinayak Kariappa <vinayak.kariappa.chettimada@...>; Cufi, Carles <Carles.Cufi@...>; mayank7117@...; devel@... Subject: RE: [Zephyr-devel] hci interface stopped working after few hours #ble #hci #nrf52480 #uart
Hi Vinayak > A btmon log would help identify the reason for disconnection.
I have uploaded the 2 logs here: https://www.dropbox.com/s/d2yurf6nxee9wk0/btmon_logs.zip?dl=0 The Zephyr one has quite a lot at the beginning before I made the connection. Here is one of the disconnect events from the zephyr log file: < HCI Command: Disconnect (0x01|0x0006) plen 3 #624 [hci0] 292.906310 Handle: 0 Reason: Remote User Terminated Connection (0x13) > HCI Event: Command Status (0x0f) plen 4 #625 [hci0] 292.907421 Disconnect (0x01|0x0006) ncmd 1 Status: Success (0x00) > HCI Event: Disconnect Complete (0x05) plen 4 #626 [hci0] 292.923423 Status: Success (0x00) Handle: 0 Reason: Connection Terminated By Local Host (0x16) @ MGMT Event: Device Disconnected (0x000c) plen 8 {0x0002} [hci0] 292.923459 LE Address: DC:59:20:76:11:5C (Static) Reason: Connection terminated by local host (0x02) @ MGMT Event: Device Disconnected (0x000c) plen 8 {0x0001} [hci0] 292.923459 LE Address: DC:59:20:76:11:5C (Static) Reason: Connection terminated by local host (0x02)
> > the connection parameter update still fails but even minutes later I am still connected to the remote device. > > This is weird, the cypress dongle did not perform connection parameter update, update procedure on air only either succeeds or disconnects (unless it’s a connection parameter request procedure that is rejected by peer).
Yes, that is what it is, apologies:
> ACL Data RX: Handle 0 flags 0x02 dlen 16 #179 [hci0] 69.454378 LE L2CAP: Connection Parameter Update Request (0x12) ident 2 len 8 Min interval: 6 Max interval: 12 Slave latency: 0 Timeout multiplier: 400 < ACL Data TX: Handle 0 flags 0x00 dlen 10 #180 [hci0] 69.454425 LE L2CAP: Connection Parameter Update Response (0x13) ident 2 len 2 Result: Connection Parameters rejected (0x0001)
Thanks, Jamie THIS MESSAGE, ANY ATTACHMENT(S), AND THE INFORMATION CONTAINED HEREIN MAY BE PROPRIETARY TO LAIRD CONNECTIVITY, INC. AND/OR ANOTHER PARTY, AND MAY FURTHER BE INTENDED TO BE KEPT CONFIDENTIAL. IF YOU ARE NOT THE INTENDED RECIPIENT, PLEASE DELETE THE EMAIL AND ANY ATTACHMENTS, AND IMMEDIATELY NOTIFY THE SENDER BY RETURN EMAIL. THIS MESSAGE AND ITS CONTENTS ARE THE PROPERTY OF LAIRD CONNECTIVITY, INC. AND MAY NOT BE REPRODUCED OR USED WITHOUT THE EXPRESS WRITTEN CONSENT OF LAIRD CONNECTIVITY, INC.
|
|
lairdjm
Hi Vinayak > A btmon log would help identify the reason for disconnection.
I have uploaded the 2 logs here: https://www.dropbox.com/s/d2yurf6nxee9wk0/btmon_logs.zip?dl=0 The Zephyr one has quite a lot at the beginning before I made the connection. Here is one of the disconnect events from the zephyr log file: < HCI Command: Disconnect (0x01|0x0006) plen 3 #624 [hci0] 292.906310 Handle: 0 Reason: Remote User Terminated Connection (0x13) > HCI Event: Command Status (0x0f) plen 4 #625 [hci0] 292.907421 Disconnect (0x01|0x0006) ncmd 1 Status: Success (0x00) > HCI Event: Disconnect Complete (0x05) plen 4 #626 [hci0] 292.923423 Status: Success (0x00) Handle: 0 Reason: Connection Terminated By Local Host (0x16) @ MGMT Event: Device Disconnected (0x000c) plen 8 {0x0002} [hci0] 292.923459 LE Address: DC:59:20:76:11:5C (Static) Reason: Connection terminated by local host (0x02) @ MGMT Event: Device Disconnected (0x000c) plen 8 {0x0001} [hci0] 292.923459 LE Address: DC:59:20:76:11:5C (Static) Reason: Connection terminated by local host (0x02)
> > the connection parameter update still fails but even minutes later I am still connected to the remote device. > > This is weird, the cypress dongle did not perform connection parameter update, update procedure on air only either succeeds or disconnects (unless it’s a connection parameter request procedure that is rejected by peer).
Yes, that is what it is, apologies:
> ACL Data RX: Handle 0 flags 0x02 dlen 16 #179 [hci0] 69.454378 LE L2CAP: Connection Parameter Update Request (0x12) ident 2 len 8 Min interval: 6 Max interval: 12 Slave latency: 0 Timeout multiplier: 400 < ACL Data TX: Handle 0 flags 0x00 dlen 10 #180 [hci0] 69.454425 LE L2CAP: Connection Parameter Update Response (0x13) ident 2 len 2 Result: Connection Parameters rejected (0x0001)
Thanks, Jamie
|
|
Chettimada, Vinayak Kariappa
Hi Jamie,
A btmon log would help identify the reason for disconnection.
> the connection parameter update still fails but even minutes later I am still connected to the remote device.
This is weird, the cypress dongle did not perform connection parameter update, update procedure on air only either succeeds or disconnects (unless it’s a connection parameter request procedure that is rejected by peer).
Regards, Vinayak
From: Jamie Mccrae <Jamie.Mccrae@...>
Sent: 06 March 2020 08:43 To: Chettimada, Vinayak Kariappa <vinayak.kariappa.chettimada@...>; Cufi, Carles <Carles.Cufi@...>; mayank7117@...; devel@... Subject: RE: [Zephyr-devel] hci interface stopped working after few hours #ble #hci #nrf52480 #uart
Hi Vinayak I gave it a try this morning with the latest master build of zephyr using the HCI_USB on an nrf52840_pca10059 dongle and I don’t get the errors/timeout issues as I save previously when I tested, however, GATT is unusable from bluetoothctl on linux (BlueZ 5.50). With the zephyr dongle, the device connects, seems to fail a connection parameter updates and disconnects – I am unable to list any details from the GATT server on the remote device (nothing comes through automatically and in the gatt menu, list-attributes seemingly does nothing). In comparison with a non-zephyr (cypress) based USB HCI dongle, it connects and instantly lists the GATT table, the connection parameter update still fails but even minutes later I am still connected to the remote device.
When I tested previously with a UART, it was with flow hardware control wired up to the FTDI chip. If zephyr was set to use it or not I cannot recall (it would have been the default for the HCI_UART example). Thanks, Jamie THIS MESSAGE, ANY ATTACHMENT(S), AND THE INFORMATION CONTAINED HEREIN MAY BE PROPRIETARY TO LAIRD CONNECTIVITY, INC. AND/OR ANOTHER PARTY, AND MAY FURTHER BE INTENDED TO BE KEPT CONFIDENTIAL. IF YOU ARE NOT THE INTENDED RECIPIENT, PLEASE DELETE THE EMAIL AND ANY ATTACHMENTS, AND IMMEDIATELY NOTIFY THE SENDER BY RETURN EMAIL. THIS MESSAGE AND ITS CONTENTS ARE THE PROPERTY OF LAIRD CONNECTIVITY, INC. AND MAY NOT BE REPRODUCED OR USED WITHOUT THE EXPRESS WRITTEN CONSENT OF LAIRD CONNECTIVITY, INC.
|
|
lairdjm
Hi Vinayak I gave it a try this morning with the latest master build of zephyr using the HCI_USB on an nrf52840_pca10059 dongle and I don’t get the errors/timeout issues as I save previously when I tested, however, GATT is unusable from bluetoothctl on linux (BlueZ 5.50). With the zephyr dongle, the device connects, seems to fail a connection parameter updates and disconnects – I am unable to list any details from the GATT server on the remote device (nothing comes through automatically and in the gatt menu, list-attributes seemingly does nothing). In comparison with a non-zephyr (cypress) based USB HCI dongle, it connects and instantly lists the GATT table, the connection parameter update still fails but even minutes later I am still connected to the remote device.
When I tested previously with a UART, it was with flow hardware control wired up to the FTDI chip. If zephyr was set to use it or not I cannot recall (it would have been the default for the HCI_UART example). Thanks, Jamie
|
|
Chettimada, Vinayak Kariappa
Hi, Both Mayank and Jamie,
I am interested in the way the HCI packets are transported to the Host Bluetooth stack.
In case of use of nRF DKs and Dongle, if using JLink debugger host firmware, you need to disable the Mass storage device (I don’t remember, it is something to do with 64-byte USB frames). Hence, my request to try with MBED debugger host firmware which is a different UART to USB implementation.
In case using custom UART to USB, like FTDI, do you wire the CTS/RTS and using hardware flow control?
Same for the TTL connections, correct CTS/RTS and hardware flow control is essential.
The rationale being, observed HCI timeout and HCI framing errors indicate corrupted UART traffic.
Regards, Vinayak
From: devel@... <devel@...>
On Behalf Of lairdjm via Lists.Zephyrproject.Org
Sent: 05 March 2020 17:34 To: Cufi, Carles <Carles.Cufi@...>; Chettimada, Vinayak Kariappa <vinayak.kariappa.chettimada@...>; mayank7117@...; devel@... Cc: devel@... Subject: Re: [Zephyr-devel] hci interface stopped working after few hours #ble #hci #nrf52480 #uart
Hi Carles, I was assuming it was aimed at both of us, I’m not sure about what hardware they’re using. I’ll give it a try tomorrow with the hardware I have and see if it’s working with the latest branch of zephyr. Thanks, Jamie
|
|
Re: Zephyr base improvement / improved Zephyr user experience
Rasmussen, Torsten
To test the PR: https://github.com/zephyrproject-rtos/zephyr/pull/23054 west zephyr-export
|
|
Zephyr Toolchain Working Group Meeting – 05 March 2020
Rasmussen, Torsten
Hi,Today’s meeting minutes:https://docs.google.com/document/d/1IQKBK-GcJNZG0O9QArqYfvb6Huk5xHscN-XIGEZr-z8/Notes/MinutesStatus updates
Would be nice to know the reason / get explanation
General discussion regarding toolchain support
Actions
Best regards
Torsten Tejlmand Rasmussen
|
|
lairdjm
Hi Carles, I was assuming it was aimed at both of us, I’m not sure about what hardware they’re using. I’ll give it a try tomorrow with the hardware I have and see if it’s working with the latest branch of zephyr. Thanks, Jamie
|
|
Cancelled Event: Zephyr Project: Dev Meeting - Thursday, 5 March 2020
#cal-cancelled
devel@lists.zephyrproject.org Calendar <devel@...>
Cancelled: Zephyr Project: Dev Meeting This event has been cancelled. When: Where: Organizer: devel@... Description:
|
|
Carles Cufi
Hi Jamie,
I think those questions were directed to Mayank, who is experiencing the issue now.
Thanks,
Carles
From: devel@... <devel@...>
On Behalf Of lairdjm via Lists.Zephyrproject.Org
Sent: 05 March 2020 14:36 To: Chettimada, Vinayak Kariappa <vinayak.kariappa.chettimada@...>; mayank7117@...; devel@... Cc: devel@... Subject: Re: [Zephyr-devel] hci interface stopped working after few hours #ble #hci #nrf52480 #uart
Hi Vinayak, > Are you using any host debugger firmware to convert to USB? or using 3v TTL connections to your custom board from nRF52840? When I tested it, it was using an nRF52840 PCA10059-like board without a 32KHz crystal (RC was selected from zephyr), I also tried on a BL654 DVK with the 32KHz connected and set in zephyr
> For those using USB_UART conversion, I am assuming you are using Segger JLink firmware on the host chip in the nRF52840 DK/dongle. Could you try using the MBED firmware on the host debugger chip? When I was testing the UART one, I used an FTDI chip so this does not apply. I tested against a BT850 module, which also uses an FTDI with a non-zephyr based HCI module and that worked flawlessly
> Also, please create or refer me to GH issue, so that further discussions can be continued there. I never created an issue. I haven’t tested in probably about a year now or so. Jamie
|
|
Zephyr Toolchain Working Group - Thu, 03/05/2020
#cal-notice
devel@lists.zephyrproject.org Calendar <noreply@...>
Zephyr Toolchain Working Group When: Where: Description: Topic: Zephyr Toolchain Working Group Join Zoom Meeting Meeting ID: 967 549 258 One tap mobile Dial by your location
|
|
Upcoming Event: Zephyr Toolchain Working Group - Thu, 03/05/2020 9:00am-10:00am
#cal-reminder
devel@lists.zephyrproject.org Calendar <devel@...>
Reminder: Zephyr Toolchain Working Group When: Thursday, 5 March 2020, 9:00am to 10:00am, (GMT-06:00) America/Chicago Where:https://zoom.us/j/967549258 Organizer: Maureen Helm Description: Zephyr Working Group is inviting you to a scheduled Zoom meeting. Topic: Zephyr Toolchain Working Group Join Zoom Meeting Meeting ID: 967 549 258 One tap mobile Dial by your location
|
|
Zephyr Toolchain Working Group Meeting – 05 March 2020
Rasmussen, Torsten
Hi All,
For today’s meeting let’s follow up on last meeting action items and get a status update. Also I think we should consider the short / long term goals of this WG and who has the skills / capacity to do what.
Where: Agenda
Also some feedback has been given by Marc since last meeting:
Note: Should be coupled with only checking new / modified files in a PR.
Feel free to send a mail, if you would like additional topics to be discussed.
Best regards
Torsten T. Rasmussen
Live meeting minutes: https://docs.google.com/document/d/1IQKBK-GcJNZG0O9QArqYfvb6Huk5xHscN-XIGEZr-z8/edit#heading=h.x36xe8bnwr9r
|
|
lairdjm
Hi Vinayak, > Are you using any host debugger firmware to convert to USB? or using 3v TTL connections to your custom board from nRF52840? When I tested it, it was using an nRF52840 PCA10059-like board without a 32KHz crystal (RC was selected from zephyr), I also tried on a BL654 DVK with the 32KHz connected and set in zephyr
> For those using USB_UART conversion, I am assuming you are using Segger JLink firmware on the host chip in the nRF52840 DK/dongle. Could you try using the MBED firmware on the host debugger chip? When I was testing the UART one, I used an FTDI chip so this does not apply. I tested against a BT850 module, which also uses an FTDI with a non-zephyr based HCI module and that worked flawlessly
> Also, please create or refer me to GH issue, so that further discussions can be continued there. I never created an issue. I haven’t tested in probably about a year now or so. Jamie
|
|
Chettimada, Vinayak Kariappa
Hi Mayank,
Are you using any host debugger firmware to convert to USB? or using 3v TTL connections to your custom board from nRF52840?
For those using USB_UART conversion, I am assuming you are using Segger JLink firmware on the host chip in the nRF52840 DK/dongle. Could you try using the MBED firmware on the host debugger chip?
Also, please create or refer me to GH issue, so that further discussions can be continued there.
Regards, Vinayak
From: devel@... <devel@...>
On Behalf Of Mayank via Lists.Zephyrproject.Org
Sent: 05 March 2020 13:42 To: devel@... Cc: devel@... Subject: Re: [Zephyr-devel] hci interface stopped working after few hours #ble #hci #nrf52480 #uart
|
|
Re: ILI9340 Display Example
Jan Van Winkel
Hi Muhammad, Note that ili9340 sample has been removed in the latest master as there is now a common sample that support different kind of display shields. Regards, Jan
On Thu, Mar 5, 2020 at 1:03 PM Muhammad Muh <muhammad.muh83@...> wrote:
|
|
Mayank
So does anyone have idea regarding this issue ? I'm using zephyr (Version : 2.1.0) and Bluez (Version : 5.50). Thanks, Mayank
|
|
ILI9340 Display Example
Muhammad Muh <muhammad.muh83@...>
Dear All,
I hope you all are doing well.
I am trying an example in
zephyrproject/zephyr/sample/display/ili9340
The example is building fine with nucleo board
west build -b nucleo_l476rg .
BUT
Please advise on the following error when building with nrf52840 west build -b nrf52840_pca10056 .
FAILED: CMakeFiles/app.dir/src/main.c.obj
ccache /home/muh/zephyr-sdk-0.10.3/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc -DBUILD_VERSION=zephyr-v2.0.0-1364-gbb3cd11bf192 -DKERNEL -DNRF52840_XXAA -D_FORTIFY_SOURCE=2 -D__PROGRAM_START -D__ZEPHYR__=1 -I/home/muh/zephyrproject/zephyr/kernel/include
-I/home/muh/zephyrproject/zephyr/arch/arm/include -I/home/muh/zephyrproject/zephyr/include -I/home/muh/zephyrproject/zephyr/include/drivers -Izephyr/include/generated -I/home/muh/zephyrproject/zephyr/soc/arm/nordic_nrf/nrf52 -I/home/muh/zephyrproject/zephyr/ext/hal/cmsis/Core/Include
-I/home/muh/zephyrproject/modules/hal/nordic/nrfx -I/home/muh/zephyrproject/modules/hal/nordic/nrfx/drivers/include -I/home/muh/zephyrproject/modules/hal/nordic/nrfx/mdk -I/home/muh/zephyrproject/modules/hal/nordic/. -isystem /home/muh/zephyrproject/zephyr/lib/libc/minimal/include
-isystem /home/muh/zephyr-sdk-0.10.3/arm-zephyr-eabi/bin/../lib/gcc/arm-ze
phyr-eabi/8.3.0/include -isystem /home/muh/zephyr-sdk-0.10.3/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/8.3.0/include-fixed -Os -imacros/home/muh/zephyrproject/zephyr/samples/display/ili9340/build/zephyr/include/generated/autoconf.h -ffreestanding
-fno-common -g -mthumb -mcpu=cortex-m4 -imacros/home/muh/zephyrproject/zephyr/include/toolchain/zephyr_stdint.h -Wall -Wformat -Wformat-security -Wno-format-zero-length -Wno-main -Wno-pointer-sign -Wpointer-arith -Wno-unused-but-set-variable -Werror=implicit-int
-fno-asynchronous-unwind-tables -fno-pie -fno-pic -fno-strict-overflow -fno-reorder-functions -fno-defer-pop -fmacro-prefix-map=/home/muh/zephyrproject/zephyr/samples/display/ili9340=CMAKE_SOURCE_DIR -fmacro-prefix-map=/home/muh/zephyrproject/zephyr=ZEPHYR_BASE
-ffunction-sections -fdata-sections -mabi=aapcs -march=armv7e-m -std=c99 -nostdinc -MD -MT CMakeFiles/app.dir/src/main.c.obj -MF CMakeFiles/app.dir/src/main.c.obj.d -o CMakeFiles/app.dir/src/main.c.obj -c ../src/main.c
../src/main.c: In function 'main':
../src/main.c:49:27: error: 'DT_INST_0_ILITEK_ILI9340_LABEL' undeclared (first use in this function); did you mean 'DT_INST_0_JEDEC_SPI_NOR_LABEL'?
dev = device_get_binding(DT_INST_0_ILITEK_ILI9340_LABEL);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
DT_INST_0_JEDEC_SPI_NOR_LABEL
../src/main.c:49:27: note: each undeclared identifier is reported only once for each function it appears in
[4/106] Building C object zephyr/CMake...r/soc/arm/nordic_nrf/nrf52/power.c.obj
ninja: build stopped: subcommand failed.
Regards
|
|
lairdjm
Hi, I’ve previously done testing with the HCI UART and USB sample apps (in older Zephyr versions) with an nRF52840 and linux PC and always found it to not work well. It would start fine, could scan for devices from bluetoothctl and then it just seemed to screw up every time with command timeouts. Never did much digging into why. Thanks, Jamie
> Hi All, > > I'm facing issues regarding ble's hci interface. > I'm having nrf52840 module on which i run zephyr's hci_uart app for beacon scanning. > I have Bluez 5.50 installed on my custom board (imx6ull). > > hci0 interface on my device is "UP RUNNING". So, i'm able to scan the beacons. (My application scans beacons after every 10 seconds). > > Now, When i have put my device for over night testing, then i have observed that after few hours beacon scanning was stopped. > And i'm getting "Bluetooth: hci0 command 0x200b tx timeout" prints after every 5-10 seconds on the console, still the hci0 interface status is "UP RUNNING", but not able to scan the beacons. > > Sometimes also getting the prints like "Bluetooth: hci0: Frame reassembly failed (-84)". > > What could be the reason behind this ? > > Thanks, > Mayank
|
|