stc是哪家公司?keil里找不到STC89C54RD+这个单片机?谢谢! 10
stc是哪家公司?在keil软件里,怎么找到不STC89C54RD+这个单片机型号的?非常感谢!...
stc是哪家公司?在keil软件里,怎么找到不STC89C54RD+这个单片机型号的?非常感谢!
展开
展开全部
STC是中国台湾的。KEILL里没用STC89C54RD的内核需要你自己添加。自己编写内核其实不难,你在STC89C54RD资料中找到特殊的,一些51系列单片机没有的存储单元,按照51原有格式编写一份.txt格式的文档,然后再保存到KEILL安装文件下C51文件下的LIB文件下就可以了。在编程时你直接可以#include <STC89C54RD.h>就可以了。
这是我自己写的STC5410的内核 可以参考:
/*--------------------------------------------------------------------------
REGSTC5410AD.H
Header file for generic STC5410AD microcontroller.
Copyright (c) 1988-2010 Keil Elektronik GmbH and Keil Software, Inc.
All rights reserved.
--------------------------------------------------------------------------*/
#ifndef __REGSTC5410AD_H__
#define __REGSTC5410AD_H__
/* BYTE Registers */
sfr P0 = 0x80;
sfr P1 = 0x90;
sfr P2 = 0xA0;
sfr P3 = 0xB0;
sfr PSW = 0xD0;
sfr ACC = 0xE0;
sfr B = 0xF0;
sfr SP = 0x81;
sfr DPL = 0x82;
sfr DPH = 0x83;
sfr PCON = 0x87;
sfr TCON = 0x88;
sfr TMOD = 0x89;
sfr TL0 = 0x8A;
sfr TL1 = 0x8B;
sfr TH0 = 0x8C;
sfr TH1 = 0x8D;
sfr IE = 0xA8;
sfr IP = 0xB8;
sfr SCON = 0x98;
sfr SBUF = 0x99;
/* 8052 Extensions */
sfr SPSTAT = 0x84;
sfr SPCTL = 0x85;
sfr SPDAT = 0x86;
sfr AUXR = 0x8E;
sfr P1M0 = 0x91;
sfr P1M1 = 0x92;
sfr P0M0 = 0x93;
sfr P0M1 = 0x94;
sfr P2M0 = 0x95;
sfr P2M1 = 0x96;
sfr P3M0 = 0xB1;
sfr P3M1 = 0xB2;
sfr IPH = 0xB7;
sfr ADC_LOW2 = 0xBE;
sfr ADC_CONTR = 0xC5;
sfr ADC_DATA = 0xC6;
sfr CLK_DIV = 0xC7;
sfr CCON = 0xD8;
sfr CMOD = 0xD9;
sfr CCAPM0 = 0xDA;
sfr CCAPM1 = 0xDB;
sfr CCAPM2 = 0xDC;
sfr CCAPM3 = 0xDD;
sfr WDT_CONTR = 0xE1;
sfr ISP_DATA = 0xE2;
sfr ISP_ADDRH = 0xE3;
sfr ISP_ADDRL = 0xE4;
sfr ISP_CMD = 0xE5;
sfr ISP_TRIG = 0xE6;
sfr ISP_CONTR = 0xE7;
sfr CL = 0xE9;
sfr CCAP0L = 0xEA;
sfr CCAP1L = 0xEB;
sfr CCAP2L = 0xEC;
sfr CCAP3L = 0xED;
sfr PCA_PWM0 = 0xF2;
sfr PCA_PWM1 = 0xF3;
sfr PCA_PWM2 = 0xF4;
sfr PCA_PWM3 = 0xF5;
sfr CH = 0xF9;
sfr CCAP0H = 0xFA;
sfr CCAP1H = 0xFB;
sfr CCAP2H = 0xFC;
sfr CCAP3H = 0xFD;
/* BIT Registers */
/* PSW */
sbit CY = PSW^7;
sbit AC = PSW^6;
sbit F0 = PSW^5;
sbit RS1 = PSW^4;
sbit RS0 = PSW^3;
sbit OV = PSW^2;
sbit P = PSW^0; //8052 only
/* TCON */
sbit TF1 = TCON^7;
sbit TR1 = TCON^6;
sbit TF0 = TCON^5;
sbit TR0 = TCON^4;
sbit IE1 = TCON^3;
sbit IT1 = TCON^2;
sbit IE0 = TCON^1;
sbit IT0 = TCON^0;
/* IE */
sbit EA = IE^7;
sbit EPCA_LVD = IE^6;
sbit EADC_SPI = IE^5;
sbit ES = IE^4;
sbit ET1 = IE^3;
sbit EX1 = IE^2;
sbit ET0 = IE^1;
sbit EX0 = IE^0;
/* IP */
sbit PPCA_LVD = IP^6;
sbit PADC_SPI = IP^5;
sbit PS = IP^4;
sbit PT1 = IP^3;
sbit PX1 = IP^2;
sbit PT0 = IP^1;
sbit PX0 = IP^0;
/* P3 */
sbit CEX0 = P3^7;
//sbit WR = P3^6;
sbit T1 = P3^5;
sbit T0 = P3^4;
sbit INT1 = P3^3;
sbit INT0 = P3^2;
sbit TXD = P3^1;
sbit RXD = P3^0;
/* SCON */
sbit SM0 = SCON^7;
sbit SM1 = SCON^6;
sbit SM2 = SCON^5;
sbit REN = SCON^4;
sbit TB8 = SCON^3;
sbit RB8 = SCON^2;
sbit TI = SCON^1;
sbit RI = SCON^0;
/*ADC_CONTR*/ //不可位寻址
/*sbit ADC_POWER =ADC_CONTR^7;
sbit SPEED1 =ADC_CONTR^6;
sbit SPEED0 =ADC_CONTR^5;
sbit ADC_FLAG =ADC_CONTR^4;
sbit ADC_START =ADC_CONTR^3;
sbit CHS2 =ADC_CONTR^2;
sbit CHS1 =ADC_CONTR^1;
sbit CHS0 =ADC_CONTR^0;
WDT_CONTR*/
/*sbit WDT_FLAG =WDT_CONTR^7;
sbit EN_WDT =WDT_CONTR^5;
sbit CLR_WDT =WDT_CONTR^4;
sbit IDLE_WDT =WDT_CONTR^3;
sbit PS2 =WDT_CONTR^2;
sbit PS1 =WDT_CONTR^1;
sbit PS0 =WDT_CONTR^0; */
#endif
这是我自己写的STC5410的内核 可以参考:
/*--------------------------------------------------------------------------
REGSTC5410AD.H
Header file for generic STC5410AD microcontroller.
Copyright (c) 1988-2010 Keil Elektronik GmbH and Keil Software, Inc.
All rights reserved.
--------------------------------------------------------------------------*/
#ifndef __REGSTC5410AD_H__
#define __REGSTC5410AD_H__
/* BYTE Registers */
sfr P0 = 0x80;
sfr P1 = 0x90;
sfr P2 = 0xA0;
sfr P3 = 0xB0;
sfr PSW = 0xD0;
sfr ACC = 0xE0;
sfr B = 0xF0;
sfr SP = 0x81;
sfr DPL = 0x82;
sfr DPH = 0x83;
sfr PCON = 0x87;
sfr TCON = 0x88;
sfr TMOD = 0x89;
sfr TL0 = 0x8A;
sfr TL1 = 0x8B;
sfr TH0 = 0x8C;
sfr TH1 = 0x8D;
sfr IE = 0xA8;
sfr IP = 0xB8;
sfr SCON = 0x98;
sfr SBUF = 0x99;
/* 8052 Extensions */
sfr SPSTAT = 0x84;
sfr SPCTL = 0x85;
sfr SPDAT = 0x86;
sfr AUXR = 0x8E;
sfr P1M0 = 0x91;
sfr P1M1 = 0x92;
sfr P0M0 = 0x93;
sfr P0M1 = 0x94;
sfr P2M0 = 0x95;
sfr P2M1 = 0x96;
sfr P3M0 = 0xB1;
sfr P3M1 = 0xB2;
sfr IPH = 0xB7;
sfr ADC_LOW2 = 0xBE;
sfr ADC_CONTR = 0xC5;
sfr ADC_DATA = 0xC6;
sfr CLK_DIV = 0xC7;
sfr CCON = 0xD8;
sfr CMOD = 0xD9;
sfr CCAPM0 = 0xDA;
sfr CCAPM1 = 0xDB;
sfr CCAPM2 = 0xDC;
sfr CCAPM3 = 0xDD;
sfr WDT_CONTR = 0xE1;
sfr ISP_DATA = 0xE2;
sfr ISP_ADDRH = 0xE3;
sfr ISP_ADDRL = 0xE4;
sfr ISP_CMD = 0xE5;
sfr ISP_TRIG = 0xE6;
sfr ISP_CONTR = 0xE7;
sfr CL = 0xE9;
sfr CCAP0L = 0xEA;
sfr CCAP1L = 0xEB;
sfr CCAP2L = 0xEC;
sfr CCAP3L = 0xED;
sfr PCA_PWM0 = 0xF2;
sfr PCA_PWM1 = 0xF3;
sfr PCA_PWM2 = 0xF4;
sfr PCA_PWM3 = 0xF5;
sfr CH = 0xF9;
sfr CCAP0H = 0xFA;
sfr CCAP1H = 0xFB;
sfr CCAP2H = 0xFC;
sfr CCAP3H = 0xFD;
/* BIT Registers */
/* PSW */
sbit CY = PSW^7;
sbit AC = PSW^6;
sbit F0 = PSW^5;
sbit RS1 = PSW^4;
sbit RS0 = PSW^3;
sbit OV = PSW^2;
sbit P = PSW^0; //8052 only
/* TCON */
sbit TF1 = TCON^7;
sbit TR1 = TCON^6;
sbit TF0 = TCON^5;
sbit TR0 = TCON^4;
sbit IE1 = TCON^3;
sbit IT1 = TCON^2;
sbit IE0 = TCON^1;
sbit IT0 = TCON^0;
/* IE */
sbit EA = IE^7;
sbit EPCA_LVD = IE^6;
sbit EADC_SPI = IE^5;
sbit ES = IE^4;
sbit ET1 = IE^3;
sbit EX1 = IE^2;
sbit ET0 = IE^1;
sbit EX0 = IE^0;
/* IP */
sbit PPCA_LVD = IP^6;
sbit PADC_SPI = IP^5;
sbit PS = IP^4;
sbit PT1 = IP^3;
sbit PX1 = IP^2;
sbit PT0 = IP^1;
sbit PX0 = IP^0;
/* P3 */
sbit CEX0 = P3^7;
//sbit WR = P3^6;
sbit T1 = P3^5;
sbit T0 = P3^4;
sbit INT1 = P3^3;
sbit INT0 = P3^2;
sbit TXD = P3^1;
sbit RXD = P3^0;
/* SCON */
sbit SM0 = SCON^7;
sbit SM1 = SCON^6;
sbit SM2 = SCON^5;
sbit REN = SCON^4;
sbit TB8 = SCON^3;
sbit RB8 = SCON^2;
sbit TI = SCON^1;
sbit RI = SCON^0;
/*ADC_CONTR*/ //不可位寻址
/*sbit ADC_POWER =ADC_CONTR^7;
sbit SPEED1 =ADC_CONTR^6;
sbit SPEED0 =ADC_CONTR^5;
sbit ADC_FLAG =ADC_CONTR^4;
sbit ADC_START =ADC_CONTR^3;
sbit CHS2 =ADC_CONTR^2;
sbit CHS1 =ADC_CONTR^1;
sbit CHS0 =ADC_CONTR^0;
WDT_CONTR*/
/*sbit WDT_FLAG =WDT_CONTR^7;
sbit EN_WDT =WDT_CONTR^5;
sbit CLR_WDT =WDT_CONTR^4;
sbit IDLE_WDT =WDT_CONTR^3;
sbit PS2 =WDT_CONTR^2;
sbit PS1 =WDT_CONTR^1;
sbit PS0 =WDT_CONTR^0; */
#endif
小谢
2024-08-13 广告
2024-08-13 广告
作为深圳市金创图电子设备有限公司的工作人员,我推荐您选择JTAG烧录器。JTAG烧录器是一种通用的芯片烧录方法,它通过串行的方式进行烧录,具有速度快、操作简单、价格低廉等优点。JTAG烧录器支持多种芯片类型,包括单片机、PLC、DSP等,可...
点击进入详情页
本回答由小谢提供
展开全部
STC是台湾的公司,STC89C54RD+是宏晶的一个产品,兼容89c51 52。 KEIL里面选51就可以了,不选的话也可以,默认就行。只要你用STC-ISP能找到STC89C54RD+就可以下载HEX文件到单片机里面了
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
没那么麻烦!在Keil中选任意一个89C51或89C52就行,然后再程序中引用STC单片机的头文件。
STC的头文件可以在www.mcu-memory.com去下载。
Keil出现的时候还没STC这个东西呢,就算有,Keil也不屑于这种小厂的产品。
STC的头文件可以在www.mcu-memory.com去下载。
Keil出现的时候还没STC这个东西呢,就算有,Keil也不屑于这种小厂的产品。
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
stc是宏晶单片机 认准89C54这个型号就差不多了
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
这个问题可以去STC的官网http://www.mcu-memory.com/上下载一个.cdb文件,然后重命名替换掉keil--->c51--->lib文件夹下的相关cdb文件。我用的是UV4,下载后命名为uv4.cdb,将里面原有的此文件删除替换。重新运行uv,接下来,奇迹发生了。
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询