STM32F103C8 PWM with DMA
Hello,
I'm using Timer_2 channel_1 PWM with DMA to generate the low polarity Pulse.
I set the value of PSC = 72, ARR = 2000 and Fosc = 72 MHz.
uint16_t TIM2_CCR1_Value[25] = {2100, 2100, 2100, 2100, 2100, 2100, 2100, 2100, 1200, 1500, 1500, 1500, 1500, 500, 1500, 1500, 1500, 1500, 500, 500, 1500, 1500, 1500, 1500, 500};
Explanation of above I given TIM2_CCR1 array value,
Free bit {2100, 2100, 2100, 2100, 2100, 2100, 2100, 2100} = {0, 0, 0, 0, 0, 0, 0, 0}.
Start bit 1200 mean 1.2ms off and 0.8ms on.
Data_0 {1500, 1500, 1500, 1500, 500, 1500, 1500, 1500} = {0, 0, 0, 0, 1, 0, 0, 0}.
Data_1 {1500, 500, 500, 1500, 1500, 1500, 1500, 500} = {0, 1, 1, 0, 0, 0, 0, 1}.
below I given the TIM2_CCR1 array values WaveForm,
here, Free bit and Start bit timing is 20.0155 ms. Data_0 and Data_1 totally 16 bit but i get only 15 bit. after I found that missing first bit data(value is 0).
I don't know where I made a mistake and how to slove this.