...
Code Block | ||
---|---|---|
| ||
from sic_framework import SICApplication from sic_framework.devices.common_naoqi.naoqi_speakers import NaoqiTextToSpeechAction, NaoqiTextToSpeechRequest class DemoTextToSpeech(SICApplication): def run(self): nao3_action = self.connect(NaoqiTextToSpeechAction, device_id='nao1') nao3_action.request(NaoqiTextToSpeechRequest("Hello world!")) if __name__ == '__main__': test_app = DemoTextToSpeech() test_app.run() |
Code Block |
---|
import time
import cv2
from sic_framework.core.message_python2 import CompressedImageMessage
from sic_framework.devices.desktop.desktop_camera import DesktopCamera
def on_image(image_message: CompressedImageMessage):
cv2.imshow('', image_message.image)
cv2.waitKey(1)
camera = DesktopCamera()
camera.register_callback(on_image)
time.sleep(100) |