gpt4 book ai didi

bluetooth - 检测 Apple TV 第 4 代何时从 sleep 状态唤醒

转载 作者:行者123 更新时间:2023-12-01 18:42:36 24 4
gpt4 key购买 nike

我正在开发一些家庭自动化程序,我想要做的事情之一就是检测我的第四代 Apple TV 何时从 sleep 状态唤醒。通常只有当有人按下 Siri Remote 上的按钮将其唤醒时才会发生这种情况。

我有一台带有 Pulse-8 USB-CEC 适配器的 PC(与 Apple TV 连接到同一台电视),因此我尝试的第一件事自然是使用 CEC 来确定 Apple TV 何时唤醒。不幸的是,它并不可靠,因为监控 Apple TV 的电源状态以查看其何时唤醒会产生误报。 (我应该注意,我没有在 Apple TV 上启用“控制电视和接收器”,并且无法为我正在处理的特定项目打开它,因为我需要 Apple TV 不更改电视的输入。 )

我正在尝试考虑其他方法来做到这一点。我对任何可能性持开放态度,包括:

  • 在 Apple TV 上使用私有(private) API
  • 在 Apple TV 后台运行一个“始终开启”的程序,该程序会在 Apple TV 唤醒时发送信号(如果可能的话)。 (我怀疑事实并非如此。)
  • 监控 Siri Remote 和 Apple TV 之间的蓝牙通信(如果可能)
  • 以某种方式过滤 HDMI-CEC 命令,以便我可以打开“控制电视和接收器”,允许 Apple TV 的 CEC 命令用于打开和关闭电视,并排除用于更改电视输入的命令。
  • 任何其他方法,无论多么古怪或荒谬,只要它有效!

有人有什么建议吗?我已经没有什么可以尝试的了!

最佳答案

我尝试在苹果讨论/支持社区上发布以下内容,但被告知我无权发布此内容。也许这个小组中的某个人可以成功做到这一点:

Apple TV 4 CEC integration is great when it works, but it doesn't work all the time and not with all the various equipment out there, you can do a search across forums and you will see lots of unhappy users. I would like to use a raspberry PI to detect when my AppleTV goes to sleep and wakes up and programmatically turn my tv on or off using its RS232C or custom CEC commands.

I used a bonjour services explorer and compared every single result between sleep and on states and there are no differences whatsoever.  I would have expected Apple to welcome such automation projects and make this information readily available with a variable such as status: sleep or status: on. 

Is there a way I could tell the two states apart via the network connection?

If not, could one build a TvOS app which runs on the background and makes this information available to clients somehow?

关于bluetooth - 检测 Apple TV 第 4 代何时从 sleep 状态唤醒,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35675803/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com