DMA
-
Uart DMAMotor Control/BLDC 모터 제어 2025. 12. 2. 03:21
Setup the RCC and timer value. Usart with DMA will be used to reduce the CPU loads. ProsUsing DMA with UART2 allows long data transmissions to run in the background without blocking the CPU.UART DMA provides stable and reliable streaming, which is ideal for continuous debug logs and telemetry.Because UART has no strict timing requirements, DMA works smoothly and consistently without communica..
-
DMA를 이용한 2ch ADCAutonomous Lawn Mower/Raspberry pi & STM32 2025. 2. 8. 11:37
DMA는 CPU 개입 없이 ADC에서 메모리로 변환 결과를 자동으로 전송하여 센싱 데이터를 실시간으로 측정가능하여, 머신 보호기능 구현에 사용한다. DMA를 사용하면, CPU 부하를 감소하여 CPU가 중요한 의사 결정 및 제어 기능에 집중할수 있고, 지속적이고 고속의 데이터 전송을 통해 보호 기능을 신속하게 구현 가능하다. 또한 CPU를 사용하지 않기 때문에 칩 전력 소비가 감소된다. STM32F401 Ucleo 보드에서 ADC1의 IN10과 IN11을 이용한다. 이를 위해 필요한 설정은 아래와 같다. Continuous Conversion Mode를 enabled하고 DMA Continuous Requests를 enable한다. DMA continuous requests는 DMA 설정을 한 후에 선택 ..