Mike McGurrin
Published © CC BY

The Yorick Project

A 3-axis talking skull turned into an Alexa voice services device via AlexaPi software, Raspberry Pi, and some other tools.

IntermediateShowcase (no instructions)10 hours22,718
The Yorick Project

Things used in this project

Hardware components

Raspberry Pi 3 Model B
Raspberry Pi 3 Model B
×1
Pololu Maestro Servo Controller
×1
Lindbergh 3-Axis Skull
×1
USB 2.0 Mini Microphone
×1
Audio Servo Driver Board
×1

Software apps and online services

AlexaPi
Alexa Voice Service
Amazon Alexa Alexa Voice Service
Pololu Maestro Controller Software

Story

Read more

Schematics

Schematic Diagram for Project Yorick

Code

Code snippet #1

Python
begin     # Loop until input 9 goes high
  9 get_position # get the value of the red trigger, 0-255
  155 greater_than # test whether it is greater than 155 
  if      # Wakeup word detected, run wake movement sequence
    wake     
    750 delay
    1 # flag for getting out of loop
    begin
      dup
      while
      9 get_position
      10 get_position
      plus
      300 greater_than
      if     # If after wake, both inputs high, then getting reply
        think
      else
        9 get_position
        155 greater_than
        if     # if just input on 9 high, then speaking reply
          answer
        else
          10 get_position
          155 greater_than
          if   # if just input on 10 high, then listening to query
            listen
          else     # when both inputs at zero, back to rest mode
	    Rest
            1 minus
          endif
        endif
      endif 
    repeat
  endif
repeat

### Sequence subroutines: ###
# Sequence subroutines removed not included for brevity

Github

https://github.com/alexa-pi/AlexaPi

Credits

Mike McGurrin

Mike McGurrin

9 projects • 15 followers
I consult on Intelligent Transport Systems. I like robotics, python, and Halloween props, which is what got me into the mix of hw and sw.

Comments