MichaelMeissner
Senior Member+
I downloaded the uncannyEyes sketch that Phillip Burgess wrote and published over on an Adafruit blog: https://learn.adafruit.com/animated-electronic-eyes-using-teensy-3-1
When this was written it was explicitly for the Teensy 3.1, and runs also on the 3.2. I just ran it on my beta 3.6, though there are some issues:
I bought two no-name 1.44" 128x128 TFT SPI displays from ebay rather than the Adafruit versions: http://www.ebay.com/itm/122005165823?_trksid=p2057872.m2749.l2649&ssPageName=STRK:MEBIDX:IT. Of course there is no datasheet, not even a Japanese only version that Adafruit puts up for their 1.44" TFT display.
Note, as I've mentioned before, the Teensy ST7733 code does not have the additions that were added to the Adafruit code base which the uncannyEyes program uses, so I swapped to use the Adafruit version in this case. At some point, I may dig in and backport the changes Adafruit has made into the Teensy version, but since I'm switching to the OLED versions, I might not.
For whatever reason, the display came with one side soldered in, but when I tried using those pins, they didn't work with SPI. So instead, I clipped off those pins and soldered in some right angle headers on the other side. After fixing some solder problems, the displays seemed to work.
I changed the pinout to move pin 7 (data/command pin) to pin 4 so that I could eventually use the full prop shield and have it sense motion to adjust the eyes (pin 7 is the LED enable on the prop shield), and for now, I deleted the various analog inputs and buttons and just had the eyes moving on their own.
Now, I have more Teensy 3.1's lying around, so I started with a 3.1, and it worked on one display, but it would go wonky with two displays. I put a USB voltage monitor on the unit, and saw each display was pulling in about 120 mA. One is barely enough for the 3.1's voltage regulator (185 mA), and probably exceeds the specs. I figure the voltage regulator of the Teensy 3.2 might be up to the task (it is kind of close to the spec), but I didn't have a Teensy 3.2 that was easily accessible. So, I figured why not try the Teensy 3.6 which has a similar/same regulator as the Teensy 3.2. And sure enough it worked. I originally cut the speed down to 96 and it worked. I then went to the normal 120 MHz, and decided to press my luck and go to 240 Mhz. It still worked.
I tried powering the displays with 5v and using 3.3v data streams, and they didn't work. I suspect they might work if I level shifted the data pins with a fast enough level shifter. If I use a lipo battery to power the Teensy, it likely would work if I power it from VIN.
All of the speeds that I tried it at, I can see some flicker.
I decided to upgrade to the 1.5" OLED display to get the better colors and reduce the flicker. I ordered a New Haven display from digikey (http://www.digikey.com/product-deta...-1.5-128128ASC3/NHD-1.5-128128ASC3-ND/5788624). According to the datasheet, the display wants to use 80mA to 200mA. Hopefully it will run on USB 5v with 3.3v data. Note, the Adafruit blog says that you have to lower the Teensy 3.1's speed to 48Mhz to get it to work (with the Adafruit display). We will see how the New Haven display works.
Is there an example of using the motion sensors in the prop shield to identify move left and move right operations? I know it can track in 3 directions, but until now, I've mostly used the prop shield for sound, data storage (for mp3/wav files), and run neopixel LEDs. So more things to learn and try.
When this was written it was explicitly for the Teensy 3.1, and runs also on the 3.2. I just ran it on my beta 3.6, though there are some issues:
I bought two no-name 1.44" 128x128 TFT SPI displays from ebay rather than the Adafruit versions: http://www.ebay.com/itm/122005165823?_trksid=p2057872.m2749.l2649&ssPageName=STRK:MEBIDX:IT. Of course there is no datasheet, not even a Japanese only version that Adafruit puts up for their 1.44" TFT display.
Note, as I've mentioned before, the Teensy ST7733 code does not have the additions that were added to the Adafruit code base which the uncannyEyes program uses, so I swapped to use the Adafruit version in this case. At some point, I may dig in and backport the changes Adafruit has made into the Teensy version, but since I'm switching to the OLED versions, I might not.
For whatever reason, the display came with one side soldered in, but when I tried using those pins, they didn't work with SPI. So instead, I clipped off those pins and soldered in some right angle headers on the other side. After fixing some solder problems, the displays seemed to work.
I changed the pinout to move pin 7 (data/command pin) to pin 4 so that I could eventually use the full prop shield and have it sense motion to adjust the eyes (pin 7 is the LED enable on the prop shield), and for now, I deleted the various analog inputs and buttons and just had the eyes moving on their own.
Now, I have more Teensy 3.1's lying around, so I started with a 3.1, and it worked on one display, but it would go wonky with two displays. I put a USB voltage monitor on the unit, and saw each display was pulling in about 120 mA. One is barely enough for the 3.1's voltage regulator (185 mA), and probably exceeds the specs. I figure the voltage regulator of the Teensy 3.2 might be up to the task (it is kind of close to the spec), but I didn't have a Teensy 3.2 that was easily accessible. So, I figured why not try the Teensy 3.6 which has a similar/same regulator as the Teensy 3.2. And sure enough it worked. I originally cut the speed down to 96 and it worked. I then went to the normal 120 MHz, and decided to press my luck and go to 240 Mhz. It still worked.
I tried powering the displays with 5v and using 3.3v data streams, and they didn't work. I suspect they might work if I level shifted the data pins with a fast enough level shifter. If I use a lipo battery to power the Teensy, it likely would work if I power it from VIN.
All of the speeds that I tried it at, I can see some flicker.
I decided to upgrade to the 1.5" OLED display to get the better colors and reduce the flicker. I ordered a New Haven display from digikey (http://www.digikey.com/product-deta...-1.5-128128ASC3/NHD-1.5-128128ASC3-ND/5788624). According to the datasheet, the display wants to use 80mA to 200mA. Hopefully it will run on USB 5v with 3.3v data. Note, the Adafruit blog says that you have to lower the Teensy 3.1's speed to 48Mhz to get it to work (with the Adafruit display). We will see how the New Haven display works.
Is there an example of using the motion sensors in the prop shield to identify move left and move right operations? I know it can track in 3 directions, but until now, I've mostly used the prop shield for sound, data storage (for mp3/wav files), and run neopixel LEDs. So more things to learn and try.
Last edited: