April 9, 2016 at 3:54 am #2544
Hi all, I have done some searching and can’t find anything where someone else is having the issue i am having.
I am building a gameframe from scratch as a learning project. Well not entirely from scratch, i purchased the art because its great!
I had a bunch of Adafruit neopixels laying around from a previous project.
I purchased the following
a 3231 RTC board
a microsd board
an ir reciever and an ir remote
all from adafruit.
i have all the libraries in place and can successfully upload the code from the github repository to the teensy 3.2, kudos to jeremy by the way on some great code!
when i start to modify the code to use neopixels, ws2812 RGB leds, i get a ton of errors related to fastled
i also see there is a clockpin associated with the LEDS in the code, but the neopixels dont have a clock pin.
I attached a screen grab of the errors
I have been pulling my hair out messing with this.
Can anyone offer assistance as to how to switch the code over to run on a string of neopixels? Any support that would help me learn about this stuff would be amazing.
I have 3d printed 256 little diffusers, a grid, soldered all the LEDS up.
I feel like i am so close on this, but i am just a little bit too ignorant about arduino coding.
Thanks a ton in advance for any advice.
i have attached a pic of the project so far in case anyone is curious.
Attachments:You must be logged in to view attached files.April 9, 2016 at 4:17 am #2547
Game Frame 2 uses APA102C LEDs (Adafruit calls them DotStar). Unfortunately NeoPixels are not compatible with the IR receiver since they tie up the system interrupts in order to meet their exact timing.
That said, you should be able to get it working with NeoPixels at the expense of the IR working properly. Look for a FastLED example using WS2812 to see the syntax on how to init them.April 9, 2016 at 4:28 am #2548
ahh, well then i should likely revert to gameframe 1 code and ditch the IR control.
no biggie. I will work on getting that up and running as it seem like it will be more straight forward. Then i can tinker with the version 2 with the IR stripped out.
thanks a ton for the info and pointing the way!
Keep making awesome stuff!
I will be sure to post some pics when / if i get it working.
if you like checking out fun projects, particularly ones full of LEDs here is my last one. I spent a year on the designing, 3D printing, and painting. My buddy did the code for raspberry pi, which is what got me into learning the code end of all this.
thanks again!April 9, 2016 at 4:36 am #2549
The first Game Frame ran on Arduino Uno, not Teensy. I think you’re better off just getting NeoPixels working. It should be a simple matter of running the right Init.
Trying changing this line:
FastLED.addLeds<LED_TYPE, DATA_PIN, CLOCK_PIN, COLOR_ORDER>(leds, NUM_LEDS).setDither(0);
LEDS.addLeds<WS2812,DATA_PIN,COLOR_ORDER>(leds,NUM_LEDS).setDither(0);April 9, 2016 at 5:16 am #2550
Awesome! that did the trick. So after reading a bit about the APA102C leds it makes me wish i didnt have 1000 WS2812 leds lying around. Looks like an APA102 that is RGBW would be an awesome solution.
remote high five for the help!
I had to mess around with the version of sdfat I used but it seems to compile now.
looks like tomorrow is breadboard fun day!
BTW, I am excited to see what you do with the VR pinball stuff! looks like lots o fun!
thanks so muchApril 9, 2016 at 3:28 pm #2554
As i was wrapping my head around the code (poorly) i had a couple questions that are likely trivial for someone more knowledgeable than me.
1. I don’t see any pin definitions for the SD card to for the MOSI and MISO (data I/O) am i missing something or can they just be on pins 11 and 12 of the Teensy 3.2?
2. I read the Teensy 3.2 has a built in RTC, does this mean i can omit the external RTC? if needed, can the RTC’s SDA and SCL just be on pins 16-17 or 18-19? how does it know where you have hooked these things up if they aren’t defined in the code?
boy the teensy platform crams a lot of capability in a super tiny form factor. I had never even heard of this thing before I started this project.
I apologize if my questions seem silly, but I am learning so I often have silly questions.
I will keep reading and scouring the interweb for clarity on this, but I really appreciate any help from anyone willing to take the time. 🙂April 9, 2016 at 6:36 pm #2555
1) Yes, pins 11 and 12. The SPI pins are hard wired so the library doesn’t expect you to assign them.
2) It does have a built-in RTC but not a crystal so you’d need to solder one to the appropriate through holes and mess with the Time code to use the Teensy RTC instead. It also won’t be nearly as accurate as the DS3231.
As for pins, the DS3231 communicates via I2C which, like SPI, is hard wired (SDA & SCL). EDIT: These are pins 18 & 19. That is the primary default I2C address.April 9, 2016 at 6:47 pm #2556
sweet, your the best!
I will post up some pics when i get this thing together.
- You must be logged in to reply to this topic.