Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > VHDL > Interfacing to SRAM

Reply
Thread Tools

Interfacing to SRAM

 
 
john
Guest
Posts: n/a
 
      11-16-2004
Hello,



I am trying to interface a Dual Port RAM (SRAM) with a CPLD. The
memory part number is

IDT 70T633/1S. Now, I am generating the Read /Write cycles for the
memory but i am unable to

see the correct data!

My question is that I am not seeing the data because Am I not
holding the data long enough inside

the CPLD or some other VHDL reason...... Please Advice!

I reduced the code to just write one memory location and reading the
same memory location..


-- Reading Program

Process ( State_A )

Begin
Case State_A is

When A0=>

LBL <='1';
UBL <='1';
CE0 <='1';
CE1 <='0';
Read_write <='1';
Output_Enable <='1';
Data_bus <="ZZZZZZZZZZZZZZ";
Address_bus <="0000000000000000111";

nextstate_A <= A1;


When A1=>
LBL <='0';
UBL <='0';
CE0 <='0';
CE1 <='1';
Read_write <='1';
Output_Enable <='0';
Address_bus <="0000000000000000111";

nextstate_A <= A0



When others =>

nextstate_A <= A0;

End Case;

End Process;

------------------------------------------------------------------------------------------------------------
-- Writing Program

Process (State2)
Begin

Case State2 is

When G0=>

UBL <='1';
LBL <='1';
CE0 <='1';
CE1 <='0';
Output_Enable <='1';
Read_write <='1';
Data_Bus <= "01010101010101";
Address_bus <="0000000000000000111";



nextstate2 <=G1;

When G1=>

Data_Bus <= "01010101010101";
Address_bus <="0000000000000000111";
UBL <='1';
LBL <='1';
CE0 <='1';
CE1 <='0';
Output_Enable <='1';
Read_write <='1';

nextstate2 <=G2;

When G2=>

Address_bus <="0000000000000000111";
Data_Bus <= "01010101010101";
UBL <='0';
LBL <='0';
CE0 <='0';
CE1 <='1';
Output_Enable <='1';
Read_write <='0';

nextstate2 <=G1;

When others =>

nextstate2 <=G0;

End case;
End Process;


Regards
john
 
Reply With Quote
 
 
 
 
Neo
Guest
Posts: n/a
 
      11-17-2004
Hi John,
Its difficult to say just by looking at the code whether the
write/read will be successful to the memory block. If I may suggest,
have you tried simulating with its verilog or vhdl models.
 
Reply With Quote
 
 
 
 
ALuPin
Guest
Posts: n/a
 
      11-17-2004
Hi,

you make the assignment
nextstate_A <= A1;

Do you have a clocked process you did not show to us?

Rgds
André


(john) wrote in message news:<. com>...
> Hello,
>
>
>
> I am trying to interface a Dual Port RAM (SRAM) with a CPLD. The
> memory part number is
>
> IDT 70T633/1S. Now, I am generating the Read /Write cycles for the
> memory but i am unable to
>
> see the correct data!
>
> My question is that I am not seeing the data because Am I not
> holding the data long enough inside
>
> the CPLD or some other VHDL reason...... Please Advice!
>
> I reduced the code to just write one memory location and reading the
> same memory location..
>
>
> -- Reading Program
>
> Process ( State_A )
>
> Begin
> Case State_A is
>
> When A0=>
>
> LBL <='1';
> UBL <='1';
> CE0 <='1';
> CE1 <='0';
> Read_write <='1';
> Output_Enable <='1';
> Data_bus <="ZZZZZZZZZZZZZZ";
> Address_bus <="0000000000000000111";
>
> nextstate_A <= A1;
>
>
> When A1=>
> LBL <='0';
> UBL <='0';
> CE0 <='0';
> CE1 <='1';
> Read_write <='1';
> Output_Enable <='0';
> Address_bus <="0000000000000000111";
>
> nextstate_A <= A0
>
>
>
> When others =>
>
> nextstate_A <= A0;
>
> End Case;
>
> End Process;
>
> ------------------------------------------------------------------------------------------------------------
> -- Writing Program
>
> Process (State2)
> Begin
>
> Case State2 is
>
> When G0=>
>
> UBL <='1';
> LBL <='1';
> CE0 <='1';
> CE1 <='0';
> Output_Enable <='1';
> Read_write <='1';
> Data_Bus <= "01010101010101";
> Address_bus <="0000000000000000111";
>
>
>
> nextstate2 <=G1;
>
> When G1=>
>
> Data_Bus <= "01010101010101";
> Address_bus <="0000000000000000111";
> UBL <='1';
> LBL <='1';
> CE0 <='1';
> CE1 <='0';
> Output_Enable <='1';
> Read_write <='1';
>
> nextstate2 <=G2;
>
> When G2=>
>
> Address_bus <="0000000000000000111";
> Data_Bus <= "01010101010101";
> UBL <='0';
> LBL <='0';
> CE0 <='0';
> CE1 <='1';
> Output_Enable <='1';
> Read_write <='0';
>
> nextstate2 <=G1;
>
> When others =>
>
> nextstate2 <=G0;
>
> End case;
> End Process;
>
>
> Regards
> john

 
Reply With Quote
 
