@rickkas7, @peekay123 do you know if this flash chip works with the flashee-eeprom library?
What library did you use?
@rickkas7, @peekay123 do you know if this flash chip works with the flashee-eeprom library?
What library did you use?
Not sure about flashee-eeprom; I never tried it.
I wrote my own library for it. Iāll release my source once I finish a few more things.
@rickkas7 Thanks so much for the picture and wiring diagram! Perfect!
@wesner0019 Check out the code that @Suprazz posted above. It has the library for the flash chip + a library for pulling files from the internet onto the flash chip to fill it up remotely over the web. So if you flash new firmware to the Photon, you can then call a function to wipe the flash chip and then download new files to it over the web.
I have no had a chance to try it yet but will soon enough.
@peekay123 Did your flash chips arrive? Mine did but havenāt had a chance to work with them yet. Let me know how it goes, no rush, I have a trillion other things to do also.
@RWB, everything arrived. Iāll be testing the SPIFFS code tonight if I can. One thing that will need to be considered is the file format for the graphics. Ideally, they would be an exact binary version of the what is to be displayed (correct order, etc.) so it can just be streamed from the file to the display. However, Iām not familiar enough with all the moving pieces yet to know if this possible or not.
look for the BMP format. This is a uncompressed format easy to read for application like this. This is what Iām using.
@Suprazz, it would be more efficient to not use a common image format in this case. @RWB already converts these to a byte array for direct display. This reduces āreprocessingā in the Photon/Electron. @RWB, what are your thoughts here?
@peekay123 I have no idea how the image processing works in the background, so I leave it to you to tell me what is best. Obviously, we donāt want to rewrite what is already working with the Sharp Memory LCD.
My main goal was to be able to update the flash chip over the web remotely so I can update my products remotely since I plan on doing a lot of work with the LCD display & animations over time.
Think about it and let me know what the best options are.
Also, what are your thoughts on the image download portion of the code?
@RWB, since this is for the 2.7" monochrome version of the display, all pics will be black and white. A full screen image will take 12KB (also display buffer size). So you could store 80 or so full screen images on the flash. For animation, the faster they can stream off the flash, the faster the animation. As such, a streaming-ready data format may be best. However, that being said, it may be simplest to work with BMP format, as @Suprazz pointed out, and pay the small performance cost. Animations will be slower but I donāt believe speed is an issue for you.
@peekay123 If itās not a problem I plan on upgrading to a larger 4 or 16 Mb chip from the same company since the extra cost is so small. This way I should never run out of flash and Iāll have memory to spare for future ideas that will come up.
I have no idea what the image refresh times are between using the BMP format vs the way we are currently doing it but as long as its 1 second or under it shouldnāt matter much.
@RWB, as long as you get 30Hz or so, that is more than enough. If the image is only a partial screen size, we could create an animation buffer in RAM and play it back to the screen. It all depends what you need. Presently, the display library does not exploit SPI DMA and uses a single buffer. R&D is in called for here
@peekay123 90% of the images will not be full-screen size but smaller individual images and icons.
The way the current library works is perfect.
look here for a code sample of how to load a bitmap from sd. itās easy and good for your application. And it will be fast because itās only 2 colors. In my case Iām using 160x128 16 bits of color per pixelā¦
@Suprazz, thanks! I was working on that code already Now, if only I can find a monochrome BMP file online to test with. I want to avoid using an SD card since that means 3 SPI devices. I guess I could write an app that load several BMPs onto the flash from SD and then do another app to read the files and display them. Pain in my tush if you ask me.
simply load the files from the flash instead of the sdā¦ with spiffs itās easy to do a file open and read the same was as itās done with the sd libraryā¦
You can create monocrome bmp files with paint.
@Suprazz, I have to load the images onto the flash from a web page. I canāt find any bmp on the web to grab and I have nothing setup to serve one. So, the alternate is to load the files on SD and go from SD to flash. Am I missing something?
yes you're right. or you could use the FTPino server with spiffs like I do but right now there is an issue and I'm not able to transfer files completely. I'm trying to figure this out but I have no idea of what else I can try..
@peekay123 So you just need me to find or create a Bitmap image and host it online?
I have websites so I can provide a link to a BMP image just let me know exactly what you need and Iāll try to help out real quick. Like do you need a full-size image for the 2.7-inch display 400 x 240 pixels? Or do you just need any size BMP file under that size?
@Suprazz, Iām using a different ftp client library that has given me zero problems. Iāll use it to pull a file from a local server.
@RWB, the websites need to be HTTP and not HTTPS. You could hold full screen and smaller monochrome BMP images. If you are hosting an FTP that is just as good.
FYI, Iāll be doing some sanity check on the BMP file so only monochrome images that donāt exceed 400x240 are accepted and flashed.
@peekay123 Iāll give this a try after you have it all up and working.
Iāll give ya some for your time also