@mentra/bluetooth-sdk 3.4.0-dev.1208 → 3.4.0-dev.1209

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/android/src/main/java/com/mentra/bluetoothsdk/DeviceManager.kt +2 -16
  2. package/android/src/main/java/com/mentra/bluetoothsdk/GeneratedReleaseMetadata.kt +5 -5
  3. package/android/src/main/java/com/mentra/bluetoothsdk/MentraBluetoothSdk.kt +2 -9
  4. package/android/src/main/java/com/mentra/bluetoothsdk/sgcs/Nimo.kt +13 -316
  5. package/android/src/main/java/com/mentra/bluetoothsdk/sgcs/NimoCanvasCoordinator.kt +0 -35
  6. package/android/src/main/java/com/mentra/bluetoothsdk/sgcs/NimoCanvasSession.kt +2 -10
  7. package/android/src/test/java/com/mentra/bluetoothsdk/sgcs/NimoCanvasCoordinatorTest.kt +1 -56
  8. package/android/src/test/java/com/mentra/bluetoothsdk/sgcs/NimoCanvasSessionTest.kt +0 -22
  9. package/build/_private/BluetoothSdkModule.d.ts +0 -3
  10. package/build/_private/BluetoothSdkModule.d.ts.map +1 -1
  11. package/build/_private/BluetoothSdkModule.js.map +1 -1
  12. package/build/generated/releaseMetadata.js +5 -5
  13. package/build/generated/releaseMetadata.js.map +1 -1
  14. package/ios/BluetoothSdkModule.swift +0 -6
  15. package/ios/Source/BluetoothSdkDefaults.swift +1 -1
  16. package/ios/Source/DeviceManager.swift +1 -10
  17. package/ios/Source/GeneratedReleaseMetadata.swift +5 -5
  18. package/ios/Source/MentraBluetoothSDK.swift +2 -15
  19. package/ios/Source/sgcs/Nimo.swift +39 -272
  20. package/ios/Source/sgcs/NimoCanvasCoordinator.swift +9 -38
  21. package/ios/Source/sgcs/NimoCanvasSession.swift +0 -1
  22. package/ios/Tests/DeviceManagerReconnectTests.swift +0 -71
  23. package/ios/Tests/NimoCanvasTransportTests.swift +0 -89
  24. package/package.json +2 -2
  25. package/src/_private/BluetoothSdkModule.ts +0 -3
  26. package/src/generated/releaseMetadata.ts +5 -5
  27. package/android/src/debug/java/com/mentra/bluetoothsdk/sgcs/NimoDiagnostics.kt +0 -368
  28. package/android/src/debug/java/com/mentra/bluetoothsdk/sgcs/NimoFramebufferProtocol.kt +0 -156
  29. package/android/src/debug/java/com/mentra/bluetoothsdk/sgcs/NimoResourceDiagnostics.kt +0 -274
  30. package/android/src/release/java/com/mentra/bluetoothsdk/sgcs/NimoDiagnostics.kt +0 -20
  31. package/android/src/release/java/com/mentra/bluetoothsdk/sgcs/NimoResourceDiagnostics.kt +0 -16
  32. package/android/src/testDebug/java/com/mentra/bluetoothsdk/sgcs/NimoDiagnosticsTest.kt +0 -287
  33. package/android/src/testDebug/java/com/mentra/bluetoothsdk/sgcs/NimoFramebufferProtocolTest.kt +0 -127
  34. package/android/src/testDebug/java/com/mentra/bluetoothsdk/sgcs/NimoLifecycleTest.kt +0 -851
  35. package/ios/Source/sgcs/NimoMacResourceTransport.swift +0 -217
  36. package/ios/Source/sgcs/NimoResourceFixture.swift +0 -384
  37. package/ios/Source/sgcs/NimoResourceSession.swift +0 -406
  38. package/ios/Tests/NimoResourceSessionTests.swift +0 -476
@@ -26,7 +26,6 @@ import com.mentra.bluetoothsdk.sgcs.MentraLive
26
26
  import com.mentra.bluetoothsdk.sgcs.MentraLivePairingStateStore
27
27
  import com.mentra.bluetoothsdk.sgcs.MentraNex
28
28
  import com.mentra.bluetoothsdk.sgcs.Nimo
29
- import com.mentra.bluetoothsdk.sgcs.NimoResourceDiagnostics
30
29
  import com.mentra.bluetoothsdk.sgcs.SGCManager
31
30
  import com.mentra.bluetoothsdk.sgcs.Simulated
32
31
  import com.mentra.bluetoothsdk.utils.ControllerTypes
@@ -317,7 +316,6 @@ class DeviceManager internal constructor(initializeHardware: Boolean) {
317
316
  initializeViewStates()
318
317
  if (initializeHardware) {
319
318
  initializeHardwareServices()
320
- NimoResourceDiagnostics.start(Bridge.getContext())
321
319
  }
322
320
  }
