-
大小: 21KB文件类型: .rar金币: 1下载: 0 次发布日期: 2021-01-02
- 语言: 其他
- 标签:
资源简介
使用定时器产生1ms中断,从而控制595进行动态扫描数码管。
代码片段和文件信息
#include “msp430g2553.h“
long temp;
long IntDegF;
long IntDegC = 0;
#define CPU_F ((double)1000000)
#define delay_us(x) __delay_cycles((long)(CPU_F*(double)x/1000000.0))
#define delay_ms(x) __delay_cycles((long)(CPU_F*(double)x/1000.0))
unsigned char position[4]={0xfe0xfd0xfb0xf7};
unsigned char dis_buff[4];
//unsigned char time[3]={0}; // 分、秒计数单元和积分单元
unsigned char posit = 0;
unsigned char disp[] = {0xC00xF90xA40xB00x990x920x820xF80x800x90}; //共yang显示 顺时针
//unsigned char disp[] = {0x3f0x060x5B0x4F0x660x6D0x7D0x070x7F0x6F}; //共yin显示 顺时针
#define clr_595_1 P1OUT |= BIT6
#define clr_595_0 P1OUT &=~BIT6
#define clk_595_1 P1OUT |= BIT7
#define clk_595_0 P1OUT &=~BIT7
#define cp_595_1 P1OUT |= BIT4
#define cp_595_0 P1OUT &=~BIT4
#define di_5
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 490 2012-04-23 21:18 dongtai-LED\.ccsproject
文件 19195 2012-05-02 23:28 dongtai-LED\.cproject
文件 2576 2012-05-03 10:38 dongtai-LED\.project
文件 93 2012-04-23 21:18 dongtai-LED\.settings\org.eclipse.cdt.codan.core.prefs
文件 154 2012-04-23 21:18 dongtai-LED\.settings\org.eclipse.cdt.debug.core.prefs
文件 239 2012-04-23 21:19 dongtai-LED\.settings\org.eclipse.core.resources.prefs
文件 51 2012-05-07 09:04 dongtai-LED\Debug\ccsObjs.opt
文件 14 2012-05-07 09:04 dongtai-LED\Debug\ccsSrcs.opt
文件 10934 2012-05-07 09:04 dongtai-LED\Debug\dongtai-LED.map
文件 17673 2012-05-07 09:04 dongtai-LED\Debug\dongtai-LED.out
文件 3228 2012-05-07 09:04 dongtai-LED\Debug\makefile
文件 7660 2012-05-07 09:04 dongtai-LED\Debug\number.obj
文件 273 2012-05-07 09:04 dongtai-LED\Debug\number.pp
文件 268 2012-05-07 09:03 dongtai-LED\Debug\ob
文件 1811 2012-05-07 09:04 dongtai-LED\Debug\sources.mk
文件 802 2012-05-07 09:04 dongtai-LED\Debug\subdir_rules.mk
文件 525 2012-05-07 09:04 dongtai-LED\Debug\subdir_vars.mk
文件 4912 2012-04-23 21:18 dongtai-LED\lnk_msp430g2231.cmd
文件 4912 2012-05-02 23:28 dongtai-LED\lnk_msp430g2553.cmd
文件 822 2012-04-23 21:19 dongtai-LED\MSP430G2231.ccxm
文件 822 2012-05-02 23:28 dongtai-LED\MSP430G2553.ccxm
文件 2538 2012-05-07 09:04 dongtai-LED\number.c
目录 0 2012-04-23 21:19 dongtai-LED\.settings
目录 0 2012-05-07 09:04 dongtai-LED\Debug
目录 0 2012-05-03 10:53 dongtai-LED
----------- --------- ---------- ----- ----
79992 25
评论
共有 条评论