summaryrefslogtreecommitdiffstats
path: root/scripts
Commit message (Collapse)AuthorAgeFilesLines
* scripts/run-*-example.sh: Set kernel core pattern, to be sure of name and ↵Sven Gothel2021-11-022-0/+2
| | | | location (current dir) of core file.
* Adding blues-btreset.sh: Reset and 'disable' one or more adapter ..Sven Gothel2021-10-291-0/+14
|
* Add BTAdapter's Slave Peripheral SMP Key ManagementSven Gothel2021-10-291-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To have full SMP key persitency in peripheral slave mode, BTAdapter requires fine grained control over - Passing stored keys to BTDevice's PairingData (w/o uploading them) - Uploading BTDevice's PairingData to the adapter This required interaction in certain places, only enabled if adapter is BTRole::Slave (peripheral): - BTAdapter::mgmtEvDeviceConnectedHCI() Only issue unpairDevice() if not pre-paired. Unpairing is required for new pairing to avoid DHKey Check failures! - BTAdapter::mgmtEvDeviceDisconnectedHCI() - First unpairDevice() will be issued via notifyDisconnect() - Set and upload stored keys for disconnected device (if existing), preparing for next connect. - BTAdapter::sendDevicePairingState() - SMPPairingState::COMPLETED && not SMPPairingState::PRE_PAIRED: Store keys - SMPPairingState::COMPLETED && SMPPairingState::PRE_PAIRED: Refresh keys to BTDevice (set), no upload! - SMPPairingState::FAILED: Remove and delete keys +++ BTAdapter::setSMPKeyPath(path) allows user to enable the persistent key storage by setting its local filesystem path. It will also read all key files (SMPKeyBin) and if valid and matching with the adapter, uploads them for pre-pairing. See dbt_peripheral00.cpp: adapter->setSMPKeyPath(ADAPTER_KEY_PATH); +++
* scripts/run-native-example.sh: Enforce using bash to preserve command-line ↵Sven Gothel2021-09-291-14/+21
| | | | quotes
* scripts/run-java-scanner10.sh: Removed (missed in previous unified launch ↵Sven Gothel2021-09-271-133/+0
| | | | script commit)
* Examples: Build using a set of idiomatic names, one recipe for each ↵Sven Gothel2021-09-272-2/+0
| | | | examples; Add jar install for example/java!
* Add build-cross.sh using chroot to target system (from my pi-gen work, using ↵Sven Gothel2021-09-262-0/+95
| | | | images also build by our pi-gen branch)
* scripts/run*: Unify launch scripts using single defintion and symbolic links ↵Sven Gothel2021-09-2611-454/+194
| | | | with definite name
* Moved EUI48, EUI48Sub (C++/Java) and uuid_t, *Octets (C++) to jaulib for ↵Sven Gothel2021-09-181-1/+1
| | | | | | | | | general use. Notable, the java classes EUI48, EUI48Sub and BasicTypes are included in direct_bt's jar file to avoid any inconvenience. Hence BTUtils's byte[s]HexString(..) simply uses jaulib's BasicTypes s' implementation.
* Add advertising support (start with set-data and -params, stop) via HCIHandlerSven Gothel2021-09-152-0/+269
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reasonable default values have been chosen from the BT spec, which can be overriden using the HCIHandler and BTAdapter operations. The extended advertising operations are also supported (Bluetooth 5.0). +++ Successfully tested running: (0) Test machine with 2 adapter - adapter-1 DC:FB:48:00:90:19 (acting as client) - adapter-2 00:1A:7D:DA:71:08 (acting as peripheral) (1) Running dbt_peripheral00.cpp or DBTPeripheral.java as the advertising peripheral on the test machine. `direct_bt/dist-amd64$ ../scripts/run-dbt_peripheral00.sh -adapter 00:1A:7D:DA:71:08` or `direct_bt/dist-amd64$ ../scripts/run-java-peripheral00.sh -adapter 00:1A:7D:DA:71:08` (2) Running dbt_scanner10.cpp or DBTScanner10.java as the listeninig and connection-initiator client on the same test machine. `direct_bt/dist-amd64$ sh ../scripts/run-dbt_scanner10.sh -adapter DC:FB:48:00:90:19 -dev 00:1A:7D:DA:71:08 -seclevel 00:1A:7D:DA:71:08 1` or `direct_bt/dist-amd64$ sh ../scripts/run-java-scanner10.sh -adapter DC:FB:48:00:90:19 -dev 00:1A:7D:DA:71:08 -seclevel 00:1A:7D:DA:71:08 1`
* scripts/run-dbt_scanner10.sh: Fix '-root' launchSven Gothel2021-09-031-1/+1
|
* Direct-BT: Remove TinyB and Cleanup Java API (1)Sven Gothel2021-08-311-1/+0
| | | | | | | | | | | | | | | | | | Starting with version 2.3, the previously refactored *TinyB* has been removed completely. Motivation was lack of detailed Bluetooth support, inclusive increasing diversion with *Direct-BT*. Furthermore, work is underway for `BLE slave periphal and GATT server` support and its mapping to *BlueZ D-Bus* is questionable and would be resource intensive. Java API changed as follows: - Objects no more Clonable - Removed dead unsupported code - Removed deprecated code - Added 'GattCharPropertySet', representing property bit mask for BTGattChar, replacing the string array.
* Add support for Bluetooth 5.0 Adapter (using HCI extended scanning and ↵Sven Gothel2021-08-301-0/+2
| | | | | | | | | connecting if supported) On Bluetooth 5.0 Adapter where HCI extended scanning and connecting is suppored, the original HCI commands may fail via DISALLOWED. Tested adapter: Intel AX200 Bluetooth 5.0 (Wi-Fi 6 802.11ax (2.4Gbps) + BT 5.0)
* run-[dbt_|java-]scanner10.sh: Add [-setcap, -root] launch options, update ↵Sven Gothel2021-08-112-49/+147
| | | | setcap/capsh; README: Clean MD; Refine Direct-BT application launch options
* dbt_scanner10/DBTScanner10: Extract BTDeviceRegistry and BTSecurityRegistry ↵Sven Gothel2021-07-311-4/+10
| | | | | | | | | | | | | | to lib, support full EUI84Sub and name-sub pattern matching Same naming-schema and functionality C++/Java Due to using EUI48Sub and name-sub pattern matching, we naturally had to drop the hash-set fast-lookup approach. However, looking up device names via pattern-matching is essential to handle device groups, i.e. - specific security settings (level, passkey, ..) - actually accepting them to connect (waitForDevices)
* Clarify EInfoReport ownership between MgmtEvtDeviceFound, HCIHandler and ↵Sven Gothel2021-07-271-5/+18
| | | | | | | | | | | | | | | BTAdapter; Add AD_EIR debug flag MgmtEvtDeviceFound changes: Stringent ownership - field eireport type `std::shared_ptr<EInfoReport>` -> `std::unique_ptr<EInfoReport>` - getEIR() returns immutable EInfoReport pointer BTAdapter::mgmtEvDeviceFoundHCI(): Cleanup confusion - Expect coming from HCIHandler (we only listen to it), ABORT otherwise - Cleanup confusion of ownership etc Debug: - HCIHandler env.DEBUG_SCAN_AD_EIR `direct_bt.debug.hci.scan_ad_eir`
* test_java.sh: Fix jar name usedSven Gothel2021-07-271-5/+6
|
* scripts/run-java-scanner10.sh: Add 'JAVA_PROPS' var to allow passing Java ↵v2.2.7Sven Gothel2021-06-151-1/+3
| | | | properties.
* add script/*.sh for native testsSven Gothel2021-01-294-0/+77
|
* locale: Add LC_ALL and hint to set system (testing requires proper unified ↵Sven Gothel2021-01-299-18/+36
| | | | setup)
* Revert to gcc as default since clang < 10 has issues on 32bit arm (raspi3 setup)Sven Gothel2021-01-281-1/+1
|
* cmake/build/test: Ensure UTF8 is used by system, set LANG to 'en_US.UTF-8' ↵Sven Gothel2021-01-283-0/+12
| | | | to have a unified environment
* Enhance Scanner10's MyLongTermKeyInfo (C++/Java): Store BTSecurityLevel and ↵Sven Gothel2021-01-282-0/+4
| | | | | | | | | SMPIOCapability setting to be self-contained un reusage. Also - store keys in own path - determine filename within class - validate BTSecurityLevel as well
* scripts/run-java-scanner10.sh: Remove jni debugging, oopsSven Gothel2021-01-261-2/+2
|
* Complete build change: Using jaulib[_fat] if available (for Java) incl. ↵Sven Gothel2021-01-252-2/+54
| | | | native lib loading. Added junit test facility (Java).
* Java: New API Layout: Shorten named [Bluetooth -> BT], [Characteristic -> ↵Sven Gothel2021-01-254-13/+14
| | | | Char] etc (align naming with direct_bt == java; reduce java code footprint and too long code lines)
* Update run-dbt_scanner10.sh (just naming..)Sven Gothel2021-01-111-8/+9
|
* Replace std::vector w/ jau::darray: Adapt JNI methodsSven Gothel2021-01-111-2/+2
|
* valgrind.supp: Add Catch to suppressed stacksSven Gothel2021-01-111-0/+8
|
* cmake: Disable RTTI (-fno-rtti) for now, ensuring no side-effects; Adding ↵Sven Gothel2021-01-051-1/+4
| | | | GPROF and PERF_ANALYSIS 'tags' to build with gprof or just '-O3 -g -ggdb' (callgrind)
* Move jaucpp -> jaulib; Full integration of jaulib's unit tests (TODO: Use ↵Sven Gothel2020-12-211-0/+44
| | | | | | | Catch2 for own unit tests) Also: cmake: Add "null-dereference" to NO_ERROR, as it causes trouble with jau::get_uint8(..) with "-O3" See jaulib commit db34007f905dab9feeba16e95c16d84bfb0ff11a
* scripts/run*sh: Use ${USER} environment variable instead of hardcoded name ;-)Sven Gothel2020-12-032-4/+4
|
* scripts/run-*-scanner10.sh: Have capsh user being configured and include ↵Sven Gothel2020-10-272-4/+8
| | | | 'ulimit -c unlimited' in capsh'ed execution for core dumps
* Document Direct-BT Non-Root Usage via setcap or preferrably capsh.Sven Gothel2020-10-272-4/+39
|
* Add ChangedAdapterSetCallback (C++), ChangedAdapterSetListener (Java) for ↵Sven Gothel2020-10-251-0/+4
| | | | [DBT|Bluetooth]Manager, enabling fully event driven workflow w/ adapter add/remove
* Update valgrind.suppSven Gothel2020-10-221-5/+46
|
* cmake: Expose different instrumentation (-fsanitize=) modulesSven Gothel2020-10-211-0/+2
|
* run-dbt-scanner10: Use export for VALGRIND invocation macroSven Gothel2020-10-191-4/+4
|
* Update valgrind.supp fileSven Gothel2020-10-191-71/+115
|
* Build: Separate GCC sanitize flags from DEBUG=ON, enable via INSTRUMENTATION=ONSven Gothel2020-10-181-0/+1
|
* Align run-java-scanner10.sh with run-dbt-scanner10.sh scriptSven Gothel2020-10-142-8/+41
|
* run-dbt-scanner10.sh: Added current valgrind (memcheck, drd and callgrind) ↵Sven Gothel2020-10-091-11/+37
| | | | | | commented-out options Example with callgrind enabled: "../scripts/run-dbt_scanner10.sh -log ~/dbt_scanner10-arm64-30 -dev_id 1 -disconnect -count 1 -Ndebug -dbt_debug false -quiet -mac C0:26:DA:01:DA:B1 -mac C0:26:DF:01:E5:CA -mac C0:26:DA:00:03:DC -mac C0:26:DA:05:EF:5B"
* valgrind.supp: Add DRD suppressions equivalent to Helgrind (No errors)Sven Gothel2020-10-091-1/+210
|
* helgrind suppressions file: 0 errors (from initial 3716)Sven Gothel2020-10-082-3/+21
| | | | | | | | | | | | | Note on completion.. Most reported issues were due to helgrind's lack of analyzing the atomic macros used in C++ atomic<T>. Most issues related to 'direct_bt::LFRingbuffer::*', utilizing SC-DRF atomic acquire (read) and release (write) not detected by helgrind. This mechanism is well tested, see unit test test_mm_sc_drf (passed). However, we have fixed around 6 issues - mostly lock order related.
* helgrind suppressions file added: 10 errors left (from 3716), analyzed and ↵Sven Gothel2020-10-083-0/+370
| | | | | | suppressed - or - fixed Also adding the suppression extraction scripts from <https://wiki.wxwidgets.org/Parse_valgrind_suppressions.sh>
* run-java-scanner10.sh: Add uncommented check:jni and valgrind variantsSven Gothel2020-09-301-1/+5
|
* scripts/build.sh: Add commented out CLANG_ARGS (documentation, convenience)Sven Gothel2020-09-301-2/+3
|
* run-dbt-scanner10.sh: Add commented out VALGRIND optionSven Gothel2020-09-291-1/+4
|
* Adding kernel-bt-[debug|reload].sh scriptsSven Gothel2020-09-252-0/+41
|
* Java Example: Rename ScannerTinyB10 -> DBTScanner10: Requiring Direct-BT, ↵Sven Gothel2020-09-251-2/+2
| | | | name aligned with dbt_scanner10.cpp