|
Hi,
I am using the EZ kit lite adsp21061, and I would like to use the DMA in
handshake mode. In my software code, I am using the II6, II7 IM6,IM7and C6, C7
registers.
When I send some DMAR1 or DMAR2, my C7 or C6 decrements to 0, but I have
never interrupt. Moreover, in the DMAC7 or DMAC6 registers, the externel port
FIFO buffer is full, in spite of I flush.
do you have any suggestions ?
thank you.
My software code is:
#define N 32
#include "def21060.h" .segment/dm seg_dmda;
.VAR Dest[N]; .endseg;
.segment/pm seg_pmco;
.VAR buff_dest; .VAR buff_N; Reset: r1=0;
r0t ; pm(buff_dest)=r0; r0=N ; pm(buff_N)=r0 ; r0=0x0400 ; dm(DMAC7)=r0 ; r0=pm(buff_dest);
dm(II7)=r0 ; r0=1 ; dm(IM7)=r0 ; r0=pm(buff_N) ; dm (C7)=r0 ; r0=0x0405 ;
dm(DMAC7)=r0 ; bit set mode1 IRPTEN ; bit set imask EP1I|TMZHI|IRQ0I|IRQ1I; wait: idle ; jump wait ; file://*************************************************************************
DMA7_service: r0=0x0400 ;
dm(DMAC7)=r0 ; r0=0x2000; file://flush dm(DMAC7)=r0 ; r0t;
dm(II7)=r0 ; r0=1 ; dm(IM7)=r0 ; r0=N ; dm (C7)=r0 ; r0=0x0405 ;
dm(DMAC7)=r0 ; rti;
|
dma transfer handshake mode
Started by ●July 16, 2003
Reply by ●July 16, 20032003-07-16
|
On Wed, 16 Jul 2003, [iso-8859-1] claire Simon wrote: > I am using the EZ kit lite adsp21061, and I would like to use the DMA in handshake mode. In my software code, I am using the II6, II7 IM6,IM7and C6, C7 registers. > When I send some DMAR1 or DMAR2, my C7 or C6 decrements to 0, but I have never interrupt. Moreover, in the DMAC7 or DMAC6 registers, the externel port FIFO buffer is full, in spite of I flush. > do you have any suggestions ? Yeah, two things to try: the flush bit is 0x2000 not 0x400 (or you may not have included a flush here). For interrupts to be generated with external ports, both C7 and EC7 must go to zero. In your example you don't set EC7, so it may not be the right count. If you are not packing, then EC7 = C7 and EM7 = 1 = IM7. Since it is handshake mode, there is no EI7 to set, but you might want to clear it anyway. Patience, persistence, truth, Dr. mike |
Reply by ●July 18, 20032003-07-18
|
Hi,
thank you.
Now, it's working with the channel 7, but not with the channel 6.
Indeed, I'm using the EZkit 21061, and the kernel use the DMA6
interrupt.
How can I modify my software code ?
thank you in advance
It's the software code which is working with the channel 7:
.segment/pm seg_pmco;
.VAR buff_dest; .VAR buff_N; Reset: r1=0;
r2=0; r3t; r5=N ; r6=0x0405 ; b0=Cspy; m0=1; r03; r0=0x0400 ;
dm(DMAC7)=r0 ; r0=0x2000; {flush} dm(DMAC7)=r0 ; r0t; dm(II7)=r0 ; r0=1 ; dm(IM7)=r0 ; r0=1 ; dm (EM7)=r0 ; r0=N ; dm (C7)=r0 ; dm (EC7)=r0 ; r0=0x0405 ; dm(DMAC7)=r0 ; irptl =0; bit set mode2 FLG0O|FLG1O|FLG2O|TIMEN;
bit set mode2 IRQ0E|IRQ1E; bit clr astat FLG2 ; {allume} bit set imask EP1I|TMZHI|IRQ0I|IRQ1I; bit clr mode1 NESTM ; bit set mode1 IRPTEN ; r1=0; bit clr astat FLG0; nop;nop; bit set astat FLG0; nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop; nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop;nop; wait:
idle ; jump wait ; file://*************************************************************************
DMA7_service: r2=r2+1; dm(TOTO2)=r2; r0=0;
dm(DMAC7)=r0 ; dm(II7)=r3 ; dm(IM7)=r4 ; dm (EM7)=r4 ; dm (C7)=r5 ; dm (EC7)=r5 ; dm(DMAC7)=r6 ; rti;
|
Reply by ●July 18, 20032003-07-18
|
On Fri, 18 Jul 2003, [iso-8859-1] claire Simon wrote: > Hi, > > thank you. > Now, it's working with the channel 7, but not with the channel 6. Indeed, I'm using the EZkit 21061, and the kernel use the DMA6 interrupt. > How can I modify my software code ? > thank you in advance Did you move the external wires for the other DMAR lines? Did you change every 7->6? Enable EPI0 instead of EPI1? There's a lot of bits to flip, it only takes one wrong for the whole thing not to work! A good nights sleep before a double check of everything will probably help :-) Patience, persistence, truth, Dr. mike |
|
|
Reply by ●July 18, 20032003-07-18
|
Hi, If EP0I is used by the kernel, then it is difficult for your to use DMA6. There is a resource contention issue involved with it, because both the kernel and your code is trying to use the same interrupt. Think what happens when the interrupt occurs. Whose isr will it branch to....kernel or your code which is running above the kernel. If you can repalce the kernel isr address with your isr address in the interrupt vector table, then you have success. I had similar problem with IRQ2 -- uart intterupt. I removed the kernel, programed my code in a eeprom. No kernel no contention. Correct me if I am wrong Regards Liyju _______________________________________ Success is a journey not a destination. --- Mike Rosing <> wrote: > On Fri, 18 Jul 2003, [iso-8859-1] claire Simon > wrote: > > > Hi, > > > > thank you. > > Now, it's working with the channel 7, but not with > the channel 6. Indeed, I'm using the EZkit 21061, > and the kernel use the DMA6 interrupt. > > How can I modify my software code ? > > thank you in advance > > Did you move the external wires for the other DMAR > lines? Did you change > every 7->6? Enable EPI0 instead of EPI1? There's a > lot of bits to flip, > it only takes one wrong for the whole thing not to > work! A good nights > sleep before a double check of everything will > probably help :-) > > Patience, persistence, truth, > Dr. mike > > _____________________________________ > Note: If you do a simple "reply" with your email > client, only the author of this message will receive > your answer. You need to do a "reply all" if you > want your answer to be distributed to the entire > group. > > _____________________________________ > About this discussion group: > > To Join: Send an email to > To Post: Send an email to > > To Leave: Send an email to > Archives: http://groups.yahoo.com/group/adsp > > Other Groups: http://www.dsprelated.com/groups.php3 > ">http://docs.yahoo.com/info/terms/ __________________________________ |
|
|
Reply by ●July 19, 20032003-07-19
|
sir, i am working with 10 SHARC(ADSP-21060) proessors in multiprocessing mode. of which one processor is root(master) which is called as Level 0 processor.there are three processors(slave) to this master processor which constitute level 1 processor and each level1 processor has two slave processors each constituting Level3 processors. i am working for GPS signal simulation. the objective is ,i have booted all the 10 processors through link port.but the application program that has to b ported in the level 1 processors exeeds 2MB.we know that the processors onchip memory is 4 MB but divided in to 2 blocks (each 2 MB). my questin is How can i use the second block in runtime to store the remaining code beyond 2 MB. plz suggest me at the earliest. thanking u satish(india) __________________________________ |
|
|
Reply by ●July 19, 20032003-07-19
|
On Fri, 18 Jul 2003, satish kumar wrote: > i am working with 10 SHARC(ADSP-21060) proessors in > multiprocessing mode. > > of which one processor is root(master) which is called > as Level 0 processor.there are three processors(slave) > to this master processor which constitute level 1 > processor and each level1 processor has two slave > processors each constituting Level3 processors. > > i am working for GPS signal simulation. > the objective is ,i have booted all the 10 processors > through link port.but the application program that has > to b ported in the level 1 processors exeeds 2MB.we > know that the processors onchip memory is 4 MB but > divided in to 2 blocks (each 2 MB). > my questin is How can i use the second block in > runtime to store the remaining code beyond 2 MB. If should not be a problem, the memory range is basicly continuous. You can make it all PM if you want to, but you'll have to figure out where to store data. You can split the second block into part pm and part dm too. It's very flexable! Patience, persistence, truth, Dr. mike |
Reply by ●July 21, 20032003-07-21
|
Hi, You're right. The kernel use EPOI, and I think there is a contention, and that's why it isn't working. But how can i do ? I don't know how to move the adress' kernel in the interrupt vector table. thank you in advance. --- In , Liyju Janardhan <liyju_j@y...> wrote: > Hi, > > If EP0I is used by the kernel, then it is difficult > for your to use DMA6. There is a resource contention > issue involved with it, because both the kernel and > your code is trying to use the same interrupt. > > Think what happens when the interrupt occurs. Whose > isr will it branch to....kernel or your code which > is running above the kernel. > > If you can repalce the kernel isr address with your > isr address in the interrupt vector table, then you > have success. > > I had similar problem with IRQ2 -- uart intterupt. > I removed the kernel, programed my code in a eeprom. > No kernel no contention. > > Correct me if I am wrong > > Regards > > Liyju > _______________________________________ > Success is a journey not a destination. > --- Mike Rosing <eresrch@e...> wrote: > > On Fri, 18 Jul 2003, [iso-8859-1] claire Simon > > wrote: > > > > > Hi, > > > > > > thank you. > > > Now, it's working with the channel 7, but not with > > the channel 6. Indeed, I'm using the EZkit 21061, > > and the kernel use the DMA6 interrupt. > > > How can I modify my software code ? > > > thank you in advance > > > > Did you move the external wires for the other DMAR > > lines? Did you change > > every 7->6? Enable EPI0 instead of EPI1? There's a > > lot of bits to flip, > > it only takes one wrong for the whole thing not to > > work! A good nights > > sleep before a double check of everything will > > probably help :-) > > > > Patience, persistence, truth, > > Dr. mike > > > > > > > > _____________________________________ > > Note: If you do a simple "reply" with your email > > client, only the author of this message will receive > > your answer. You need to do a "reply all" if you > > want your answer to be distributed to the entire > > group. > > > > _____________________________________ > > About this discussion group: > > > > To Join: Send an email to > > > > > > To Post: Send an email to > > > > To Leave: Send an email to > > > > > > Archives: http://groups.yahoo.com/group/adsp > > > > Other Groups: http://www.dsprelated.com/groups.php3 > > > > > > ">http://docs.yahoo.com/info/terms/ > > > > __________________________________ > |
|
|
Reply by ●July 21, 20032003-07-21
|
Hi, Changing the isr address in int vect table is simple. Below is an example of IRQ1 intterupt. My program is written in C, irq1handler is the isr whose address I am putting at location 0x2001c. asm("#define IRQ1IntVectorAddr 0x2001c"); asm(".var OrigIRQ1IntVectorContents;"); asm(".global _irq1handler;"); asm("PX = PM (IRQ1IntVectorAddr);"); asm("PM (OrigIRQ1IntVectorContents) = PX;"); asm("PX=PM(PickCode);"); asm("PM(IRQ1IntVectorAddr)=PX;"); if(flag==1){ asm("PickCode:"); asm("JUMP _irq1handler;"); } Remember to initialise flag to zero. Condition flag==1 is never true in the program, still the compiler does the thing what we wanted. Its interesting to note the register values, the content of location 0x2001c, before and after stepping up through the above code. Let me know if the above code works for you. Regards Liyju --- raicles <> wrote: > Hi, > > You're right. The kernel use EPOI, and I think there > is a contention, > and that's why it isn't working. > But how can i do ? > I don't know how to move the adress' kernel in the > interrupt vector > table. > thank you in advance. > > --- In , Liyju Janardhan > <liyju_j@y...> wrote: > > Hi, > > > > If EP0I is used by the kernel, then it is > difficult > > for your to use DMA6. There is a resource > contention > > issue involved with it, because both the kernel > and > > your code is trying to use the same interrupt. > > > > Think what happens when the interrupt occurs. > Whose > > isr will it branch to....kernel or your code which > > is running above the kernel. > > > > If you can repalce the kernel isr address with > your > > isr address in the interrupt vector table, then > you > > have success. > > > > I had similar problem with IRQ2 -- uart intterupt. > > I removed the kernel, programed my code in a > eeprom. > > No kernel no contention. > > > > Correct me if I am wrong > > > > Regards > > > > Liyju > > _______________________________________ > > Success is a journey not a destination. > > > > > > --- Mike Rosing <eresrch@e...> wrote: > > > On Fri, 18 Jul 2003, [iso-8859-1] claire Simon > > > wrote: > > > > > > > Hi, > > > > > > > > thank you. > > > > Now, it's working with the channel 7, but not > with > > > the channel 6. Indeed, I'm using the EZkit > 21061, > > > and the kernel use the DMA6 interrupt. > > > > How can I modify my software code ? > > > > thank you in advance > > > > > > Did you move the external wires for the other > DMAR > > > lines? Did you change > > > every 7->6? Enable EPI0 instead of EPI1? > There's a > > > lot of bits to flip, > > > it only takes one wrong for the whole thing not > to > > > work! A good nights > > > sleep before a double check of everything will > > > probably help :-) > > > > > > Patience, persistence, truth, > > > Dr. mike > > > > > > > > > > > > _____________________________________ > > > Note: If you do a simple "reply" with your email > > > client, only the author of this message will > receive > > > your answer. You need to do a "reply all" if > you > > > want your answer to be distributed to the entire > > > group. > > > > > > _____________________________________ > > > About this discussion group: > > > > > > To Join: Send an email to > > > > > > > > > To Post: Send an email to > > > > > > To Leave: Send an email to > > > > > > > > > Archives: http://groups.yahoo.com/group/adsp > > > > > > Other Groups: > http://www.dsprelated.com/groups.php3 > > > > > > > > > ">http://docs.yahoo.com/info/terms/ > > > > > > > > > > > > __________________________________ > > > > _____________________________________ > Note: If you do a simple "reply" with your email > client, only the author of this message will receive > your answer. You need to do a "reply all" if you > want your answer to be distributed to the entire > group. > > _____________________________________ > About this discussion group: > > To Join: Send an email to > To Post: Send an email to > > To Leave: Send an email to > Archives: http://groups.yahoo.com/group/adsp > > Other Groups: http://www.dsprelated.com/groups.php3 > ">http://docs.yahoo.com/info/terms/ __________________________________ |
|
|
Reply by ●July 23, 20032003-07-23
|
hi, thanks you . Now it's working. my software code is: segment/pm seg_pmco; file://************************************************************************* _ep0ihandler: r2=r2+1; dm(TOTO2)=r2; r0=0; dm(DMAC6)=r0 ; dm(II6)=r3 ; dm(IM6)=r4 ; dm (EM6)=r4 ; dm (C6)=r5 ; dm (EC6)=r5 ; dm(DMAC6)=r6 ; r0 =flag; PX = PM (EP0IIntVectorAddr); PM (OrigEP0IIntVectorContents) = PX; file://PX=PM(PickCode); PM(EP0IIntVectorAddr)=PX; r0=r0+1; file://PickCode: if eq JUMP _ep0ihandler; rti; regards Liyju Janardhan <> wrote: Hi, Changing the isr address in int vect table is simple. Below is an example of IRQ1 intterupt. My program is written in C, irq1handler is the isr whose address I am putting at location 0x2001c. asm("#define IRQ1IntVectorAddr 0x2001c"); asm(".var OrigIRQ1IntVectorContents;"); asm(".global _irq1handler;"); asm("PX = PM (IRQ1IntVectorAddr);"); asm("PM (OrigIRQ1IntVectorContents) = PX;"); asm("PX=PM(PickCode);"); asm("PM(IRQ1IntVectorAddr)=PX;"); if(flag==1){ asm("PickCode:"); asm("JUMP _irq1handler;"); } Remember to initialise flag to zero. Condition flag==1 is never true in the program, still the compiler does the thing what we wanted. Its interesting to note the register values, the content of location 0x2001c, before and after stepping up through the above code. Let me know if the above code works for you. Regards Liyju --- raicles wrote: > Hi, > > You're right. The kernel use EPOI, and I think there > is a contention, > and that's why it isn't working. > But how can i do ? > I don't know how to move the adress' kernel in the > interrupt vector > table. > thank you in advance. > > --- In , Liyju Janardhan > wrote: > > Hi, > > > > If EP0I is used by the kernel, then it is > difficult > > for your to use DMA6. There is a resource > contention > > issue involved with it, because both the kernel > and > > your code is trying to use the same interrupt. > > > > Think what happens when the interrupt occurs. > Whose > > isr will it branch to....kernel or your code which > > is running above the kernel. > > > > If you can repalce the kernel isr address with > your > > isr address in the interrupt vector table, then > you > > have success. > > > > I had similar problem with IRQ2 -- uart intterupt. > > I removed the kernel, programed my code in a > eeprom. > > No kernel no contention. > > > > Correct me if I am wrong > > > > Regards > > > > Liyju > > _______________________________________ > > Success is a journey not a destination. > > > > > > --- Mike Rosing wrote: > > > On Fri, 18 Jul 2003, [iso-8859-1] claire Simon > > > wrote: > > > > > > > Hi, > > > > > > > > thank you. > > > > Now, it's working with the channel 7, but not > with > > > the channel 6. Indeed, I'm using the EZkit > 21061, > > > and the kernel use the DMA6 interrupt. > > > > How can I modify my software code ? > > > > thank you in advance > > > > > > Did you move the external wires for the other > DMAR > > > lines? Did you change > > > every 7->6? Enable EPI0 instead of EPI1? > There's a > > > lot of bits to flip, > > > it only takes one wrong for the whole thing not > to > > > work! A good nights > > > sleep before a double check of everything will > > > probably help :-) > > > > > > Patience, persistence, truth, > > > Dr. mike > > > > > > > > > > > > _____________________________________ > > > Note: If you do a simple "reply" with your email > > > client, only the author of this message will > receive > > > your answer. You need to do a "reply all" if > you > > > want your answer to be distributed to the entire > > > group. > > > > > > _____________________________________ > > > About this discussion group: > > > > > > To Join: Send an email to > > > > > > > > > To Post: Send an email to > > > > > > To Leave: Send an email to > > > > > > > > > Archives: http://groups.yahoo.com/group/adsp > > > > > > Other Groups: > http://www.dsprelated.com/groups.php3 > > > > > > > > > ">http://docs.yahoo.com/info/terms/ > > > > > > > > > > > > __________________________________ > > > > _____________________________________ > Note: If you do a simple "reply" with your email > client, only the author of this message will receive > your answer. You need to do a "reply all" if you > want your answer to be distributed to the entire > group. > > _____________________________________ > About this discussion group: > > To Join: Send an email to > To Post: Send an email to > > To Leave: Send an email to > Archives: http://groups.yahoo.com/group/adsp > > Other Groups: http://www.dsprelated.com/groups.php3 > ">http://docs.yahoo.com/info/terms/ __________________________________ _____________________________________ Note: If you do a simple "reply" with your email client, only the author of this message will receive your answer. You need to do a "reply all" if you want your answer to be distributed to the entire group. _____________________________________ About this discussion group: To Join: Send an email to To Post: Send an email to To Leave: Send an email to Archives: http://groups.yahoo.com/group/adsp Other Groups: http://www.dsprelated.com/groups.php3 ">http://docs.yahoo.com/info/terms/ --------------------------------- |
|
|






