what pins best to use?
mctrivia
Posts: 3,772
4 address lines, 3 address latch
8 data lines
re#
we#
cs
what pins would you recomend for fastest access to the 128MB RAM?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
8 data lines
re#
we#
cs
what pins would you recomend for fastest access to the 128MB RAM?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
Comments
PortPin 9 - 15 for the adress + latch
This way you can use the movs and movd instructions for fast setting. Otherwise you have to do masking to avoid changing the control signals.
PortPin 8 and PortPin 17 should be unused if controlled by the same COG, so you don't need to take care of the MSB when writing 8 bit with a 9 bit instruction.
For the control signals you can use whatever pins you want starting from PortPin 18.
Q: 128Mb? or Kb?. If Mb, what sort of chip/module is that?
And something I've realised - you don't need /CS on a ram chip. Just leave it selected all the time and use /RD and /WR. Saves a pin...
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.smarthome.viviti.com/build
See RAM RAM RAM for more about my modules.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
Post Edited (mctrivia) : 11/12/2009 2:35:13 AM GMT
As for which pins, I'm not 100% sure it matters. If you use P0-7 and send out a data 1 byte at a time, you still need to mask the high (>7) bits out, then or them with the address mask. And if you put address from P0 up and data further up, it is the other way round but (I think) the same number of ops. Sooner or later, something needs a shift, and I think a shift 1 bit is the same speed as a shift 20 bits, so that doesn't really matter either. For a ballpark figure, I got code writing a single byte to a static ram over 12 lines in 25 instructions. I think Cluso did it in 16, but that included some out-of-bounds checking as well, so maybe it could be 12 or 13 instructions. It probably is easiest to start with P0-7 as a data bus.
The instructions tend to take the form of - get a long, shift it, AND mask it, OR it with something else, output it by toggling something. 6 instructions, but sometimes 5 if there is no shifting. So I don't think it matters which pins you use.
16megabytes would very nice though... 128megabytes would be scary!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.smarthome.viviti.com/build
Post Edited (Dr_Acula) : 11/12/2009 3:05:07 AM GMT
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
I don't know if what I imagine actually exists but it would be really nice if the low address bits could be loaded into a latch which is capable of counting up ... and down too, why not? If you do CPLD or FPGA programs, a versatile latch could really speed up your access time as long as the code to drive it is fast, tight, and transparent (for example two PUBs, RDRAM() and WRRAM(), or if it isn't too anachronistic, POKE and PEEK). You probably could command the latch very fast with longs through a COG Video Generator I think.
Sometimes I lose a few bytes of data in my SRAMs when everything else is powered down, and I never completely solved that problem, but I sure wish that the /WR pin was active high instead of active low, as that is an obvious possible cause of data loss.
I'm looking forward to mctrivia's schematic - in particular how the memory chip actually addresses 16mb. Is it just a lot of pins? And if so, since memory is usually addressed in blocks, maybe you can set the higher addresses and change them less frequently? Burst mode sounds intriguing too.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.smarthome.viviti.com/build
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
I have not made a 3D model of the memory modules yet so on the simulation you just need to imagine 25.8mm long pins sticking out of the board. My modules can be soldered on up to 8 high.
Yes 128MB is a lot of RAM I would like to see someone try to use it all up with a prop.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
Don't forget what Bill Gates supposedly said about the PC "640K ought to be enough for anybody"
It sure would be great to have something like a wiki page with a table outlining all the RAM variations available - type, cost, byte capacity, pin requirements, burst access speed, random access speed, read speed vs. write speed, power requirements, etc.
There are just so many variations of RAM -
cog RAM - maybe the fastest, cheap, but limited in size
hub RAM - still pretty fast, also cheap with a little more size
static RAM with multiplexed addressing - expensive but relatively fast and fairly large capacity, needs lots of pins
static RAM with external counter addressing - maybe the fastest large capacity solution; fewer pins needed
dynamic RAM - much less expensize, fairly large capacity, need lots of pins, often free as surplus
SDRAM - like DRAM but self-refreshes, relatively expensive
SD card(s) - very few pins needed
serial EEPROM - relatively small, slow
FRAM - reads wear them out
CMOS clock RAM - extremely low power for a few bytes of nonvolatile storage
hard disk - probably currently the highest capacity, relatively slow, often free as surplus; needs lots of pins, needs lots of power
And maybe another wiki section with tips and tricks for the best pin access - using the movi, movd, movs commands, using cog counters to generate addresses and/or RAS/CAS/WE pulses, etc.
70ns random
20ns near(different a3-0)
7ns burst(133mhz)
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
I'm in sort of the same boat as Dr_Acula - I've been working with a 30 pin SIMM on a prof development board, just basically getting experience trying to work out optimum pins and commands for different ways to do addressing if the goal is to access a megabyte or more pretty fast.
30 pin SIMMs also multiplex adresses, so the addressing problem is similar to the SDRAM board - it's not too hard to get really fast access to a small block of the RAM if you fix the higher address lines, but if you want to read or write every location, the instructions to manage the extra bits really start to add up.
Maybe a mix of propeller addressing the high address lines, with the SDRAM burst writing to the lower addresses might get good results?
Set start address
clk*3
Read
Clk
Read
Clk
Read...
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
But what if you're trying to digitize music or data or something and you want several megabytes of samples recorded at equal time intervals. How much processing has to be done to set up the next burst write?
I'm not trying to disparage burst mode; I'm just trying to look at an actual application of SDRAM to see how it would perform over the entire capacity of storage.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
A0-A3 tied to P9-P12
L0-L2 tied to P13-P15
Re# tied to P18
Wr# tied to P19
CS tied to P20
have not roted yet but
CLK tied to P21
ADV# tied to P22
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
Post Edited (mctrivia) : 11/13/2009 4:46:50 AM GMT
Going off on a slight tangent, David B please keep us all posted with the SIMM developments.
On the schematic, where do /WR etc go? (there are 6 pins in a group at the right). Do these go to other prop pins or to another latch or something else?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.smarthome.viviti.com/build
Cre got grounded as there is no way with this schematic to effectively work with the registers and they really only effect low power modes.
the ics are only about 50c each. you can read the part number on the sim though obviously you need to use the 3.3v versions.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.smarthome.viviti.com/build
It can be wired on perf board but a pcb kit would be much better.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
Also CS is important. With these modules you can only hold CS high for 4uS max.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
Thanks for the update.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
JMH
The biggest PSRAM I see on digikey is 128Mbits and 16bit wide data (8bit are not generally available?). The WAIT pin also needs to be connected for 7ns operation. For asynchronous SRAM-like operation, the 20ns access time is limiting for higher speed bursts, but eliminating the need to use extra pins can be useful especially given the possibilities for Propeller I (near 8MB) and II (<2GB) direct access. There should be more attention given to a PSRAM solution. PSRAM cost per MB at 20ns -vs- 10ns SRAM is appealing at ~ $10/8MB -vs- $10/1MB ... only 16bit PSRAM devices appear to be generally available for higher density. The power cost is much less ... orders of magnitude.
So, what's up?
What I can say is I have received all the parts to build 25 of my RAM Modules and I will finally be receiving the PCB on Monday.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
Where did you find a part with 26 address lines. I guess I was looking at the wrong spec. I like your "bank select" method via byte lane enable.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
24 bit LCD Breakout Board coming soon. $21.99 has backlight driver and touch sensitive decoder.
He designed a nice adapter module for Morpheus, however due to production time, testing time, etc., the Morpheus adapter won't be on the market until sometime in January.
I will make an "official" announcement after I have the boards and tested them - at which time I will order a production run. I don't yet have exact pricing for the adapter board, however I am trying to make it as affordable as possibe - which is why I went "off-shore" for manufacturing.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.mikronauts.com Please use mikronauts _at_ gmail _dot_ com to contact me off-forum, my PM is almost totally full
Morpheusdual Prop SBC w/ 512KB kit $119.95, Mem+2MB memory IO board kit $89.95, both kits $189.95
Propteus and Proteus for Propeller prototyping 6.250MHz custom Crystals run Propellers at 100MHz
Las - Large model assembler for the Propeller Largos - a feature full nano operating system for the Propeller
I got the Propeller Platform expansion PCB's in-house late last week - I'm sending a few over to mctrivia to validate his design. Once the design is validated, I'll make them available as a project. If everything checks out, they should be available in about 2 weeks.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Gadget Gangster - Share your Electronic Projects
I hope that WAIT signal is connected for synchronous mode .... Good luck guys.