The PCA9671 provides general purpose remote I/O expansion for most microcontrollerfamilies via the two-line bidirectional bus (I2C-bus) and is a part of the Fast-mode Plus(Fm+) family.The PCA9671 is a drop in upgrade for the PCF8575 providing higher I2C-bus speeds(1 MHz versus 400 kHz) so that the output can support PWM dimming of LEDs, higherI2C-bus drive (30 mA versus 3 mA) so that many more devices can be on the bus withoutthe need for bus buffers, higher total package sink capacity (400 mA versus 100 mA) thatsupports having all 25 mA LEDs on at the same time and more device addresses (64versus 8) to allow many more devices on the bus without address conflicts.
上传时间: 2013-10-12
上传用户:laomv123
The PCA9672 provides general purpose remote I/O expansion for most microcontrollerfamilies via the two-line bidirectional bus (I2C-bus) and is a part of the Fast-mode Plusfamily.The PCA9672 is a drop-in upgrade for the PCF8574 providing higher Fast-mode Plus(Fm+) I2C-bus speeds (1 MHz versus 400 kHz) so that the output can support PWMdimming of LEDs, higher I2C-bus drive (30 mA versus 3 mA) so that many more devicescan be on the bus without the need for bus buffers, higher total package sink capacity(200 mA versus 100 mA) that supports having all LEDs on at the same time and moredevice addresses (16 versus 8) are available to allow many more devices on the buswithout address conflicts.
上传时间: 2013-10-23
上传用户:jasonheung
The PCA9673 provides general purpose remote I/O expansion for most microcontrollerfamilies via the two-line bidirectional bus (I2C-bus) and is a part of the Fast-mode Plusfamily.The PCA9673 is a drop in upgrade for the PCF8575 providing higher Fast-mode Plus(Fm+) I2C-bus speeds (1 MHz versus 400 kHz) so that the output can support PWMdimming of LEDs, higher I2C-bus drive (30 mA versus 3 mA) so that many more devicescan be on the bus without the need for bus buffers, higher total package sink capacity(400 mA versus 100 mA) that supports having all 25 mA LEDs on at the same time andmore device addresses (16 versus 8) are available to allow many more devices on the buswithout address conflicts.
上传时间: 2013-10-29
上传用户:wkchong
The PCA9674/74A is a drop-in upgrade for the PCF8574/74A providing higher Fast-modePlus I2C-bus speeds (1 MHz versus 400 kHz) so that the output can support PWMdimming of LEDs, higher I2C-bus drive (30 mA versus 3 mA) so that many more devicescan be on the bus without the need for bus buffers, higher total package sink capacity(200 mA versus 100 mA) that supports having all LEDs on at the same time and moredevice addresses (64 versus 8) are available to allow many more devices on the buswithout address conflicts.
上传时间: 2013-10-22
上传用户:wwwwwen5
The CAT9555 is a CMOS device that provides 16-bitparallel input/output port expansion for I²C and SMBuscompatible applications. These I/O expanders providea simple solution in applications where additional I/Osare needed: sensors, power switches, LEDs,pushbuttons, and fans.
上传时间: 2014-01-09
上传用户:1101055045
单片机C语言应用程序设计针对目前最通用的单片机8051和最流行的程序设计语言——C语言,以KEII。公司8051单片机开发套件讲解单片机的C语言应用程序设计。该套件的编译器有支持经典8051及8051派生产品的版本,统称为Cx51。Windows集成开发环境μVision2把μVisionl用的模拟调试器dScope与集成环境无缝结合起来,使用更方便,支持的单片机品种更多。 本书的特点是取材于原文资料,总结实际教学和应用经验,实例较多,实用性强。本书中C语言是针对8051特有结构描述的,这样,即使无编程基础的人,也可通过本书学习单片机的c编程。单片机C语言应用程序设计目录第1章 单片机基础知识 1.1 8051单片机的特点 1.2 8051的内部知识 1.3 8051的系统扩展 习题一第2章 C与8051 2.1 8051的编程语言 2.2 Cx51编译器 2.3 KEIL 8051开发工具 2.4 KEIL Cx51编程实例 2.5 Cx51程序结构 习题二第3章 Cx51 数据与运算 3.1 数据与数据类型 3.2 常量与变量 3.3 Cx51数据存储类型与8051存储器结构 3.4 8051特殊功能寄存器(SFR)及其Cx51定义 3.5 8051并行接口及其Cx51定义 3.6 位变量(BIT)及其Cx51定义 3.7 Cx51运算符、表达式及其规则 习题三第4章 Cx51 流程控制语句 4.1 C语言程序的基本结构及其流程图 4.2 选择语句 4.3 循环语句 习题四第5章 Cx51 构造数据类型 5.1 数组 5.2 指针 5.3 结构 5.4 共用体 5.5 枚举 习题五第6章 Cx51 函数第7章 模块化程序设计第8章 8051内部资源的C编辑第9章 8051扩展资源的C编辑第10章 8051输出控制的C编程第11章 8051数据采集的C编程第12章 8051机间通信的C编程第13章 8051人机交互的C编程附录A μVision2集成开发环境使用附录B KEIL Cx51 上机制南
上传时间: 2013-10-21
上传用户:行者Xin
keil 使用笔记:在Memory窗口上输入address_type:address才能看到正确地址的变量debug~perfermance analyzer加入要察看的模块名称,然后view~perfermance analyzer window 可以察看各个模块运行时间①Display address_type:address B:Bit address C:Code Memory Bx:Code Bank D D:80H 命令可以查看特殊寄存器 data D I:0 命令可以查看内部RAM数据iData; D X:0 命令可以查看外部RAM数据xData; ②R1 //显示R1 register ~R1 //显示变量R1 R1 = R7 //对寄存器Rx操作R1 = --R7 R1 = 0x20 ③main //显示main()的开始地址d main //显示main()的代码④向RAM.ROM中写数据Enter data_type address_type:address expr,expr.... data_type:int char double float long E char data:0x20 1,2,3,4 //向data区0x20开始的地址写1,2,3,4 变量放在RAM的30H,要把定义放在main前面!另外特别注意,内部RAM通常供C程序存放中间变量等,所以一定要看看编译后的程序中是否存在存储单元冲突的情况,比如如果程序中 使用了别的寄存器组的话,08-1FH单元就不能用了unsigned long data i _at_ 0x30
上传时间: 2013-11-05
上传用户:dongqiangqiang
这一颗,我们学习如何让跑马灯自动按照我们预定的顺序进行。这种控制在工控场合经常用到。这个程序里,我们预先定义了一个变化的顺序speedcode,每跑一圈灯就根据预定设置的表格数据来决定下一圈的跑马速度。这样我们就实现了按照预定的顺序自动变化运行。请看代码:-----------------------------------#define uchar unsigned char //定义一下方便使用#define uint unsigned int#define ulong unsigned long#include <reg52.h> //包括一个52 标准内核的头文件sbit P10 = P1^0; //头文件中没有定义的IO 就要自己来定义了sbit P11 = P1^1;sbit P12 = P1^2;sbit P13 = P1^3;bit ldelay=0; //长定时溢出标记,预置是0uchar speed=10; //设置一个变量保存跑马灯的移动速度uchar code speedcode[10]={3,1,5,12,3,20,2,10,1,4}; //10 个预定义的速度char code dx516[3] _at_ 0x003b;//这是为了仿真设置的//可编程自动控制跑马灯void main(void) // 主程序{uchar code ledp[4]={0xfe,0xfd,0xfb,0xf7};//预定的写入P1 的值uchar ledi; //用来指示显示顺序uchar i;RCAP2H =0x10; //赋T2 的预置值0x1000,溢出30 次就是1 秒钟RCAP2L =0x00;TR2=1; //启动定时器ET2=1; //打开定时器2 中断EA=1; //打开总中断
上传时间: 2013-11-20
上传用户:ming529
单片机指令系统 3.1 MCS-51指令简介 3.2 指令系统 3.1 MCS-51指令简介 二、MCS-51系列单片机指令系统分类 按寻址方式分为以下七种:按功能分为以下四种: 1、立即立即寻址 1、数据传送指令位操 2、直接寻址 2、算术运算指令 3、寄存器寻址 3、逻辑运算指令 4、寄存器间接寻址指令 4、控制转移类指令 5、相对寻址 5、位操作指令 6、变址寻址 7、位寻址 三、寻址方式 3、寄存器间接寻址 MOV A, @R1 操作数是通过寄存器间接得到的。 4、立即寻址 MOV A, #40H 操作数在指令中直接给出。 5、基址寄存器加变址寄存器寻址 以DPTR或PC为基址寄存器,以A为变址寄存器, 以两者相加形成的16位地址为操作数的地址。 MOVC A, @A+DPTR MOVC A, @A+PC 四、指令中常用符号说明 Rn——当前寄存器区的8个工作寄存器R0~R7(n=0~7); Ri——当前寄存器区可作地址寄存器的2个工作寄存器R0和R1(i=0,1); direct——8位内部数据存储器单元的地址及特殊功能寄存器的地址; #data——表示8位常数(立即数); #datal6——表示16位常数; add 16——表示16位地址; addrll——表示11位地址; rel——8位带符号的地址偏移量; bit——表示位地址; @——间接寻址寄存器或基址寄存器的前缀; ( )——表示括号中单元的内容 (( ))——表示间接寻址的内容; 五、MCS-51指令简介 1. 以累加器A为目的操作数的指令 2. 以Rn为目的操作数的指令 3. 以直接地址为目的操作数的指令 4. 以寄存器间接地址为目的操作数指令 应用举例1 8段数码管显示 应用举例2 3.2 指令系统 2、堆栈操作指令 3. 累加器A与外部数据传输指令 4. 查表指令 MOVC A, @A+PC 例子: 5. 字节交换指令 6. 半字节交换指令 二、算术操作类指令 PSW寄存器 2. 带进位加法指令 3. 加1指令 4. 十进制调整指令 5. 带借位减法指令(Subtraction) 6. 减1指令(Decrease) 7. 乘法指令(Multiplication) 8. 除法指令(Division) 三、逻辑运算指令 1. 简单逻辑操作指令 2. 循环指令 带进位左循环指令(Rotate Accumulator Left through Carry flag) 右循环指令(Rotate Accumulator Right) 带进位右循环指令(Rotate A Right with C) 3. 逻辑与指令 4. 逻辑或指令 5. 逻辑异或指令 四、控制转移类指令 1. 跳转指令 相对转移指令 SJMP rel PC←(PC)+2 PC←(PC)+rel 程序中标号与地址之间的关系 2. 条件转移指令 3. 比较不相等转移指令 4. 减 1 不为 0 转移指令 5. 调用子程序指令 7. 中断返回指令 五、位操作指令 1. 数据位传送指令 2. 位变量逻辑指令 3. 条件转移类指令
上传时间: 2013-10-27
上传用户:xuanjie
The C500 microcontroller family usually provides only one on-chip synchronous serialchannel (SSC). If a second SSC is required, an emulation of the missing interface mayhelp to avoid an external hardware solution with additional electronic components.The solution presented in this paper and in the attached source files emulates the mostimportant SSC functions by using optimized SW routines with a performance up to 25KBaud in Slave Mode with half duplex transmission and an overhead less than 60% atSAB C513 with 12 MHz. Due to the implementation in C this performance is not the limitof the chip. A pure implementation in assembler will result in a strong reduction of theCPU load and therefore increase the maximum speed of the interface. In addition,microcontrollers like the SAB C505 will speed up the interface by a factor of two becauseof an optimized architecture compared with the SAB C513.Moreover, this solution lays stress on using as few on-chip hardware resources aspossible. A more excessive consumption of those resources will result in a highermaximum speed of the emulated interface.Due to the restricted performance of an 8 bit microcontroller a pin compatible solution isprovided only; the internal register based programming interface is replaced by a set ofsubroutine calls.The attached source files also contain a test shell, which demonstrates how to exchangeinformation between an on-chip HW-SSC and the emulated SW-SSC via 5 external wiresin different operation modes. It is based on the SAB C513 (Siemens 8 bit microcontroller).A table with load measurements is presented to give an indication for the fraction of CPUperformance required by software for emulating the SSC.
标签: synchronous Emulating serial
上传时间: 2014-01-31
上传用户:z1191176801