def actionThread_exec(params):
t = threading.currentThread()
memory_service = getattr(t, "mem_serv", None)
# tts_service = getattr(t, "session", None).service("ALTextToSpeech")
print "Action speechbtn started with params " + params
# action init
# action init
if len(params) > 0:
memory_service.raiseEvent('AnswerOptions', 'speechbtn_' + params)
else:
memory_service.raiseEvent('AnswerOptions', 'speechbtn')
print "Action " + actionName + " " + params + " terminated"
# action end
sleep(.5)
memory_service.raiseEvent("PNP_action_result_" + actionName, "success")
评论列表
文章目录