heap_caps_malloc allocated address boundary
Posted: Mon Nov 18, 2019 4:08 pm
SPI Master states that when using DMA the transfer buffers be 32-bit aligned (staring from a 32-bit boundary and having a length of multiples of 4 bytes). The section of the API is "Write and Read Phases".
My question is if my transfer buffer is a void *heap_caps_malloc(size_t size, uint32_t caps) where size is multiple of 4 bytes and caps is MALLOC_CAP_DMA) is the buffer address guaranteed by be on a 32 bit boundary?
If not what can one do to guarantee the buffer address is on a 32 bit boundary?
My question is if my transfer buffer is a void *heap_caps_malloc(size_t size, uint32_t caps) where size is multiple of 4 bytes and caps is MALLOC_CAP_DMA) is the buffer address guaranteed by be on a 32 bit boundary?
If not what can one do to guarantee the buffer address is on a 32 bit boundary?