SAM - Software Automatic Mouth

Hi everyone. I thought it would be a good idea to port a speech synthesizer to Pokitto. At one point I have this partly working in the simulator, but I can’t get it working on Pokitto. My guess is not enough RAM perhaps? I can get it to a certain point, but then it crashes. I commented out the where it crashes/freezes. If anyone else want’s to have a go, you can grab the beginnings from here.
Currently there will be no audio output because we can’t do that yet, but I assume it should be able to output a .wav file to the SD card if the file exists already.

3 Likes

I just found this
Would it take much to port to Pokitto? I know absolutely nothing about how it works…

This looks like it was written by a C programmer gradually learning C++.

You’d need to:

  • swap out all the pgm_read_byte and pgm_read_word macro calls
  • change all the booleans to bool
  • change FALSE to false and TRUE to true
  • swap byte to uint8_t
  • modify some of the sound playing functions.
  • possibly remap the pins (I don’t know what the Pokitto equivalent would be or if it has an equivalent)

It’s definitely doable, it’s just a question of how much work it would be. Obviously you’d have to actually have half an idea of how it works.
I don’t think it can output to wav though, so you’d probably have to wait until we’ve got full sound on the Pokitto.