Enter the world of Jasper

(Last Updated On: )

Want to play around with some voice activation? Want to talk to your Raspberry Pi? Your choices so far are Alexa and Jasper. I went with Jasper after finding out AlexaPi requires you to press a button on a website to activate the voice goodies. So you would have to click a button on a web page every time you want to talk and are done talking to Alexa. Fuck that noise! Jasper it is! First off don’t follow the Jasper Documentation install guide. Do not! (as of 05/04/2016), it doesn’t work. It was also written for older Pies.

Instead you should probably follow this guide (Wheezy only): https://github.com/bablokb/jasper-install (I have not tried this myself). I downloaded an image made for a Pi2 B+.

Pros to not downloading an image, you don’t have to wait for the download and you can tweak stuff during the build I’m sure, if you know what you are doing, this is not me. Cons, the build time takes 4-8hrs. Pros to downloading an image, all that build time is gone. Cons, you have to (find!) download the 2gb-7gb torrent.

So this is what I did. Download the image for the Raspberry Pi 2 B+ and bake it to a SD Card (I use the ApplePi Baker, so easy). Do the standard raspi-config crap after your first boot. Now go and follow everything in the configuration section. All of it. Now you should be good to go. Use thePi Baker to “freeze” (copy the image) of the SD so when you fuck it up later you don’t have to start from scratch when you jack shit up later.

(Finding and) Downloading Jasper for the RPi2…
This guy did all the work and released it to the world for free but he requires you to download and install some shitty ass 3rd party torrent software to get it. What a total asshat, on top of that he protects everything with fucking keys. Total douche cannon move.

Mega download: https://mega.nz/#!T5VHXb4A!ZFaDDAUASswYb6Fi_-opDScBWOpNqmJMWS9KgPgn2nU
Guy that made the IMG: http://www.dansinclair.co.uk/raspberry-pi-2-jasper/

Debian DEB: https://groups.google.com/forum/#!topic/jasper-support-forum/RVATTGel-OQ

You can also find a few IMGs for the RPi2/B+ in the Google Groups, most of them require that stupid 3rd party software and keys to unlock them (fucking asshat!!): https://groups.google.com/forum/#!forum/jasper-support-forum

Some side notes that may help keep your sanity longer:

To start Jasper at Boot
sudo crontab -e
Add the following:
@reboot /home/pi/jasper/jasper.py;

To remove Jasper start at boot
sudo crontab -e
place # in front of the job or remove it
save (ctrl+o) and quit (ctrl+x)

OR (untested, copy/pasted from Google-Groups)

You can just add the scrip to ‘/etc/rc.local’, something like:
su -c '/usr/bin/python /home/pi/jasper/jasper.py' pi

I removed News.py and HN.py, these news scripts were useless to me and for some reason News.py would override every other script. So Jasper would constantly tell me the news no mater what I asked him, and that is not a short script so you get tired of waiting for it to finish and telling him no all the time.

I tried to change the default voice (its hard to understand sometimes) but Google-TTS is a no go for me, it requires a Google Developer Account and that costs $25. I’ll pass. So stuck with espeak. Have not tried the others yet.

If you are running into “I’m sorry but I can’t see that far into the future” with Weather.py then you’re probably using your zipcode in the config, like the instructions said, well that wont work surprise. You need to use the special chart to get the closest big city in your area and use that number then Jasper will tell you the weather. I also started using the Weather.py from the google groups here instead, its better and worked for me out of the box.
(I can’t remember where that special chart was, soon as I do I will update the post)

Super handy tip #1:
The volume level will most likely not be set at a decent usable level. From a terminal run “alsamixer” on your Raspberry Pi for microphone and speaker level controls. Raising the microphone level will help Jasper to hear your voice from a greater distance, and up the output volume while you’re at it.

Super handy tip #2:
After a day or so of playing with Jasper he started crashed constantly for what seemed like no reason. The only error I would get is

Which after some digging I found is related to the Google email notification script. If you comment out your email address in profile.yml the error will go away. Google email notifications won’t work either, but at least Jasper will stop crashing.

Super handy tip #3:
This person suggests changing keywords to at least 4 syllables so Jasper has an easier time hearing you over background noise, sounds like a legit idea but I haven’t tried it yet.

Some useful information on how to write Jasper scripts:

Build your own Siri with Raspberry Pi2 and Jasper

Things left to do:
1. Spotify control
2. Integrate with the house security system/Raspberry Pi (the one in the garage)
3. Write some more scripts

Jasper modules I have found
Reports system status https://github.com/edouardpoitras/jasper-status

Collections of modules I have found
https://github.com/Hadjimina/JasperModules (some good ones)
https://github.com/aaskasen/JasperModules – sample home automation

Discover more from Its_All.Lost

Subscribe to get the latest posts to your email.

Leave a Reply