Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Connecting a RAM cell to an I/O

Status
Not open for further replies.

shaiko

Advanced Member level 5
Joined
Aug 20, 2011
Messages
2,644
Helped
303
Reputation
608
Reaction score
297
Trophy points
1,363
Activity points
18,302
Hello,

Considering the fact that a RAM cell requires less transistors to implement then a DFF - why can't a RAM cell be used as a complete substitute to a DFF?

For example:
On FPGA's, I/O pins can be connected to a DFF...Is there a good reason why they can't be connected directly to a single bit RAM memory cell?
 

The SRAM storage cell itself uses less transistors, but the access to it isn't anything like a DFF, no clock, no D, no Q. I'm sure it could be made to behave like a DFF but then it will probably end up with just as many transistors.
 
  • Like
Reactions: shaiko

    shaiko

    Points: 2
    Helpful Answer Positive Rating
I'm clearly missing something - this is how I see it:

"Access" can be divided into 2 types:

1. Read access - no such thing really. If the memory content is simply a voltage level, then we should be able to connect a wire to the point of storage and consider it being constantly and permanently read accessed. Just like connecting a wire to the Q pin of a DFF. Would you agree?

2. Write access.
Code:
process 
begin
  if rising_edge ( clock ) then 
    if write = '1' then
      Y<= X ;
    end if ;
  end if ;
end process ;
The above inffers RAM in Quartus. Almost the same behavioural description as a DFF (add an asynchronous reset and it becomes a DFF). Very similar "write access"...

What am I missing ?
Is #1 wrong?
Is #2 wrong?
 

I'm pretty sure you're understanding of both #1 and #2 are incorrect.

You read an SRAM cell using a sense amplifier (we aren't talking about digital logic levels).

The inferred RAM in Quartus is because that is the way the tool interprets the code. It doesn't represent the way you have to inject (write) the value into the memory cell of an SRAM. An SRAM cell doesn't even require a clock, but Altera parts do require a clock to infer RAMs as there are DFFs built into the RAM to make the SRAM synchronous.

- - - Updated - - -

You might want to look at this thread, a DFF doesn't require as many transistors as you think.

- - - Updated - - -

Here is something really interesting posted on stack exchange on DFF designs. I especially found the three patents interesting.
 
  • Like
Reactions: shaiko

    shaiko

    Points: 2
    Helpful Answer Positive Rating
So...although RAM as a cell is more economical then a DFF it requires quite a bit of "service hardware" around it. This overhead becomes worthwhile only when the amount of memory is big - hence block RAM...

Then what is the purpose of Distributed RAM in FPGA?
If it also requires "service logic" but the price isn't shared among a lot of memory cells - why bother?
 

Then what is the purpose of Distributed RAM in FPGA?
If it also requires "service logic" but the price isn't shared among a lot of memory cells - why bother?

Distributed RAM always exists as it's actually the configuration memory contents for a LUT. The logic to read the LUT memory already exists they just added the hooks into the write circuit to allow the fabric to write to the memory.
 
  • Like
Reactions: shaiko

    shaiko

    Points: 2
    Helpful Answer Positive Rating
Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top