Andreas Galauner wrote:
So, I had the idea of developing a small Board which contains a USB port and an SPI flash. I first thought about emulating the SPI flash completely by an AVR, but I think the clock rates of the SPI bus are too high to do this. My new approach is a SPI flash which resides on the AVR board which can be multiplexed between the AVR to program it and the motherboard. If I want to test a new BIOS, the AVR puts the motherboard into reset, detaches the flash chip with a multiplexer from the motherboard, programs it, switches it back to the motherboard and let off the reset.
Rapid BIOS development :)
Hello Andreas,
I agree with you that emulating a SPI ROM chip in software on AVR, or on any microcontroller, is near impossible because of the fast response times required. There is very little time between the last incoming address bit and the expected transmission of the data, if the SPI clock (generated by the mainboard) is in the order of 16...50 MHz.
Regarding your idea of multiplexing SPI ROM between mainboard and AVR, some of the work has already been done here:
http://www.coreboot.org/InSystemFlasher
Perhaps you could use it as a starting point?
Best Regards, Juhana Helovuo