File size: 2,027 Bytes
f0ccdab | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 | # Display Guide
The display API lets your app send glanceable, user-visible information to supported smart glasses.
Mentra Live does not have a display. Use display APIs only on display-equipped models such as G2.
## Basic Text
Android:
```kotlin
sdk.displayText(text = "Turn left in 100 ft", x = 0, y = 0, size = 24)
```
iOS:
```swift
try await sdk.displayText("Turn left in 100 ft", x: 0, y: 0, size: 24)
```
React Native:
```ts
await BluetoothSdk.displayText("Turn left in 100 ft", 0, 0, 24);
```
## Clear Display
Android:
```kotlin
sdk.clearDisplay()
```
iOS:
```swift
try await sdk.clearDisplay()
```
React Native:
```ts
await BluetoothSdk.clearDisplay();
```
## Dashboard
Android:
```kotlin
sdk.showDashboard()
```
iOS:
```swift
sdk.showDashboard()
```
React Native:
```ts
await BluetoothSdk.showDashboard();
```
Dashboard support depends on the connected glasses model and firmware.
## Settings That Affect Display
Android:
```kotlin
sdk.setBrightness(60)
sdk.setAutoBrightness(true)
sdk.setDashboardPosition(height = 4, depth = 6)
sdk.setHeadUpAngle(20)
sdk.setScreenDisabled(false)
```
iOS:
```swift
try await sdk.setBrightness(60)
try await sdk.setAutoBrightness(enabled: true)
try await sdk.setDashboardPosition(height: 4, depth: 6)
try await sdk.setHeadUpAngle(20)
try await sdk.setScreenDisabled(false)
```
React Native:
```ts
await BluetoothSdk.setBrightness(60, false);
await BluetoothSdk.setAutoBrightness(true);
await BluetoothSdk.setDashboardPosition(4, 6);
await BluetoothSdk.setHeadUpAngle(20);
await BluetoothSdk.setScreenDisabled(false);
```
## Guidelines
- Keep text short. Glasses displays are glanceable, not phone screens.
- Prefer one primary message at a time.
- Avoid rapid display churn. Debounce frequent updates.
- Clear the display when information is no longer relevant.
- Handle disconnected, not-ready, and unsupported-capability states gracefully.
|