Closed LuigiGiuffrida98 closed 3 months ago
@JuanSapriza, I modified the DMA HAL and the example_dma application, can you please review them?
To simulate example_dma
we need mora than 2 memory banks (the default). We should do something about that or the tests are going to fail. How was it being done before this? :thinking:
Well... it seems that since this change the mcu-gen is done properly with more banks for both the test_all
script and the CI... yet we have this situation where it does not work for certain applications.
@davideschiavone now that we have this, do you think we could have some sort of "description" at the top of applications that a script can parse and detect if you have the right configuration to do so and give a proper message?
for example, something like
// Copyright EPFL contributors.
// Licensed under the Apache License, Version 2.0, see LICENSE for details.
// SPDX-License-Identifier: Apache-2.0
@mcu-mem-banks 8
@mcu-mem-bank-il 2
@mcu-cpu cv32e40p
#include <stdio.h>
...
Then you run
make mcu-gen
make verilator-sim
make run-app-verilator PROJECT=my_project
> ERROR: You need 8 memory banks. You have generated 2 memory banks. Call make mcu-gen MEM_BANKS=8.
This should go to another issue... just thinking out loud
Apart from that, all tests passed. I will check the rest of the code for blasphemies
I took the liberty of changing a few words, but everything looks amazing.
Also tested example_dma_2d
and example_dma_external
and both return SUCCESS
.
✅ Good to merge on my side
This PR is to implement sign extension capability in the DMA data transfer if the data type of the destination is wider than the data type of the source.
This required the addition of little logic in the DMA and three control registers:
TODO: