Raspberry Pi Google助理问题

时间:2018-04-07 07:29:11

标签: python google-api raspberry-pi artificial-intelligence google-assistant-sdk

我最近关注this教程并遇到了问题。我似乎无法让它工作,但当我运行命令sudo /home/pi/google-assistant-init.sh启动它时,我收到此错误:

/home/pi/main.py:16: RuntimeWarning: This channel is already in use, continuing anyway.  Use GPIO.setwarnings(False) to disable warnings.
  GPIO.setup(25, GPIO.OUT)
Traceback (most recent call last):
  File "/home/pi/main.py", line 58, in <module>
    main()
  File "/home/pi/main.py", line 52, in main
    with Assistant(credentials) as assistant:
TypeError: __init__() missing 1 required positional argument: 'device_model_id'

我似乎无法让它发挥作用。任何帮助,将不胜感激。我也完成了所有步骤。

1 个答案:

答案 0 :(得分:1)

那个教程已经过时了。从那时起,开发人员在运行脚本之前必须register a device model。在第一次注册后,您可以毫无问题地运行项目。