Can anyone replicate the issue?
My goal for now is to see anything on the SPI lines, there is no clock and no MOSI signal. (monitoring them with an oscilloscope).
I'm working with an SAMV71XPlained Ultra development board. I'm setting up the SPI Driver in START (see Image), with the code mentioned below. If I change the HAL dma driver to sync or async mode everything works fine.
This is the code of main.c
/* Initializes MCU, drivers and middleware */ atmel_start_init(); ams_system32_setupGPIO(PIN_ABCC_SPI_SS, GPIO_DIRECTION_OUT, GPIO_PULL_OFF); ams_system32_setupGPIO(PIN_LED, GPIO_DIRECTION_OUT, GPIO_PULL_OFF); gpio_set_pin_level(PIN_ABCC_SPI_SS, 0); SPI_0_example(); while(1){}
This is the relevant code of driver_examples.c (supplied by ATMEL START)
static uint8_t example_SPI_0[12] = "Hello World!"; struct io_descriptor *io; static void tx_complete_cb_SPI_0(struct _dma_resource *resource) { /* Transfer completed */ } void SPI_0_example(void) { spi_m_dma_get_io_descriptor(&SPI_0, &io); spi_m_dma_register_callback(&SPI_0, SPI_M_DMA_CB_TX_DONE, (spi_m_dma_cb_t)tx_complete_cb_SPI_0); spi_m_dma_enable(&SPI_0); io_write(io, example_SPI_0, 12); }
I surely did miss something, right?