google-smart-home - Google 智能家居 - TemperatureSetting 温度范围不起作用
问题描述
我制作了一个谷歌智能家居,能够通过谷歌智能家居触摸控制来控制热水器泵。它需要控制的是所需的温度和模式(开关)。
我无法使用“加热器”设备完成这项工作,因此我使用了“恒温器”设备。
一切正常,除了一件事:温度范围。
在我的 onSync 请求中,我输入了 60F° 和 104F° 之间的范围,但它在设备上不起作用。
这是我的 onSync 请求。
function onSync(firebaseRef) { return async (body, headers) => {
return {
requestId: body.requestId,
payload: {
agentUserId: uId,
devices: [{
id: pId,
type: 'action.devices.types.THERMOSTAT',
traits: [
'action.devices.traits.TemperatureSetting',
],
name: {
defaultNames: ['My Heat Pump'],
name: 'Heat Pump',
nicknames: ['Pump'],
},
deviceInfo: {
manufacturer: 'test',
model: '1',
hwVersion: '1.0',
swVersion: '1.0.1',
},
willReportState: true,
attributes: {
// TemperatureSetting
availableThermostatModes: 'off,heat',
thermostatTemperatureRange: {
minThresholdCelsius: 15.555,
maxThresholdCelsius: 40.0
},
thermostatTemperatureUnit: 'F'
},
}],
},
};
}
}
你知道如何获得良好的温度范围吗?
奖励:温度触摸控制可以与加热器等其他东西一起使用吗?
解决方案
我从 Reddit 上的 u/devunwired 那里得到了这个答案:
在我的 onSync 请求中,我输入了 60F° 和 104F° 之间的范围,但它在设备上不起作用。
这是一个已知问题,即 Google Home 应用程序当前不呈现提供的温度范围(在语音查询中尊重该值)。您可以在此处关注(并开始)功能请求: b/154169625
推荐阅读
- latex - Latex 中多行方程的第一行中不需要的缩进
- java - 无法为 com.sun.xml.bind:jaxb-core:jar:2.2.11 构建父项目
- c# - 如何对文档数据库中的主表事务执行操作
- python-3.x - 我们如何使用 selenium 与活动浏览器交互?
- mysql - TYPO3 ExpressionBuilder中的mysql“rlike”
- angular - 更新到 Angular 8 后延迟模块加载错误
- swiftui - 图像集框架
- javascript - 我愿意让不和谐机器人从我的 Minecraft 机器人发送所有消息(加入、离开、杀死、聊天)
- javascript - 如何在 React + Typescript 中将状态更新为之前的状态
- python - 生成具有 n 位的随机数并避免使用 0 作为第一位?