Forum Discussion
Altera_Forum
Honored Contributor
14 years ago --- Quote Start --- You might have an easier time using this instead: http://www.alterawiki.com/wiki/modular_sgdma --- Quote End --- Yeah the UP core has a ST port into the core and another ST port coming out of it. Before I slot the ST component in between the read and write masters and assuming that my original data is generated by the CPU and stored in the SDRAM, and the result after going through the UP core will also go in the SDRAM, do I need: - modular dispatcher (MM to MM), Read master and Write master like in the example file or - modular dispatcher (MM to ST) & Read master, and modular dispatcher (ST to MM) & Write master My feeling is that it is the first option but I just want a confirmation because it is my first time using a DMA type component. If suppose instead I had used the standard SG-DMA component available in SOPC, would I then need two SG-DMA components, i.e. MM to ST at transmission and ST to MM at receiver? OK, in the meantime I tried to adapt the example given in the website to my DE2-115 board but the msgdma keeps spinning and my NIOS program gets stuck at loop 'while (sgdma_interrupt_fired == 0) {}'. How do I find the cause of the error? Could this error due to the fact that I have not fully copied the SOPC example design file because I have not used the Avalon-MM Pipeline Bridge and the 'DDR SDRAM Contorller with ALTMEMPHY'? I just have a CPU, SDRAM controller and the Modular SGDMA components (all running at same clock rate) at the moment. I did not add those components because I don't understand their purpose but if needed, I will do it. Now assuming I get that example file working after adding all these extra components and clocks, what changes will I need to bring to the parameter setttings of my Read Master and Write Master components if the data to be transferred is now a 3 x 12 array of u8 integers, i.e. 36 bytes, defined as below in my C code. alt_u8 my_2d_array[3][12] ; //Fill in the values source_buffer = &(my_2d_array[0][0]); The Data Width setting goes to 8. How about Length Width and FIFO Depth, and the other settings? What are the major changes in the example 'main.c' file to I need to do? Thanks