STM32CubeMX (MCUs)

cancel
Showing results for 
Search instead for 
Did you mean: 

Forum Posts

dac+timer

void HAL_DAC_ConvCpltCallbackCh1(DAC_HandleTypeDef *hdac){ HAL_GPIO_TogglePin(START_OF_FRAME_GPIO_Port , START_OF_FRAME_Pin);}   uint32_t val[] = { 500, 600, 700, 800, 900, 1000, 1100, 1200, 1300, 1400};   HAL_DAC_Start_DMA(&hdac1, DAC_CHANNEL_1, val...

msg-1001059758846-54432.jpg
nimaltd by Senior
  • 211 Views
  • 3 replies
  • 0 kudos

Resolved! DAC-DMA and Timer

I am using timer 2 for trigger DAC and GPIO to generate analog and digital values.own timer 2 started with DMA to change ARR by an array.My GPIO array works well and starting to change from index 0 . but my DAC array start from Index 1. as you can se...

msg89464043-592494.jpg
nimaltd by Senior
  • 282 Views
  • 3 replies
  • 0 kudos

Resolved! Don't see DAC output for SINE wave with DMA

Hello,I followed a tutorial on how to generate a SINE wave using DAC and DMA that was really good. Logically it makes sense, you set up the DAC, set it to be triggered by a timer, then set up the DMA channel, set it to circular, and set it to use a t...

0693W00000FAgEAQA1.png 0693W00000FAgE5QAL.png 0693W00000FAgEFQA1.png 0693W00000FAgEeQAL.png
Kneepatch by Associate III
  • 1279 Views
  • 12 replies
  • 0 kudos

How to set 80MHZ frequency of SPI4 of STM32h745Kii

Hello I am working on stm32h745 controller, I am configuring the DAC SPI . For the DAC minimum frequency is 80 MHz. I want to set that frequency for SPI4 , but uanble to set how I can set the 80 Mhz frequency to SPI4. How can I set that if I set th...

0693W00000WI0IJQA1.png
MDeva.1 by Associate II
  • 248 Views
  • 2 replies
  • 0 kudos

Resolved! STM32F7 DACs enabling inconsistently upon powerup

Using STM32F765VG6TR, every time I power on the MCU, the two DACs are supposed to be set to constant output voltages of 2.4V and 0.8V. This happens inconsistently - sometimes it works, about 50/50 success rate. A few notes:If it isn't working, an MCU...

0693W00000QKcDbQAL.png 0693W00000QKcDWQA1.png 0693W00000QKcANQA1.png
Auhv by Associate II
  • 892 Views
  • 7 replies
  • 0 kudos

What fastest way to change the size of the DMA addressed by a peripheral. In particular the DAC? Stopping and starting the DAC using HAL_DAC_Stop_DMA and HAL_DAC_Start_DMA with a new Data Length takes up a lot of cycles if I use the CubeMX functions. I

I tried DMA_SetConfig after __HAL_DMA_DISABLE and clearly it is not enough.Incidentally my intention is not change the size of the DMA allocated area - rather the size of this region accessed by a peripheral

Resolved! STM32F103 & STM32F334 DAC + DMA Error.

STM32F334 DMA + DAC.After CubeMX: MX_DAC1_Init(); MX_DMA_Init(); MX_DAC2_Init();DAC2 working, DAC1 don't workingAfter editing: MX_DMA_Init(); MX_DAC1_Init(); MX_DAC2_Init();DAC1 and DAC2 working.The same for STM32F103. MX_DAC_Init(); MX_DMA_Init();Er...

SGorb by Associate
  • 388 Views
  • 2 replies
  • 0 kudos

Resolved! STM32G474 DMA cannot write to DAC_DHRx register

Hi everyone,I am using the NUCLEO-G474RE development board with STM32G474RE MCU​The ioc file is attached, and this is main function:int main(void) { /* USER CODE BEGIN 1 */   /* USER CODE END 1 */   /* MCU Configuration-------------------------...

0693W00000Ly1LTQAZ.png
Shen by Associate II
  • 428 Views
  • 3 replies
  • 0 kudos