Misty Lessons
  • Misty Lessons
    • 📖Welcome to Misty Lessons
    • 📚Get to know your Misty
    • 📲Connect to Misty
    • 👩‍💻Misty Studio
    • 🖥️Desktop Environment
    • ⬆️Update your Misty
    • 👥Projects
  • Blockly
    • 🧩Blockly Lessons
      • 🤸Lesson 1: Movement
      • 🎶Lesson 2: Voice and Sound
      • 🎭Lesson 3: Expressions
      • 🎥Lesson 4: Robot Cinema
      • 🛠️Lesson 5: Events
      • ☺️Lesson 6: Face recognition
      • 🔢Lesson 7: Variables and Functions
      • 💬Lesson 8: NLP
    • 🏫Blockly projects
  • Blockly Elements
    • ⚛️Misty Blocks
      • Movement
      • Speech
      • Audio
      • Vision
      • Events
      • Miscellaneous
      • NLP
      • System
    • 🔁Basic Blocks
      • Logic
      • Loops
      • Math
      • Text
      • Lists
    • 🅰️Advanced Blocks
      • Variables
      • Functions
  • Python
    • 🐍Python Lessons
      • 🦿Lesson 1: Loco-motion
      • 🤖Lesson 2 : Build a character
      • 🧠Lesson 3: Create memories
      • ⚒️Lesson 4: Event skills
      • 👀Lesson 5: Expand awareness
      • 🔗Lesson 6: Compact code
      • 🗣️Lesson 7: Start a conversation
  • Python Elements
    • 🐸Misty Python API
      • Motion and Mobility
      • Display and LED
      • Record Assets
      • Change/Remove Assets
      • Stream Assets
      • Get Assets
      • Events
      • Sensor Events
      • Speech and NLP
      • Arduino Backpack
      • System
      • Slam
    • 📗Python Definitions
  • Python Projects
    • 🔮MistyGPT
    • 🚨Misty Intruder Alert
    • 📺Conference Assistant
    • 🏷️QR code detector
    • 🕵️‍♂️Misty follow human
    • 👋Misty wave back
    • 🖲️Misty OA
    • 🌐Get weather
    • 🚚Misty Delivery
    • 🫂Motivational Misty
    • 🖼️Misty Museum Guide
    • 🎃Who for Halloween
  • ARDUINO
    • ♾️Arduino Backpack
    • 🦎Arduino
    • 🔧Arduino Lessons
      • 🔌Arduino to Misty
      • ➕Misty to Arduino
  • ARDUINO PROJECTS
    • 🛠️Misty Tracker
    • 🦾Misty Arm
  • Community Projects
    • 🌤️Misty weather forecaster
  • HARDWARE EXTENSION
    • ⚙️Arduino breadboard support
    • 🦾Misty arm
    • 🥤Tin holder
  • Resource Database
    • 📁Image files
    • 📁Audio files
    • 📁Languages
    • 📁Known objects
    • 📁NLP Actions
    • 📁Action Commands
    • 📁ChatGPT PDF files
    • 📁AR Tag Dictionary
    • ⚙️Technical Specifications
Powered by GitBook
On this page
  • GetAudioFile
  • GetAudioList
  • GetImage
  • GetImageList
  • GetVideo
  • GetVideoList
  • GetVideoRecording
  • GetVideoRecordingList
  • GetKnownFaces
  • GetConversations
  • GetLoadedContexts
  • GetStates
  1. Python Elements
  2. Misty Python API

Get Assets

In this section you can find all of Misty's API calls related to fetching information about her stored assets. To display a list of assets in the output field in the Python Interface you will need to use the syntax shown in the example below:

from mistyPy.Robot import Robot

# Initialize Misty
misty = Robot()

# Get the list of videos
video_list = misty.get_video_list()

# Check if video list is retrieved successfully
if video_list is not None:
    # Print the list of videos
    print("List of Videos:")
    for video in video_list:
        print(video)
else:
    print("Failed to retrieve the video list.")

GetAudioFile

Obtains a system or user-uploaded audio file currently stored on Misty.

Example Code

misty.get_audiofile("myaudio.mp4", false)

Parameters

misty.get_audio_file(self, fileName : str = None, base64 : bool = None)
  • FileName (string): The name of the audio file to get, including its file type extension.

  • Base64 (boolean): Optional. Sending a request with true returns the audio file data as a downloadable Base64 string. Sending a request with false returns the audio file to your browser or REST client. Defaults to false.

GetAudioList

Lists all audio files (default system files and user-uploaded files) currently stored on Misty.

misty.get_audio_list()

GetImage

Obtains a system or user-uploaded image file.

Example Code

misty.get_image("e_Amazement.jpg", false)

Parameters

misty.get_image(self, fileName : str = None, base64 : bool = None)
  • FileName (string) - The name of the image file to get, including the file type extension.

  • Base64 (boolean) - Optional. Sending a request with true returns the image data as a downloadable Base64 string. Sending a request with false displays the image in your browser or REST client immediately after the image is taken. Default is true.

GetImageList

Obtains a list of the images currently stored on Misty.

misty.get_image_list()

GetVideo

Obtains a user-uploaded video file currently stored on Misty.

Example Code

misty.get_video("myvideo.mp4", false)

Parameters

misty.get_video(self, fileName : str = None, base64 : bool = None)
  • FileName (string) - The name of the video to obtain, with the file type extension.

  • Base64 (boolean) - Optional. Sending a request with true returns the video data as a Base64-encoded string. Sending a request with false downloads the video file to your REST client. Default is false.

GetVideoList

Obtains a list of the user-uploaded video assets saved to Misty's storage.

misty.get_video_list()

GetVideoRecording

Downloads a video that Misty has created. Optionally, returns the video data as a Base64 string.

Example Code

misty.get_video_recording("myrecording.mp4",true)

Tip: Misty records videos in .mp4 format. Video recordings have a maximum resolution of 3840 x 2160 pixels and can be up to 3 minutes long. A single video file can be up to 225 MB and can take several minutes to download.

Parameters

misty.get_video_recording(self, name : str = None, base64 : bool = None)
  • Name (string) - Optional. The filename of the video to download. If not supplied, defaults to misty_video.

  • Base64 (boolean) - Optional. Sending a request with true returns the video data as a Base64-encoded string. Sending a request with false downloads the video file to your REST client. Defaults to false.

GetVideoRecordingList

Obtains a list of filenames for each video recording saved to Misty's local storage.

misty.get_video_recording_list()

GetKnownFaces

Obtains a list of the names of faces on which Misty has been successfully trained.

misty.get_known_faces()

GetConversations

Obtains a list of conversations stored in Misty's memory.

misty.get_conversations()

GetLoadedContexts

Obtains a list of loaded contexts used for NLP.

misty.get_loaded_contexts()

GetStates

Obtains a list of states used in your conversation.

misty.get_states()

Last updated 1 year ago

Note: This command only obtains user-uploaded video assets. To obtain a video recording that Misty created, you must use the command.

Note: This command only obtains a list of user-uploaded video assets. To obtain a list of video recordings that Misty created, you must use the command.

You can only use this command to download videos that Misty recorded. To get videos that you or another user has uploaded, use the command.

🐸
GetVideoRecording
GetVideoRecordingsList
GetVideo