Problem with DMA interrupt

OP #1174168
Hello,

I'am using the AT91SAM9RL64 Eval Board. To get to know USB, I extended
the  USB-Example "usb-device-core-project-1.4-at91sam9rl-ek" from the
ATMEL homepage.

I extended the configuration descriptor with two endpoint descriptors,
one bulk in- EP (1) and one bulk out EP (6). The size of the endpoints
is 512 byte. DMA is activated.

For testing I call the USBD_Write- function with the following
parameters:
USBD_Write( 0x1,&data,512,(TransferCallback)usbdWriteCallback,0);

Directly after this, my Callback- function is executed, because an
interrupt is triggered by the DMA Channel1, but I didn't read Data by
the host.

In my opinion this interrupt should only be triggert, when the host
read's data. Do you know a possible reason for this behavior? What I
have to consider?

On the host I use the LibUsb-Win32 driver/library.

Thx
Torsten
Moderator #1174169
Maybe you can compare your code with the cdc-serial project also in the
software-package. It also sets up bulk-endpoints and descriptors are
included. It might be easier to adapt this example to your needs than to
add code to the core-example.

Reply

A question of your own? This thread is over 18 years old. Ask it in a thread of its own – more people read along there, and it gets answered more often and sooner.

Start a new thread

A fix, an addition or feedback on this thread? Then reply here.

Formatting
  • [c]C-Code[/c]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]
  • [[Title]] – link to an article
  • Link to another post: right-click its post ID (#8078628), copy the address, paste it into the text

More about formatting

Post long source code as an attachment, not in the text.

Already registered? Log in

Not shown to anyone. We send you a link; your post appears once you confirm it there.

By submitting you create a free account and accept the terms of use.