帮助开发可视化界面,完成显示设备选择、控件配置与多媒体播放集成。
复制安装指令,让 AI 自动完成配置 · 推荐新手
请帮我安装 askskill 上的 "display-access" 技能: 1. 下载 https://raw.githubusercontent.com/facebook/meta-wearables-dat-android/main/plugins/mwdat-android/skills/display-access/SKILL.md 2. 保存为 ~/.claude/skills/display-access/SKILL.md 3. 装好后重载技能,告诉我可以用了
请为一个会议室展示屏设计界面配置方案:选择合适的显示设备,定义顶部标题栏、三张信息卡片、底部操作按钮,并说明各区域的布局与交互。
输出一份展示界面方案,包含设备选择建议、界面结构、控件说明与交互逻辑。
请用 UI DSL 描述一个信息看板页面,包含图标、按钮、图片区域和视频播放器,并确保适配横屏显示。
输出可用于构建页面的 UI DSL 定义,清晰描述组件层级、属性与布局。
请设计一个用于门店大屏的多媒体播放页面,包含品牌图片轮播、宣传视频播放、返回按钮和状态图标,并说明播放控制逻辑。
输出一套多媒体页面设计说明,涵盖视觉组件、媒体区域安排和播放控制流程。
Use mwdat-display to render content on Meta Ray-Ban Display glasses.
Use this skill with getting-started and permissions-registration when creating a full app. A Display app still needs SDK initialization, app registration, Android permissions, and DAT manifest metadata before it can create a session.
In libs.versions.toml:
[libraries]
mwdat-display = { group = "com.meta.wearable", name = "mwdat-display", version.ref = "mwdat" }
In app/build.gradle.kts:
dependencies {
implementation(libs.mwdat.core)
implementation(libs.mwdat.display)
}
Display apps need the same core DAT setup as other apps plus DAM enabled:
<uses-permission android:name="android.permission.BLUETOOTH" />
<uses-permission android:name="android.permission.BLUETOOTH_CONNECT" />
<uses-permission android:name="android.permission.INTERNET" />
<application ...>
<meta-data
android:name="com.meta.wearable.mwdat.APPLICATION_ID"
android:value="${mwdat_application_id}" />
<meta-data
android:name="com.meta.wearable.mwdat.CLIENT_TOKEN"
android:value="${mwdat_client_token}" />
<meta-data
android:name="com.meta.wearable.mwdat.DAM_ENABLED"
android:value="true" />
</application>
Set mwdat_application_id and mwdat_client_token from Gradle manifest placeholders or local.properties, as in the DisplayAccess sample. Developer Mode builds can use the developer registration flow, but production builds need real Wearables Developer Center credentials.
Request the runtime permissions before initializing DAT, then call Wearables.initialize(context) once and start observing SDK state. Start registration with Wearables.startRegistration(activity), collect Wearables.registrationState, collect Wearables.registrationErrorStream, and wait for RegistrationState.REGISTERED before creating a display session. Use Wearables.startUnregistration(activity) when the user disconnects the app.
Display content only works on connected, compatible devices whose type supports display. Use the public device filter when you want automatic selection:
import com.meta.wearable.dat.core.Wearables
import com.meta.wearable.dat.core.selectors.AutoDeviceSelector
val selector = AutoDeviceSelector(filter = { device -> device.isDisplayCapable() })
val sessionResult = Wearables.createSession(selector)
Use SpecificDeviceSelector(selectedDeviceId) instead when your UI lets the user pick a specific DeviceIdentifier from Wearables.devices.
For device picker UI, mirror the DisplayAccess sample: collect Wearables.devices, start a metadata collection for each device ID from Wearables.devicesMetadata[id], remove metadata for devices that disappear, and show device name, device.deviceType.description, device.linkState, device.compatibility, and device.isDisplayCapable(). Keep selection disabled unless the device is LinkState.CONNECTED and display-capable, and surface DeviceCompatibility.DEVICE_UPDATE_REQUIRED with an openFirmwareUpdate action.
import com.meta.wearable.dat.core.types.Device
import com.meta.wearable.dat.core.types.DeviceIdentifier
import com.meta.wearable.dat.core.types.LinkState
import kotlinx.coroutines.Job
import kotlinx.coroutines.flow.MutableStateFlow
import kotlinx.coroutines.flow.update
private val metadataJobs = mutableMapOf<DeviceIdentifier, Job>()
private val devicesMetadata = MutableStateFlow<Map<DeviceIdentifier, Device>>(emptyMap())
lifecycleScope.launch {
Wearables.devices.collect { deviceIds ->
(metadataJobs.keys - deviceIds).forEach { removedId ->
metadataJobs.remove(removedId)?.cancel()
devicesMetadata.update { current -> current - removedId }
}
deviceIds.forEach { id ->
metadataJobs.getOrPut(id) {
…
帮助用户配置摄像头会话与视频流,并完成拍照及分辨率帧率设置
指导你构建含会话创建、相机串流与拍照功能的完整 DAT 应用
帮助开发者管理会话与流状态,并处理暂停恢复及设备可用性监控
帮助排查常见故障、版本兼容与会话流诊断问题,提升开发调试效率
帮助开发者完成 Meta AI 应用注册与设备权限接入流程配置。
帮助开发者掌握 DAT SDK Android 的 Kotlin 约定、结果处理与会话能力规范。
帮助你创建、修改、调试并预览 IWSDK 应用中的 PanelUI 界面组件。
将实时更新发送到 iOS 和 Android 展示屏设备的 MCP 工具。
将参考界面提炼为可量化的设计DNA,并据此生成风格一致的UI方案。
通过屏幕识别与键鼠控制自动操作桌面应用,执行测试、办公与重复流程。
让 AI 通过截图感知桌面并操控鼠标键盘完成自动化操作。
自动录制专业感网页应用界面演示视频,适合讲解、教程与产品展示