1

I spend lest two days for to find something and no result, maybe you can help me.

I'm using Amazon Echo Dot and i want to build some android application which can be controlled by Alexa. So i need to know if it's possible to realize next things:

1) Recognize my application as new smart device by Alexa

2) For example press some button I am my application when i say "Alexa. Switch something in my app"

If it's possible, can somebody provide some links for to documentation?

If i understand correct, when Alexa searching new smart devices in my WiFi network, she send JSON formatted request to each device in network and wait JSON answer. Is it right thing?

4

1 回答 1

2

我正在使用 Amazon Echo Dot,我想构建一些可以由 Alexa 控制的 android 应用程序。

目前无法直接通过 Alexa 控制应用程序。

如果您真的只想使用“打开 xy”、“关闭 xy”,那么您可以创建智能家居技能。Alexa 还要求此技能来发现设备。因此,它可用于使用特殊应用程序找到您的手机。

更多详情:https ://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/steps-to-create-a-smart-home-skill

但是,如果您想要更灵活,那么您必须创建一个 Alexa Skill 来为您的应用程序实现支持的语音命令。如果用户调用该技能的一个意图,或者在完成语音识别后最终由 alexa 后端系统调用,那么您可以对您的应用后端服务或 Android 通知系统执行休息调用,以通知您的应用该调用/用户希望。

流程应如下所示:

"Alexa start MyFancyApp"
"Alexa press the green Button"
   --> AWS Lambda "MyFancyApp.PressGreenButton" function is called
   --> MyFancyApp - Backend Service:/User01/GreenButton/press is called
   --> App on you Android Phone is informed and switch the State
   --> AWS Lambda "MyFancyApp.PressGreenButton" receives the status code from app backend and informs the user via the Echo Device: Voice out "green button is pressed".

操作方法:https ://developer.amazon.com/blogs/post/TxDJWS16KUPVKO/New-Alexa-Skills-Kit-Template-Build-a-Trivia-Skill-in-under-an-Hour

注意:您必须使用 Amazon Alexa 上的帐户链接来识别用户。

于 2017-02-02T23:02:10.290 回答