Hello, I was able to get ESP8266 working with Adafruit’s POV code and using FastLED. The code attached works but it stores the patterns in working memory instead of in flash memory. Adafruit’s code uses PROGMEM which does not work with ESP. Removing the PROGMEM pieces results in the code working but not being able to store many files. Any help or direction?
Progmem is working with esp. on 8266 and esp32. What is you error ?
you declare const image PROGMEM images[] but in your code you access it using direct pointer manipulation, imageType = images[imageNumber].type; same for palette and pixels. I am not sure how to access these when in PROGMEM but I would try using pgm_read_byte for these also.
Or you may try to remove PROGMEM for images[] in graphics.h
Removing progmem from all of the code makes it work but stores everything in ram. Using progmem and pgm_read_byte & other pgm pointers caused the esp to reboot repeatedly. The code above works as is but stores everything in ram. Need to store in flash and read back. I will have to upload a new copy of the code with more explanation. I’m hoping I can get this working. It would allow way more patterns to be stored.
Okay I have added clarification and re-uploaded the sketch. This sketch works with ESP8266 and fastled. It stores patterns in RAM though and more patterns could be stored in flash. When I try to store patterns in flash, the board resets repeatedly.
@Erin_St_Blaine this sketch works with ESP8266 and the modified Adafruit POV code and Fastled
@Chris_Stock I did not get to your entire code but when you use progmem this is how you access an array
pgm_read_byte(pic+ 3*(yw+x))
Not pgm_read_byte(&pic[3(y*w+x)])
You should try to modify your code accordingly.
Same I am not sure you can do a memcpy I have never tried.
There is a function displaybitmapfromprogmem I hope that will help
Yves