Hey all, I am trying to access external memory to the ADSP-21992 EZ-KIT. I am using the C libraries that come with VisualDSP++. I can not get A16 line to be high when i do an external access. Here is an example of the code i am using. page?; temp=external_memory_read(page, 0); I would expect this to place a 1 (high) on my external address A(16) line. instead I am getting the A(16)=0 (low): with page = 3f this is my address bus msb A19 LSB A0 1110 0000 0000 0000 0000 This is making it impossible for me to access certain memory locations. Has anyone experienced this problem before? Using the code pasted above, should i see a A(16) go high??? Thank you in advance for any information anyone can give me. Sincerely, ED |
|
ADSP 21992 External flash access problems
Started by ●April 21, 2004
Reply by ●April 21, 20042004-04-21
On Wed, 21 Apr 2004, weird_ed_edison wrote: > I am trying to access external memory to the > ADSP-21992 EZ-KIT. I am using the C libraries that > come with VisualDSP++. I can not get A16 line to be > high when i do an external access. Here is an example > of the code i am using. > > page?; > temp=external_memory_read(page, 0); > > I would expect this to place a 1 (high) on my external > address A(16) line. instead I am getting the A(16)=0 > (low): > > with page = 3f this is my address bus > msb A19 LSB A0 > 1110 0000 0000 0000 0000 > > This is making it impossible for me to access certain > memory locations. Has anyone experienced this problem > before? Using the code pasted above, should i see a > A(16) go high??? > > Thank you in advance for any information anyone can > give me. first check to see if A16 is shorted to ground with power off and an ohm meter. See if you need a pullup on that line, and then try setting up a counting program that will toggle a16 up and down every few cycles. I don't have a clue, but it could be a hardware problem and not software, so check that first. Once you know it's not hardware, just beat on it with software until it works :-) Patience, persistence, truth, Dr. mike |
|
Reply by ●April 23, 20042004-04-23
hello again, I tested the address lines with some ASM code and they appear to be working. So the hardware is functional. However, that still leaves the problem of the C code not working. Has anyone tried to access boot flash memory with the ADSP21992 EZ Eval kit? I'm not having luck with the external_memory_read(page, address) funtion that is supplied with visualdsp++. I know the flash's select line (BMS)is being activated (logic low), but I cannot get the page number sent into the function to toggle the high order address lines (A16-19) correctly. Thank you in advance for any assistance, ED P.S. Thank you Dr. Mike for your earlier assistance --- In , Mike Rosing <eresrch@e...> wrote: > On Wed, 21 Apr 2004, weird_ed_edison wrote: > > > I am trying to access external memory to the > > ADSP-21992 EZ-KIT. I am using the C libraries that > > come with VisualDSP++. I can not get A16 line to be > > high when i do an external access. Here is an example > > of the code i am using. > > > > page?; > > temp=external_memory_read(page, 0); > > > > I would expect this to place a 1 (high) on my external > > address A(16) line. instead I am getting the A(16)=0 > > (low): > > > > with page = 3f this is my address bus > > msb A19 LSB A0 > > 1110 0000 0000 0000 0000 > > > > This is making it impossible for me to access certain > > memory locations. Has anyone experienced this problem > > before? Using the code pasted above, should i see a > > A(16) go high??? > > > > Thank you in advance for any information anyone can > > give me. > > first check to see if A16 is shorted to ground with power off and an ohm > meter. See if you need a pullup on that line, and then try setting > up a counting program that will toggle a16 up and down every few cycles. > > I don't have a clue, but it could be a hardware problem and not software, > so check that first. Once you know it's not hardware, just beat on it > with software until it works :-) > > Patience, persistence, truth, > Dr. mike |
|
Reply by ●April 23, 20042004-04-23
On Fri, 23 Apr 2004, weird_ed_edison wrote: > hello again, > > I tested the address lines with some ASM code and they appear to be > working. So the hardware is functional. However, that still leaves > the problem of the C code not working. > > Has anyone tried to access boot flash memory with the ADSP21992 EZ > Eval kit? I'm not having luck with the > external_memory_read(page, address) funtion that is supplied with > visualdsp++. I know the flash's select line (BMS)is being activated > (logic low), but I cannot get the page number sent into the function > to toggle the high order address lines (A16-19) correctly. I looked at the 21992 data sheet and it looks like it should have worked. Try a continuous loop and count page up from 1 to 254 with one address and see if the upper address lines actually change. If not, try it in assembler. It might be that function has a bug and isn't compiled right. Something like address = 0x5a6c; page = 1; while(1) { external_memory_read(page, address); page++; if (page > 254) page=1; } If it's not flying on all upper lines, the problem is pretty obvious. Patience, persistence, truth, Dr. mike |
|
Reply by ●April 26, 20042004-04-26
hello again, I tried the C code supplied below, here is the results of my test. If I build the project with debug mode, and have atleast 1 breakpoint, in the code prior to the loop (mine is above and outside the loop), then it works, i see all the addresses i am supposed to. If i do not have a breakpoint in the code before the loop it does not work. It also does not work if I download the code to flash and run it directly. Here is an example of the A(19)-A(16) i am seeing on the analyzer without breakpoint in code: highaddress: 0 2 4 6 8 a c e 0 2 4 ....... (a(16) never goes high) with breakpoint in code before start of loop: highaddress: 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 ...(a(16) toggles ) any suggestions? it seems like the debug code might initialize something that i am overlooking, but im not sure what it could be. Thank you in advance for any information, Sincerely, ED P.S. Thank you again Dr. Mike for the assistance --- In , Mike Rosing <eresrch@e...> wrote: > On Fri, 23 Apr 2004, weird_ed_edison wrote: > > > hello again, > > > > I tested the address lines with some ASM code and they appear to be > > working. So the hardware is functional. However, that still leaves > > the problem of the C code not working. > > > > Has anyone tried to access boot flash memory with the ADSP21992 EZ > > Eval kit? I'm not having luck with the > > external_memory_read(page, address) funtion that is supplied with > > visualdsp++. I know the flash's select line (BMS)is being activated > > (logic low), but I cannot get the page number sent into the function > > to toggle the high order address lines (A16-19) correctly. > > I looked at the 21992 data sheet and it looks like it should have > worked. Try a continuous loop and count page up from 1 to 254 with > one address and see if the upper address lines actually change. If not, > try it in assembler. It might be that function has a bug and isn't > compiled right. Something like > address = 0x5a6c; > page = 1; > while(1) > { > external_memory_read(page, address); > page++; > if (page > 254) page=1; > } > > If it's not flying on all upper lines, the problem is pretty obvious. > > Patience, persistence, truth, > Dr. mike |
|
Reply by ●April 26, 20042004-04-26
On Mon, 26 Apr 2004, weird_ed_edison wrote: > hello again, > > I tried the C code supplied below, here is the results of my test. > If > I build the project with debug mode, and have atleast 1 breakpoint, > in the code prior to the loop (mine is above and outside the loop), > then it works, i see all the addresses i am supposed to. If i do > not have a breakpoint in the code before the loop it does not work. > It also does not work if I download the code to flash and run it > directly. > > Here is an example of the A(19)-A(16) i am seeing on the analyzer > > without breakpoint in code: > highaddress: 0 2 4 6 8 a c e 0 2 4 ....... (a(16) never goes high) > > with breakpoint in code before start of loop: > highaddress: 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 ...(a(16) toggles ) > > any suggestions? it seems like the debug code might initialize > something that i am overlooking, but im not sure what it could be. I don't know anything about this processor, but it sure looks like a simple increment problem. Time to read the manual and find every reference to the external port and all registers. The bit you need to flip is burried in there someplace. And you get to find it! Patience, persistence, truth, Dr. mike |