john
Guest
Posts: n/a
 
      11-18-2004
Hi,
Yes, I have a clocked process!


Thanks
john

(ALuPin) wrote in message news:<. com>...
> Hi,
>
> you make the assignment
> nextstate_A <= A1;
>
> Do you have a clocked process you did not show to us?
>
> Rgds
> André
>
>
> (john) wrote in message news:<. com>...
> > Hello,
> >
> >
> >
> > I am trying to interface a Dual Port RAM (SRAM) with a CPLD. The
> > memory part number is
> >
> > IDT 70T633/1S. Now, I am generating the Read /Write cycles for the
> > memory but i am unable to
> >
> > see the correct data!
> >
> > My question is that I am not seeing the data because Am I not
> > holding the data long enough inside
> >
> > the CPLD or some other VHDL reason...... Please Advice!
> >
> > I reduced the code to just write one memory location and reading the
> > same memory location..
> >
> >
> > -- Reading Program
> >
> > Process ( State_A )
> >
> > Begin
> > Case State_A is
> >
> > When A0=>
> >
> > LBL <='1';
> > UBL <='1';
> > CE0 <='1';
> > CE1 <='0';
> > Read_write <='1';
> > Output_Enable <='1';
> > Data_bus <="ZZZZZZZZZZZZZZ";
> > Address_bus <="0000000000000000111";
> >
> > nextstate_A <= A1;
> >
> >
> > When A1=>
> > LBL <='0';
> > UBL <='0';
> > CE0 <='0';
> > CE1 <='1';
> > Read_write <='1';
> > Output_Enable <='0';
> > Address_bus <="0000000000000000111";
> >
> > nextstate_A <= A0
> >
> >
> >
> > When others =>
> >
> > nextstate_A <= A0;
> >
> > End Case;
> >
> > End Process;
> >
> > ------------------------------------------------------------------------------------------------------------
> > -- Writing Program
> >
> > Process (State2)
> > Begin
> >
> > Case State2 is
> >
> > When G0=>
> >
> > UBL <='1';
> > LBL <='1';
> > CE0 <='1';
> > CE1 <='0';
> > Output_Enable <='1';
> > Read_write <='1';
> > Data_Bus <= "01010101010101";
> > Address_bus <="0000000000000000111";
> >
> >
> >
> > nextstate2 <=G1;
> >
> > When G1=>
> >
> > Data_Bus <= "01010101010101";
> > Address_bus <="0000000000000000111";
> > UBL <='1';
> > LBL <='1';
> > CE0 <='1';
> > CE1 <='0';
> > Output_Enable <='1';
> > Read_write <='1';
> >
> > nextstate2 <=G2;
> >
> > When G2=>
> >
> > Address_bus <="0000000000000000111";
> > Data_Bus <= "01010101010101";
> > UBL <='0';
> > LBL <='0';
> > CE0 <='0';
> > CE1 <='1';
> > Output_Enable <='1';
> > Read_write <='0';
> >
> > nextstate2 <=G1;
> >
> > When others =>
> >
> > nextstate2 <=G0;
> >
> > End case;
> > End Process;
> >
> >
> > Regards
> > john

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Simulation Model for SRAM ALuPin VHDL 2 02-22-2004 03:05 AM
How do I model a 6T SRAM cell in VHDL KM VHDL 1 12-05-2003 08:30 PM
Reading back SRAM content via JTAG? moe VHDL 3 11-16-2003 02:22 PM
SRAM vs Cache Michael VHDL 4 09-22-2003 08:31 AM
write data to Sram and then read to PC sarah VHDL 1 08-13-2003 10:08 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57