323
321
 
@@ -1359,7 +1357,6 @@ class DeviceManager internal constructor(initializeHardware: Boolean) {
1359
1357
  // MARK: - Auxiliary Commands
1360
1358
 
1361
1359
  fun initSGC(wearable: String) {
1362
- if (!NimoResourceDiagnostics.allowManagerConnect(wearable)) return
1363
1360
  Bridge.log("Initializing manager for wearable: $wearable")
1364
1361
  if (sgc != null && sgc?.type != wearable) {
1365
1362
  Bridge.log("MAN: Manager already initialized, cleaning up previous sgc")
@@ -2378,7 +2375,6 @@ class DeviceManager internal constructor(initializeHardware: Boolean) {
2378
2375
  }
2379
2376
 
2380
2377
  fun connectDefault() {
2381
- if (NimoResourceDiagnostics.dispatchCapturedEntry { connectDefault() }) return
2382
2378
  if (defaultWearable.isEmpty()) {
2383
2379
  Bridge.log("MAN: No default wearable, returning")
2384
2380
  return
@@ -2400,7 +2396,6 @@ class DeviceManager internal constructor(initializeHardware: Boolean) {
2400
2396
  Bridge.log("MAN: connectDefault skipped — bluetooth runtime permissions not granted")
2401
2397
  return
2402
2398
  }
2403
- if (!NimoResourceDiagnostics.allowManagerConnect(defaultWearable, reconnectTarget)) return
2404
2399
  initSGC(defaultWearable)
2405
2400
  val live = sgc as? MentraLive
2406
2401
  if (live != null && MentraLivePairingStateStore.isRejected) {
@@ -2437,7 +2432,6 @@ class DeviceManager internal constructor(initializeHardware: Boolean) {
2437
2432
  }
2438
2433
 
2439
2434
  fun connectByName(dName: String) {
2440
- if (NimoResourceDiagnostics.dispatchCapturedEntry { connectByName(dName) }) return
2441
2435
  Bridge.log("MAN: Connecting to wearable: $dName")
2442
2436
 
2443
2437
  var name = dName
@@ -2452,7 +2446,6 @@ class DeviceManager internal constructor(initializeHardware: Boolean) {
2452
2446
  return
2453
2447
  }
2454
2448
 
2455
- if (!NimoResourceDiagnostics.allowManagerConnect(pendingWearable.ifEmpty { defaultWearable }, name)) return
2456
2449
  if (pendingWearable.isEmpty() && !defaultWearable.isEmpty()) {
2457
2450
  Bridge.log("MAN: No pending wearable, using default wearable")
2458
2451
  pendingWearable = defaultWearable
@@ -2467,11 +2460,8 @@ class DeviceManager internal constructor(initializeHardware: Boolean) {
2467
2460
  return
2468
2461
  }
2469
2462
 
2470
- if (!NimoResourceDiagnostics.allowManagerConnect(pendingWearable, name)) return
2471
- if (!NimoResourceDiagnostics.preserveCapturedScan(pendingWearable, name)) {
2472
- disconnect(clearPendingIdentity = false)
2473
- Thread.sleep(100)
2474
- }
2463
+ disconnect(clearPendingIdentity = false)
2464
+ Thread.sleep(100)
2475
2465
  searching = true
2476
2466
  pendingDeviceName = name
2477
2467
 
@@ -2480,10 +2470,8 @@ class DeviceManager internal constructor(initializeHardware: Boolean) {
2480
2470
  }
2481
2471
 
2482
2472
  fun connectDevice(deviceModel: String, deviceName: String) {
2483
- if (NimoResourceDiagnostics.dispatchCapturedEntry { connectDevice(deviceModel, deviceName) }) return
2484
2473
  Bridge.log("MAN: Connecting to device: $deviceModel $deviceName")
2485
2474
  if (DeviceTypes.ALL.contains(deviceModel)) {
2486
- if (!NimoResourceDiagnostics.allowManagerConnect(deviceModel, deviceName)) return
2487
2475
  pendingWearable = deviceModel
2488
2476
  initSGC(pendingWearable)
2489
2477
  sgc?.connectById(deviceName)
@@ -2689,8 +2677,6 @@ class DeviceManager internal constructor(initializeHardware: Boolean) {
2689
2677
  }
2690
2678
 
2691
2679
  fun findCompatibleDevices(deviceModel: String) {
2692
- if (NimoResourceDiagnostics.dispatchCapturedEntry { findCompatibleDevices(deviceModel) }) return
2693
- if (!NimoResourceDiagnostics.allowManagerConnect(deviceModel)) return
2694
2680
  Bridge.log("MAN: Searching for compatible device names for: $deviceModel")
2695
2681
 
2696
2682
  // reset the search results:
@@ -3,9 +3,9 @@ package com.mentra.bluetoothsdk
3
3
  /** Generated by release CI. Do not edit in a release checkout. */
4
4
  internal object GeneratedReleaseMetadata {
5
5
  const val FAMILY_BASE_VERSION: String = "3.4.0"
6
- const val RELEASE_IDENTITY: String = "3.4.0-dev.1208"
7
- const val RELEASE_SET_ID: String = "mentra-3.4.0-dev.1208"
8
- const val SOURCE_COMMIT: String = "8eba34ecbad37d513d6ec0cac4cf18990275245b"
9
- const val OTA_MANIFEST_URL: String = "https://artifactscdn.mentraglass.com/Mentra-Community/MentraOS/releases/mentra-builds-v3.4.0/mentra-live-ota-3.4.0-dev.1208.json"
10
- const val OTA_MANIFEST_SHA256: String = "c7e80329f56c6db864a30938a1031803714a0a4316d1b2e0ae72fa9e52d7fd6a"
6
+ const val RELEASE_IDENTITY: String = "3.4.0-dev.1209"
7
+ const val RELEASE_SET_ID: String = "mentra-3.4.0-dev.1209"
8
+ const val SOURCE_COMMIT: String = "1f73b5402e1a0b5f06000b84300695f0dfc879c1"
9
+ const val OTA_MANIFEST_URL: String = "https://artifactscdn.mentraglass.com/Mentra-Community/MentraOS/releases/mentra-builds-v3.4.0/mentra-live-ota-3.4.0-dev.1209.json"
10
+ const val OTA_MANIFEST_SHA256: String = "f93b7fed880136625a8b29c4e74210e882b5322bd79f76aa84d79a31bb95b82a"
11
11
  }
@@ -10,7 +10,6 @@ import android.os.Handler
10
10
  import android.os.Looper
11
11
  import android.util.Log
12
12
  import com.mentra.bluetoothsdk.sgcs.MentraLive
13
- import com.mentra.bluetoothsdk.sgcs.NimoResourceDiagnostics
14
13
  import com.mentra.bluetoothsdk.streaming.StreamSessionState
15
14
  import com.mentra.bluetoothsdk.utils.ControllerTypes
16
15
  import com.mentra.bluetoothsdk.utils.PhoneAudioMonitor
@@ -368,8 +367,6 @@ class MentraBluetoothSdk private constructor(
368
367
  }
369
368
 
370
369
  fun startScan(model: DeviceModel) {
371
- if (NimoResourceDiagnostics.dispatchCapturedEntry { startScan(model) }) return
372
- if (!NimoResourceDiagnostics.allowManagerConnect(model.deviceType)) return
373
370
  if (model != DeviceModel.SIMULATED) {
374
371
  requireBluetoothReady("scan for glasses")
375
372
  }
@@ -476,13 +473,11 @@ class MentraBluetoothSdk private constructor(
476
473
 
477
474
  @JvmOverloads
478
475
  fun connect(device: Device, options: ConnectOptions = ConnectOptions()) {
479
- if (NimoResourceDiagnostics.dispatchCapturedEntry { connect(device, options) }) return
480
- if (!NimoResourceDiagnostics.allowManagerConnect(device.model.deviceType, device.name)) return
481
476
  if (device.model != DeviceModel.SIMULATED) {
482
477
  requireBluetoothReady("connect to glasses")
483
478
  }
484
479
  val isController = ControllerTypes.ALL.contains(device.model.deviceType)
485
- if (options.cancelExistingConnectionAttempt && !NimoResourceDiagnostics.preserveCapturedScan(device.model.deviceType, device.name)) {
480
+ if (options.cancelExistingConnectionAttempt) {
486
481
  if (isController) {
487
482
  deviceManager.disconnectController()
488
483
  } else {
@@ -519,18 +514,16 @@ class MentraBluetoothSdk private constructor(
519
514
 
520
515
  @JvmOverloads
521
516
  fun connectDefault(options: ConnectOptions = ConnectOptions()) {
522
- if (NimoResourceDiagnostics.dispatchCapturedEntry { connectDefault(options) }) return
523
517
  val defaultDevice =
524
518
  currentDefaultDevice()
525
519
  ?: throw BluetoothSdkException(
526
520
  "default_device_missing",
527
521
  "Set a default glasses device before calling connectDefault.",
528
522
  )
529
- if (!NimoResourceDiagnostics.allowManagerConnect(defaultDevice.model.deviceType, defaultDevice.name)) return
530
523
  if (defaultDevice.model != DeviceModel.SIMULATED) {
531
524
  requireBluetoothReady("connect to glasses")
532
525
  }
533
- if (options.cancelExistingConnectionAttempt && !NimoResourceDiagnostics.preserveCapturedScan(defaultDevice.model.deviceType, defaultDevice.name)) {
526
+ if (options.cancelExistingConnectionAttempt) {
534
527
  cancelConnectionAttempt()
535
528
  }
536
529
  deviceManager.connectDefault()