Different types of AI glasses have different capabilities. After [planning how
you'll support different types of AI devices](https://developer.android.com/develop/xr/jetpack-xr-sdk/ai-glasses/support-different-types), you can check for device
capabilities at runtime to provide the best experience for a user's device.

## Check whether a device has a display

Some AI glasses have a display where your app can show [UIs built with Jetpack
Compose Glimmer](https://developer.android.com/develop/xr/jetpack-xr-sdk/jetpack-compose-glimmer). The following example shows how to check whether a glasses
device has a display:  

    val projectedDeviceController = ProjectedDeviceController.create(activity)

    if (projectedDeviceController.capabilities.contains(CAPABILITY_VISUAL_UI)) {
        // Set up UX state machine for AI glasses that have a display.
    } else {
        // Set up UX state machine for AI glasses that don't have a display.
    }