summaryrefslogtreecommitdiff
path: root/emulator/main.c
Commit message (Collapse)AuthorAgeFilesLines
* emulator: Add support for vendor commandsLuiz Augusto von Dentz2022-01-051-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds support for vendor commands reserving a single opcode (0xfc10) so it can be extended using subcommands, similar to how MSFT works. The first subcommand (0x00) enables the emulator to generate arbitrary events using the commands parameters: > tools/hcitool cmd 3f 10 00 22 24 d0 d0 d0 d0 d0 d0 ff ff < HCI Command: Vendor (0x3f|0x0010) plen 11 00 22 24 d0 d0 d0 d0 d0 d0 ff ff ."$........ Bluetooth: hci0: Malformed HCI Event: 0x22 > HCI Event: Inquiry Result with R.. (0x22) plen 9 Num responses: 36 Page scan repetition mode: Reserved (0xff) Page period mode: Reserved (0xff) Class: 0xffffd0 Major class: Uncategorized, specific device code not specified Minor class: 0x34 Limited Discoverable Mode invalid service class Clock offset: 0x6368 RSSI: 105 dBm (0x69) > HCI Event: Command Complete (0x0e) plen 4 Vendor (0x3f|0x0010) ncmd 1 Status: Success (0x00)
* emulator: Add initial support for MSFT vendor commandsLuiz Augusto von Dentz2021-10-211-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds the initial support for MSFT vendor commands and enable them when in btvirt: < HCI Command: Microsoft Ex.. (0x3f|0x001e) plen 1 Read Supported Features (0x00) > HCI Event: Command Complete (0x0e) plen 14 Microsoft Extension (0x3f|0x001e) ncmd 1 Read Supported Features (0x00) Status: Success (0x00) Features: 0x3f 0x00 0x00 0x00 0x00 0x00 0x00 0x00 RSSI Monitoring feature for BR/EDR RSSI Monitoring feature for LE connections RSSI Monitoring of LE advertisements Advertising Monitoring of LE advertisements Verifying the validity of P-192 and P-256 keys Continuous Advertising Monitoring Event prefix length: 0 Event prefix: < HCI Command: Microsoft Ex.. (0x3f|0x001e) plen 2 LE Set Advertisement Filter Enable (0x05) Enable: All filter conditions (0x01) > HCI Event: Command Complete (0x0e) plen 5 Microsoft Extension (0x3f|0x001e) ncmd 1 LE Set Advertisement Filter Enable (0x05) Status: Success (0x00)
* vhci: Read the controller indexLuiz Augusto von Dentz2021-10-181-5/+7
| | | | | | This makes vhci instance read its controller index assigned by the kernel and also introduces vhci_get_btdev so it can be used by the likes of hciemu.
* emulator: Add option for enabling debug with btvirtLuiz Augusto von Dentz2021-02-191-1/+19
| | | | | This adds -d/--debug options which enables debug of vhci instance on btvirt.
* emulator: Add SPDX License IdentifierTedd Ho-Jeong An2020-09-211-14/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds SPDX License Identifier and removes the license text. ------------------------------------- License COUNT ------------------------------------- LGPL-2.1-or-later : 20 GPL-2.0-or-later : 2 License: LGPL-2.1-or-later emulator/server.c emulator/amp.c emulator/hciemu.c emulator/vhci.c emulator/btdev.c emulator/serial.h emulator/le.h emulator/le.c emulator/main.c emulator/amp.h emulator/hciemu.h emulator/bthost.h emulator/btdev.h emulator/vhci.h emulator/serial.c emulator/phy.c emulator/smp.c emulator/phy.h emulator/bthost.c emulator/server.h License: GPL-2.0-or-later emulator/b1ee.c emulator/hfp.c
* emulator: Fix command line parameters with optional argumentOlivier Martin2020-04-151-2/+4
| | | | | Some parameters were missing the indication that additional argument could be expected.
* shared/mainloop: Remove mainloop_set_signalLuiz Augusto von Dentz2018-12-051-8/+1
| | | | | This removes mainloop_set_signal and replaces it usage with mainloop_run_with_signal.
* shared: Move mainloop implementation from monitor to sharedJohan Hedberg2015-02-121-1/+1
|
* emulator: Add support for providing a pseudo terminalMarcel Holtmann2014-07-121-2/+17
|
* emulator: Update copyright and license detailsMarcel Holtmann2014-02-121-10/+10
|
* emulator: Add simple standalone single mode LE deviceMarcel Holtmann2013-12-281-2/+23
|
* emulator: Add support for AMP controller emulationMarcel Holtmann2013-10-091-3/+23
|
* emulator: Add some extra long option stringsMarcel Holtmann2013-10-051-1/+5
|
* emulator: Make unix server sockets optionalMarcel Holtmann2013-10-051-20/+36
|
* emulator: Exit with failure when Virtual HCI setup failsMarcel Holtmann2013-10-051-1/+3
|
* emulator: Add command line option for AMP controllersMarcel Holtmann2013-10-051-1/+5
|
* emulator: Add options to usage descriptionMarcel Holtmann2013-09-101-0/+3
|
* emulator: Allow multiple vhci adapter creation with btvirtJohan Hedberg2013-03-071-7/+11
|
* emulator: Add command line options for selecting controller type to btvirtJohan Hedberg2013-01-311-2/+9
|
* emulator: Use BR/EDR/LE vhci type as default for btvirtJohan Hedberg2013-01-311-1/+1
|
* emulator: Create separate server BR/EDR/LE and BR/EDR typesJohan Hedberg2013-01-311-7/+13
|
* emulator: Add command line switch for local HCI virtual deviceMarcel Holtmann2013-01-131-4/+12
|
* Revert "Ensure config.h is included by using CPPFLAGS"Johan Hedberg2012-12-071-0/+4
| | | | | | | | | | | | | | This reverts commit 8a03376544b046a84301847d1594f6c3674983ff. The patch needs to be split up and the gdbus/ changes were bogus compared to the original commit message. Conflicts: Makefile.am Makefile.obexd profiles/cyclingspeed/cyclingspeed.c profiles/heartrate/heartrate.c src/error.c
* Ensure config.h is included by using CPPFLAGSLucas De Marchi2012-12-051-4/+0
| | | | | | | | | | Instead of trying to include config.h in each file over the tree and possibly forgetting to include it, give a "-include config.h" argument to the compiler so it's guaranteed that a) it will be included for all source files and b) it will be the first header included. gdbus/ directory is left out, since it would break other projects using it.
* emulator: Add handling for monitor server instanceMarcel Holtmann2012-11-271-0/+5
|
* build: Remove stupid -I directivesMarcel Holtmann2012-11-201-1/+1
|
* emulator: Create server channel for LE only deviceMarcel Holtmann2012-11-131-1/+6
|
* emulator: Add version and usage informationMarcel Holtmann2012-10-301-0/+38
|
* emulator: Create support for enabling AMP controllersMarcel Holtmann2012-10-291-5/+10
|
* emulator: Ignore failures for device transportsMarcel Holtmann2012-10-291-7/+2
|
* emulator: Add initial version of new emulatorMarcel Holtmann2012-02-271-0/+73