Breaking News

Spi Serial Flash Programmer Schematic Design

среда 31 октября admin 22
Ch341a spi flash programmer software

I am working on making a z80 based CPM computer based on the design from Grant Searle - - and have been studying up what would be needed to make a go of it. With the passage of time some electronic devices have gotten more expensive, and some have gotten cheaper. For a ROM, the current cheapest way that I could find for a 1-off board is one of the 128Kx8bit memories.

This is called programming, and is typically done with a much higher voltage. It actually damages the material, and after 100k program cycles, the gate will fail. † Indirect SPI flash programming using the ISE Design Suite iMPACT tools. Memories use a 4-wire synchronous serial data bus. The SPI flash configuration.

An SST39SF010A is only $1.66US at Digikey, and a 628128 128Kx8bit RAM is $2.15US. NOTE: This programmer will never be a standalone device. A goal is that I could send it a IntelHex file and it would read each line and write it to the flash, with the PC based program checking for addresses used, and offsets I might want to put on the data (more than 1 ROM image on a chip for testing/playing) In this case the Erase and write and verify could be automated. The other possibility is that I would send data to it in a binary mode which would be dependant on a program in another computer to send it address and data. The biggest problem is this - How do I program one of these Flash ROMS? And it turns out it is really rather easy. I started out with a design that uses an Arduino and 3 74595 shift registers, and then I dug out a board that I had put together a while back - ATMega1284P-PU 40 pin DIP based board that Crossroads pproduced and I bought a bare board form him.

Here's the where the conversation can be found - I hadn't done much with the board for awhile and recently I purchased several USB to Serial converters form DIPMicro and got one of them wired up and working. So I went from trying to design it with an ATMega328P and 3 supporting 595 shift registers to needing 1 ATMega1284 and no supporting chips. The ATMega1284 is a 40 pin DIP device with 32 I/O pins, of which can use up to 2 serial ports. In this application I only need 1 serial port so 30 pins are left free. The 8 pins for PORTA are assigned to the Flash's 8 data pind, PORTC is the lower 8 address bits, and because of the way things are defined under the Bobuino the other pins move around so they are not as easy to map to a port. So 2 Serial Port Pins, 8 Data bits, 19 address bits and 3 control bits - (*OE, *WE,*CE) and all the pins are used.

I have previously worked with Direct Port Manipulation on a Stepper Driver I made using an ATtiny2313 so I wanted to use that here wherever possible. Direct Port I/O is faster, but on a standard Arduino the use is limited by other functions sharing the different ports and the ATMega328. On the 1284 configured like a Bobuino, PORTA - which is shared with the 8 Analog pins (A0-A7) and (D14-D21) and PORTC which is digital pins D22-D29.

I assigned the Flash Data pins to PORTA and the lower 8 address bits to Port C. I can read the chip ID, and I can read chip data. Reading the chip data is the easiest. Load an address onto the address lines, digitalWrite(ReadEN,LOW); digitalWrite(ChipEN,LOW); readVal = PINA; digitalWrite(ChipEN,HIGH); digitalWrite(ReadEN,HIGH); I am working on using the 'sector' operations. Sectors are 4K blocks of memory. So a sector runs from address XX000 to XXFFFF. So to read secto 0 the command is R00, to read sector stating at 7000 the command would be R07.

It will read a 4K sector and send it out the serial port in approx. The CHip ID function uses both Write and Read. It writes to a sequence of addresses and then any address ending in 0 will return the Manufactirer ID, and any address ending in 1 will return the Chip ID. The sequence for the Chip ID function is - Write to address 5555 the value AA, write to address 2aaa the value 55, Write to address 5555 the value 90, then read from and Even address the Chip Manufacturer ID, and from and Odd address the Chip ID. And when finished send 0f to any address to exit Chip ID Mode.

These 2 functions are Non-Destructive, but when the Chip-ID function works properly then all programming steps should also work. Hey Crossroads - Here's where I come up with that - On the Bobuino PORTB goes like this - Pin 1 D4, Pin2 d5, pin3 D6, Pin4 D10, Pin5 D11, Pin6 D12, Pin7 D13 and on PORTD Pin1 RX0, Pin2 TX0, Pin3 D2, Pin3 D3, Pin4 D30, Pin 5 D8, Pin6 D9, Pin7 D31.

As is, I got a few wires mixed up and I was just going from PinX on the Crossroads Bobuino board to PinY on the flash chip. Shaktimaan serial title song lyrics mp3 download. Emulator casio fx 991es plus android. By not trying to sort out the pins at this time I felt I had a higher degree of possibility of not getting myself confused and haveing it work, WHICH IT NOW DOES!!!

I have successfully WRITTEN, READ and Erased a Sector of the flash. 90% finished. Took about a week. Now the remaining 10% will take months. If I used just PORT I/O it would work, but there would be 2 levels of numbers to keep track of the get all the wires in the proper place. If I used a 'Standard' pin configuration then the individual PORT groups would not be mixed up in any manner. Just a matter of the number of things I want to juggle when I am not real sure what I am doing.