Hi Szymon,
I don't think waiting for the NOP before attaching made any difference, but now
I can't remember so I'll have to check that. In any case here is the btmon
output I got during my initial testing:
$ sudo btmon
[sudo] password for alan:
Bluetooth monitor ver 5.41
= Note: Linux version 4.8.0-34-generic (x86_64) 0.977791
= Note: Bluetooth subsystem version 2.21 0.977792
= New Index: 00:00:00:00:00:00 (Primary,UART,hci0) [hci0] 121.060311
= Open Index: 00:00:00:00:00:00 [hci0] 121.066478
< HCI Command: Reset (0x03|0x0003) plen 0 [hci0] 121.070996
= bluetoothd: Bluetooth daemon 5.41 121.092783
= bluetoothd: Starting SDP server 121.104354
= bluetoothd: Bluetooth management interface 1.13 initialized 121.112600
> HCI Event: Command Complete (0x0e) plen 3 [hci0] 126.168513
NOP (0x00|0x0000) ncmd 1
= Close Index: 00:00:00:00:00:00 [hci0] 131.246188
ALan
-----Original Message-----
From: Szymon Janc [mailto:[email protected]]
Sent: Thursday, February 02, 2017 12:18 PM
To: [email protected]
Subject: Re: BLE HCI support on NRF52DK
Hi Alan,
On 2 February 2017 at 19:16, Alan Graves <[email protected]> wrote:
>
> Thanks for rechecking. I know I'm not setup with RTS/CTS handshaking on the
> custom board so that is probably going to be a problem. When I get a chance
> I'll repeat my tests with a complete serial signal set on the nRF52832 DK
> board.
>
> BTW Do you know if Linux assumes hardware flow control by default and if it
> is possible to override that configuration somewhere? I've been caught before
> with hardware flow defaults on PPP over serial on Linux...
btattach has -N, --noflowctl option for disabling flow control. Yet, it is not
recommended for H4 protocol (actually, H4 spec requires flow control to be
enabled).
But I'd first check if simply waiting for few seconds before calling btattach
fix the problem (ie so that Linux sends initial HCI Reset after NOP event was
emitted).
> ALan
>
> -----Original Message-----
> From: Christopher Collins [mailto:[email protected]]
> Sent: Wednesday, February 01, 2017 4:00 PM
> To: [email protected]
> Subject: Re: BLE HCI support on NRF52DK
>
> Hi Alan,
>
> On Wed, Feb 01, 2017 at 11:05:23PM +0000, Alan Graves wrote:
> > Hi,
> >
> > I've spent some time trying to get nRF52832 DK running the 'blehci' code
> > communicating with Xubuntu 16.10 (under VMware) with not much luck.
>
> I just ran the latest blehci from develop with the following setup:
>
> * BlueZ 5.39
> * Ubuntu 16.04 (Xenial)
> * nRF52832 DK
>
> I didn't notice any issues when I tried. I'm afraid I don't see anything
> wrong with the steps you follows. Maybe one of the following hints will help:
>
> * Make sure the two flow control pins (RTS / CTS) are attached.
>
> * Try killing btattach and restarting it. When you do this, you should
> see BlueZ send the host init sequence in btmon (starting with a Reset
> command).
>
> The btattach step is required because the BlueZ host doesn't seem to
> interpret the no-op event as a controller reset. You have to explicitly tell
> the host to reset the controller.
>
> Hopefully this gets you a little closer to a solution. If you're still
> seeing the same issue, just let me know and we can debug it further.
>
> Thanks,
> Chris
--
pozdrawiam
Szymon K. Janc