CDN加速镜像 | 设为首页 | 加入收藏夹
当前位置: 首页 资源下载 源码下载 嵌入式/单片机编程 单片机(51,AVR,MSP430等)

文件名称:【19】DMA PWM WS2812 GPIO输出16组

  • 所属分类:
  • 标签属性:
  • 上传时间:
    2017-08-29
  • 文件大小:
    2.26mb
  • 已下载:
    2次
  • 提 供 者:
  • 相关连接:
  • 下载说明:
    别用迅雷下载,失败请重下,重下不扣分!

介绍说明--下载内容来自于网络,使用问题请自行百度

STM32作为主控芯片,72Mhz,利用DMA+PWM实现驱动WS2812,创建16个并行800kBit / s数据流的想法如下:
使用定时器每1.25us创建一个800kHz的时基和一个DMA请求。
使用2个比较模块在低位时间(350ns)和高位时间(700ns)下创建DMA请求
1.25us DMA请求将GPIO端口的所有位设置为高电平
350ns DMA请求将数据从帧缓冲区传输到GPIO端口。如果该位为0,GPIO引脚将变为低电平,否则将保持高电平。
700ns DMA请求将所有GPIO引脚设置为低电平。
重复步骤1到3,直到发送所有位。
这产生脉冲周期为1.25us,脉冲宽度为350ns或700ns的脉冲流,具体取决于脉冲表示的位值,通过DMA将数据传输到GPIO端口意味着每16个LED每位需要一个字(两个字节)。每个LED 24位,每16个LED 24个字(48个字节)。(The idea to create 16 parallel 800kBit/s data streams is the following:

Use a Timer to create an 800kHz time base and a DMA request every 1.25us.
Use 2 compare modules to create DMA requests at the low bit time (350ns) and the high bit time (700ns)

The 1.25us DMA request sets all bits of the GPIO port high
The 350ns DMA request transfers the data from the frame buffer to the GPIO port. If the bit is a 0, the GPIO pin will go low, otherwise it will stay high.
The 700ns DMA request sets all GPIO pins low.
Repeat steps 1 to 3 until all bits have been transmitted.
This creates a stream of pulses with a pulse period of 1.25us and a pulse width of either 350ns or 700ns depending on the bit value the pulse represents.

Transferring the data via DMA to the GPIO port means that per 16 LEDs one half word (two bytes) is needed per bit. At 24 bits per LED that makes 24 half words (48 bytes) per 16 LEDs.)
相关搜索: WS2812 dma+timer stm32f103zet6

(系统自动生成,下载前可以参看下载内容)

下载文件列表

【19】DMA PWM WS2812 GPIO输出16组\CORE\core_cm3.c
【19】DMA PWM WS2812 GPIO输出16组\CORE\core_cm3.h
【19】DMA PWM WS2812 GPIO输出16组\CORE\startup_stm32f10x_hd.s
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\misc.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_adc.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_bkp.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_can.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_cec.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_crc.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_dac.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_dbgmcu.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_dma.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_exti.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_flash.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_fsmc.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_gpio.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_i2c.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_iwdg.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_pwr.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_rcc.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_rtc.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_sdio.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_spi.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_tim.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_usart.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\inc\stm32f10x_wwdg.h
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\misc.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_adc.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_bkp.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_can.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_cec.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_crc.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_dac.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_dbgmcu.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_dma.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_exti.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_flash.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_fsmc.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_gpio.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_i2c.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_iwdg.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_pwr.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_rcc.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_rtc.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_sdio.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_spi.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_tim.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_usart.c
【19】DMA PWM WS2812 GPIO输出16组\FWLIB\src\stm32f10x_wwdg.c
【19】DMA PWM WS2812 GPIO输出16组\HARDWARE\LED\led.c
【19】DMA PWM WS2812 GPIO输出16组\HARDWARE\LED\led.h
【19】DMA PWM WS2812 GPIO输出16组\Listings\startup_stm32f10x_hd.lst
【19】DMA PWM WS2812 GPIO输出16组\Listings\Template.map
【19】DMA PWM WS2812 GPIO输出16组\Objects\core_cm3.crf
【19】DMA PWM WS2812 GPIO输出16组\Objects\core_cm3.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\core_cm3.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\delay.crf
【19】DMA PWM WS2812 GPIO输出16组\Objects\delay.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\delay.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\led.crf
【19】DMA PWM WS2812 GPIO输出16组\Objects\led.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\led.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\main.crf
【19】DMA PWM WS2812 GPIO输出16组\Objects\main.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\main.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\misc.crf
【19】DMA PWM WS2812 GPIO输出16组\Objects\misc.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\misc.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\startup_stm32f10x_hd.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\startup_stm32f10x_hd.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_dma.crf
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_dma.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_dma.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_fsmc.crf
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_fsmc.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_fsmc.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_gpio.crf
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_gpio.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_gpio.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_it.crf
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_it.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_it.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_rcc.crf
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_rcc.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_rcc.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_tim.crf
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_tim.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_tim.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_usart.crf
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_usart.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\stm32f10x_usart.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\sys.crf
【19】DMA PWM WS2812 GPIO输出16组\Objects\sys.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\sys.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\system_stm32f10x.crf
【19】DMA PWM WS2812 GPIO输出16组\Objects\system_stm32f10x.d
【19】DMA PWM WS2812 GPIO输出16组\Objects\system_stm32f10x.o
【19】DMA PWM WS2812 GPIO输出16组\Objects\Template.axf
【19】DMA PWM WS2812 GPIO输出16组\Objects\Template.build_log.htm
【19】DMA PWM WS2812 GPIO输出16组\Objects\Template.hex

相关说明

  • 本站资源为会员上传分享交流与学习,如有侵犯您的权益,请联系我们删除.
  • 搜珍网是交换下载平台,只提供交流渠道,下载内容来自于网络,除下载问题外,其它问题请自行百度。更多...
  • 本站已设置防盗链,请勿用迅雷、QQ旋风等下载软件下载资源,下载后用WinRAR最新版进行解压.
  • 如果您发现内容无法下载,请稍后再次尝试;或换浏览器;或者到消费记录里找到下载记录反馈给我们.
  • 下载后发现下载的内容跟说明不相乎,请到消费记录里找到下载记录反馈给我们,经确认后退回积分.
  • 如下载前有疑问,可以通过点击"提供者"的名字,查看对方的联系方式,联系对方咨询.

相关评论

暂无评论内容.

发表评论

*快速评论: 推荐 一般 有密码 和说明不符 不是源码或资料 文件不全 不能解压 纯粹是垃圾
*内  容:
*验 证 码:
搜珍网 www.dssz.com