Re: DMA on NeoMagic MM6+ under Windows CE 5.0

Tech-Archive recommends: Fix windows errors by optimizing your registry



Thanks very much for that advice, John.

Unfortunately, it turns out that the controller IS mapped correctly. So I
guess it's most likely to be an issue with the device itself... or the
ordering of register programming...

Anyone got any other ideas or info to add?

Best regards,

Paul


"John Eldridge [MSFT]" <johneld@xxxxxxxxxxxxxxxxxxxx> wrote in message
news:%23LmCyZDUGHA.3192@xxxxxxxxxxxxxxxxxxxxxxx
Hmmm... given the extent to which things seem to be not working, my first
concern would be that the VirtualAlloc/Copy that you've done isn't mapping
to the DMA controller after all.

If you know the physical address of your DMA controller registers, you can
map to it with VirtualCopy using the PAGE_PHYSICAL flag, but the address
must be shifted by 8 bits first.
I'm not familiar with the BeginRegisterAccess() function which may already
do this.

To confirm your mapping (from BeginRegisterAccess or VirtualCopy), you can
try calling LockPages with the LOCKFLAG_QUERY_ONLY flag to read back the
physical page mapping. See the LockPages documentation for more details.


--
Thanks,
John Eldridge
This posting is provided "AS IS" with no warranties, and confers no
rights.


"Paul G" <png@xxxxxxxx> wrote in message
news:44228d33$0$15790$14726298@xxxxxxxxxxxxxxxxxx
Hi All,

I'm trying to program DMA transfers on the NeoMagic MM6+ development
board, but can't get the transfers to take place.

The BSP doesn't currently have working DMA support, so I'm directly
programming the DMA controller. I've reserved two blocks of physical
memory in the config.bib file, and have mapped them in my code using
VirtualAlloc() and VirtualCopy(), but can't get the transfer to take
place. When writing to the channel configuration and channel control
registers, the values read back from them are not what was written to
them. For example, the transfer size is always 0. After enabling the
transfer, the destination memory is the same as before, and the
transfer-pending bit for the channel is still set - it doesn't appear
that any transfer has taken place. The current code is attempting to
perform a memory-to-memory copy. The DMA controller has been mapped using
the BSP's BeginRegisterAccess() routine, and this appears to work
correctly for the SSP controller, and also allows me to correctly read
back values written to the source and destination address registers.

The data*** doesn't make it clear if there is a specific sequence that
the DMA controller registers should be setup in, or provide any example
code.

Does anyone else have any experience of this platform, or any suggestions
on what I could try next?

Many thanks,

Paul





.


Quantcast