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.

[SOLVED] Altering some bits of a RAM location

Status
Not open for further replies.

rafimiet

Member level 5
Joined
May 21, 2015
Messages
94
Helped
1
Reputation
2
Reaction score
1
Trophy points
1,288
Activity points
2,364
Is it possible to alter specific bits of a RAM location?
For example: A RAM location has some contents(say 00011000), I need to add 4(100) to the contents i.e the contents will be changed to (00011100). Can I just directly invert 2nd bit of the RAM? The only way I know is to generate address of that location in one cycle, in next cycle we will get the contents and alter then and write them back. This consumes two clock cycles. If we can directly send '1' to the second bit location without altering the other bits, it may save a clock cycle(if possible)
 

if you're using block RAM I don't think you can do this. But you could create a RAM with bit-enables; it might take up a lot of resources.
 

The rams usually have byte enable signals, so you can modify individual bytes, but not bit enables.
At that level, the only way to alter is to read-modify-write.
 
Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top