随笔分类 -  STM32

摘要:TIMx_CR1(控制寄存器1)9-8位:CKD[1:0]时钟分频因子,定义在定时器时钟(CK_INT)频率与数字滤波器(ETR,TIx)使用的采样频率之间的分频比例。 定义:00(tDTS = tCK_INT),01(tDTS = 2 x tCK_INT),10(tDTS = 4 x tCK_I... 阅读全文
posted @ 2015-08-28 00:34 IAmAProgrammer 编辑
摘要:首先,我们可以看到这个图大概有两个不分,一个部分是时钟源,另一个部分则是输入输出时钟源计数,到CNT计数器,然后根据捕获比较寄存器进行记录或比较。记录或比较有不同的配置。首先是TI信号TI1 TI2 TI3 TI4:这个信号就是外部信号,是直接与管脚相连的信号,图中还有一个问题就是TI1是可以是第一... 阅读全文
posted @ 2015-08-28 00:30 IAmAProgrammer 编辑
摘要:环境:iar arm 5.3stm32f103vbt6使用PA.8 外部输入10Mhz的方波。可从systick中断得到数据4.4×5000(预分频值)×1000(tick中断时间)=20MHz属于双边沿检测,一个PA.8个脉冲有2个边沿,所以时钟加倍。由于使用了TI1F_ED它的结构如下:void... 阅读全文
posted @ 2015-08-28 00:27 IAmAProgrammer 编辑
摘要:串口通信是经常使用到的功能,在STM32中UART具有DMA功能,并且收发都可以使用DMA,使用DMA发送基本上大家不会遇到什么问题,因为发送的时候会告知DMA发送的数据长度,DMA按照发送的长度直接发送就OK了,但是使用DMA接收时候就不同了,因为有时候数据接收并不是每一次都是定长的,但是DMA只... 阅读全文
posted @ 2015-08-27 23:16 IAmAProgrammer 编辑
摘要:http://www.cs.indiana.edu/~geobrown/book.pdfAn example of a basic timer is illustrated in Figure 10.1.This timer has four components – a controller, a... 阅读全文
posted @ 2015-08-27 22:22 IAmAProgrammer 编辑
摘要:78-WS2812-Library (STM32F4)//--------------------------------------------------------------// File : stm32_ub_ws2812.h//--------------------------... 阅读全文
posted @ 2015-08-27 00:29 IAmAProgrammer 编辑
摘要:stm-ledstrip : Driver and test routine for WS2811 RGB-LED #include "ws2812.h"#include #include #include #include #include static uint16_t PWM_Buffer[ ... 阅读全文
posted @ 2015-08-27 00:27 IAmAProgrammer 编辑
摘要:how to drive a WS2812 RGB LED using PWM and DMA#include void Delay(__IO uint32_t nCount){ while(nCount--) { }}#define TIM3_CCR1_Address 0x4000043... 阅读全文
posted @ 2015-08-26 23:55 IAmAProgrammer 编辑
摘要:0xWS2812 STM32 driver for WS2812(B) RGB LEDs0xWS2812 pronounced "hex-WS2812"This code aims at providing a basic interface to the WS2812(B) individuall... 阅读全文
posted @ 2015-08-26 23:48 IAmAProgrammer 编辑
摘要:Auto-reload register (TIMx_ARR)The auto-reload register is preloaded.Writing to or reading from the auto-reload registeraccesses the preload register.... 阅读全文
posted @ 2015-08-26 23:10 IAmAProgrammer 编辑
摘要:External Input Counter and External interrupt : count the input signal from the button.So what is the different between two methods ?While external in... 阅读全文
posted @ 2015-08-26 21:59 IAmAProgrammer 编辑
摘要:Bitbox : a small open, DIY 32 bit VGA consoleHi all,I've been developing a simple DIY console and a participant of the project and of this message boa... 阅读全文
posted @ 2015-08-26 20:12 IAmAProgrammer 编辑
摘要:One-wire Demo on the STM32F4 Discovery BoardSome of the devs at work were struggling to get their software talking to a Dallas 1-wire device. I rememb... 阅读全文
posted @ 2015-08-26 20:02 IAmAProgrammer 编辑
摘要:VGA Output from STM32F4 Discovery boardI love the web!There are so many cool projects out there, and some, with a tweak or two,get me where I want to ... 阅读全文
posted @ 2015-08-26 19:55 IAmAProgrammer 编辑
摘要:STM32通用定时器的几种配置方式//------------------------------------------------------------------------------// 1、普通定时使用#include"stm32f10x.h"#include"time.h"stati... 阅读全文
posted @ 2015-08-26 18:49 IAmAProgrammer 编辑
摘要:TIMER门控模式控制PWM输出长度参照一些网友代码做了些修改,由TIM4来控制TIM2的PWM输出长度,采用主从的门控模式,即TIM4输出高时候TIM2使能输出//TIM2 PWM输出,由TIM4来控制其输出与停止//frequency_tim2:TIM2 PWM输出周期:KHz//duty_ti... 阅读全文
posted @ 2015-08-26 18:45 IAmAProgrammer 编辑
摘要:Timers TIM1 and TIM8 use 16-bit counters and are the most complex timers of all timers included in the microcontroller.Timers TIM2 and TIM5 are 32-bit... 阅读全文
posted @ 2015-08-26 18:29 IAmAProgrammer 编辑
摘要:STM32F103ZET6 用定时器级联方式输出特定数目的PWMSTM32F103ZET6里共有8个定时器,其中高级定时器有TIM1-TIM5、TIM8,共6个。这里需要使用定时器的级联功能,ST的RM0008 REV12的P388和P399页上有说明对于特定的定时器,怎么去选择级联功能,参见表86... 阅读全文
posted @ 2015-08-26 18:11 IAmAProgrammer 编辑
摘要:使用36-pin的STM32输出VGA手头上有个项目需要通过单片机来控制将图像显示在LCD上,在网上搜了一阵子,发现都是使用的FPGA做的,开始自己对FPGA不是很熟,一直在用的也是ARM系列的,终于让我找到一份至少现在看起来还是含金量蛮高的资料,因为是英文的,这边先将它翻译一下(原文链接)。 想... 阅读全文
posted @ 2015-08-26 17:46 IAmAProgrammer 编辑

点击右上角即可分享
微信分享提示