📄 8051f.c
字号:
/////////////////////////////////////
// Generated Initialization File //
/////////////////////////////////////
#include "C8051F310.h"
#include "stdio.h"
// Peripheral specific initialization functions,
// Called from the Init_Device() function
void Timer_Init()
{
TCON = 0x50;
TMR2CN = 0x20;
TMR3CN = 0x20;
}
void Port_IO_Init()
{
XBR0 = 0x17;
XBR1 = 0x40;
}
void Interrupts_Init()
{
IE = 0xBA;
}
// Initialization function for device,
// Call Init_Device() from your main program
void Init_Device(void)
{
Timer_Init();
Port_IO_Init();
Interrupts_Init();
}
main()
{
Init_Device();
printf("HELLO WORD!!!");
while(1);
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -