0

Nothing's ever easy!

Posted by Chris on Monday, November 02, 2009
Using the super-beefed-up-18F4550 chips for version 2.0 of our ScoreSure device and a whopping 4Mbit Flash memory chip has meant lots of ideas floating around Nerd Towers.

With a massive 320x240 qvga screen, and enough memory to hold the bitmap data, full-colour images are suddenly a possibility. Interfaces have been redesigned, with flashy graphics, unnecessary animations and more - think Homers Homepage and you'll get the idea!

Anyway, it all hinges on getting data into and out of the 4Mb flash memory chip. Which, according to the datasheet is relatively easy, since it supports "legacy mode" data access - i.e. provide a memory location (in eeprom this is a single number, in Flash eeprom it's split into "page number" and "byte number" but the principle is the same) then start streaming bytes back to the PIC via SPI. This method by-passes the buffers, so you can pretend they don't exist and treat it like a giant eeprom chip. Easy.

Writing data isn't quite as straight-forward.
For a start, there's no way of writing data directly to the main memory. We've read and re-read the datasheet and can't find of any way of bypassing the pesky buffers when writing data back to the chip. We scoured every page and came up with nothing.

Then someone pointed out the block diagram:


There it is, in easy-to-understand pictures!
Data from main memory straight to the i/o interface (serial lines). But nothing going the other way. All data has to be written to the buffers, then transferred into main memory. Which is a bit of a bugger as we've already written big chunks of code for moving data around, and it all assumed that you could interface directly with the main memory array. Once again, it looks like we're back to the drawing board....

0 Comments

Post a Comment

whos.amung.us

Copyright © 2009 .Nerd Club All rights reserved. Theme by Laptop Geek. | Bloggerized by FalconHive Supported by Blogger Templates.