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.
Android:
sdk.displayText(text = "Turn left in 100 ft", x = 0, y = 0, size = 24)iOS:
try await sdk.displayText("Turn left in 100 ft", x: 0, y: 0, size: 24)React Native:
await BluetoothSdk.displayText("Turn left in 100 ft", 0, 0, 24);Android:
sdk.clearDisplay()iOS:
try await sdk.clearDisplay()React Native:
await BluetoothSdk.clearDisplay();Android:
sdk.showDashboard()iOS:
sdk.showDashboard()React Native:
await BluetoothSdk.showDashboard();Dashboard support depends on the connected glasses model and firmware.
Android:
sdk.setBrightness(60)
sdk.setAutoBrightness(true)
sdk.setDashboardPosition(height = 4, depth = 6)
sdk.setHeadUpAngle(20)
sdk.setScreenDisabled(false)iOS:
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:
await BluetoothSdk.setBrightness(60, false);
await BluetoothSdk.setAutoBrightness(true);
await BluetoothSdk.setDashboardPosition(4, 6);
await BluetoothSdk.setHeadUpAngle(20);
await BluetoothSdk.setScreenDisabled(false);- 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.