Scan error Invalid HCI Command Parameters
when attempting to scan I get a Invalid HCI Command Parameters error. However if I run bluetoothctl scan on the scanner starts working. It appears that there is some command being sent by bluetoothctl to turn on the scanner that the software is not performing.
When I use bemoan to watch what is happening when scanning with the command parameters error I see the following looping over as the app keeps trying and failing to scan.
`> HCI Event: Command Complete (0x0e) plen 4 [hci0] 2.144296 LE Set Scan Enable (0x08|0x000c) ncmd 1 Status: Invalid HCI Command Parameters (0x12) < HCI Command: Disconnect (0x01|0x0006) plen 3 [hci0] 2.145767 Handle: 0 Reason: Connection Terminated By Local Host (0x16)
HCI Event: Command Status (0x0f) plen 4 [hci0] 2.146661 Disconnect (0x01|0x0006) ncmd 1 Status: Command Disallowed (0x0c) `
When I watch the scanner start after using bluetoothctl scan on command I get the following.
`HCI Command: Disconnect (0x01|0x0006) plen 3 [hci0] 50.286713 Handle: 0 Reason: Connection Terminated By Local Host (0x16)
HCI Event: Command Status (0x0f) plen 4 [hci0] 50.287760 Disconnect (0x01|0x0006) ncmd 1 Status: Command Disallowed (0x0c) @ MGMT Command: Start Discovery (0x0023) plen 1 {0x0001} [hci0] 50.577471 Address type: 0x07 BR/EDR LE Public LE Random < HCI Command: LE Set Random Address (0x08|0x0005) plen 6 [hci0] 50.577599 Address: 01:54:A4:10:93:EA (Non-Resolvable) HCI Event: Command Complete (0x0e) plen 4 [hci0] 50.582053 LE Set Random Address (0x08|0x0005) ncmd 1 Status: Success (0x00) < HCI Command: LE Set Scan Parameters (0x08|0x000b) plen 7 [hci0] 50.582150 Type: Active (0x01) Interval: 11.250 msec (0x0012) Window: 11.250 msec (0x0012) Own address type: Random (0x01) Filter policy: Accept all advertisement (0x00) HCI Event: Command Complete (0x0e) plen 4 [hci0] 50.584337 LE Set Scan Parameters (0x08|0x000b) ncmd 1 Status: Success (0x00) < HCI Command: LE Set Scan Enable (0x08|0x000c) plen 2 [hci0] 50.584425 Scanning: Enabled (0x01) Filter duplicates: Enabled (0x01) HCI Event: Command Complete (0x0e) plen 4 [hci0] 50.588154 LE Set Scan Enable (0x08|0x000c) ncmd 1 Status: Success (0x00) @ MGMT Event: Command Complete (0x0001) plen 4 {0x0001} [hci0] 50.588270 Start Discovery (0x0023) plen 1 Status: Success (0x00) Address type: 0x07 BR/EDR LE Public LE Random @ MGMT Event: Discovering (0x0013) plen 2 {0x0002} [hci0] 50.588295 Address type: 0x07 BR/EDR LE Public LE Random Discovery: Enabled (0x01) `