cancel
Showing results for 
Search instead for 
Did you mean: 

ENET_DMA->RXSTR register problem

dolgov
Associate II
Posted on November 09, 2009 at 08:29

ENET_DMA->RXSTR register problem

5 REPLIES 5
dolgov
Associate II
Posted on May 17, 2011 at 09:59

Hello,

I've a STR912 running under eCos. To test ethernet I've set up a UDP echo server using lwIP.

The problem is that after a certain number oof packets the DMA_ENABLE bit in the ENET_DMA->RXSTR register is deleted.

Did anyone have a similar problem to mine? What could be the reasons?

Regards.

tomas23
Associate II
Posted on May 17, 2011 at 09:59

Are there some error registers or flags around the ENET DMA? If so, please check them. Check the destination address, too.

Please check whether the buffer allocation doesn't run out of RAM => this may stop the DMA.

Don't you update the descriptors before they get updated by DMA?

dolgov
Associate II
Posted on May 17, 2011 at 09:59

my prog uses enet-functions provided by ST (91x_enet.c), so i think that the registers will be set in a correct way. (i also took a look on it and couldn`t find anything suspicious)

i think the DMA fails because of the memory. i will try to enlarge the ringbuffer i use to receive packets.

i will then report if it worked

dolgov
Associate II
Posted on May 17, 2011 at 09:59

Hello again,

enlarging the ring buffer did not help.

I tried to set the CONT_EN-bit in the RXCR and the TXCR register but when I read these registers the bit is disabled.

dolgov
Associate II
Posted on May 17, 2011 at 09:59

It seems to work now.

The problem was that I didn't set up the PHY device properly. There still was the old libraray so I only implemented the new version and it worked.

My registers look that way now:

ENET_RXSTR: 10001

ENET_RXCR: 45f0

ENET_TXSTR: 10020

ENET_TXCR: 4041