📄 io86ch06.c
字号:
/************************************************************/
/* */
/* */
/* - I/O definition (io86ch06.c) - */
/* */
/* */
/************************************************************/
/*---[ Type Definition File ]---*/
#include "comdef.h"
#if 1 // for 86CM47U
Typ_IO __io(0x00) _p0dr_; /* Port 0 */
Typ_IO __io(0x01) _p1dr_; /* Port 1 */
Typ_IO __io(0x02) _p2dr_; /* Port 2 */
Typ_IO __io(0x03) _p3dr_; /* Port 3 */
Typ_IO __io(0x04) _p4dr_; /* Port 4 */
Typ_IO __io(0x05) _p5dr_; /* Port 4 */
Typ_IO __io(0x06) _p6dr_; /* Port 4 */
Typ_IO __io(0x07) _p7dr_; /* Port 4 */
/* ================= */
Typ_IO __io(0x08) _p0outcr_; /* 0x00: Port0 control register */
Typ_IO __io(0x09) _p1cr_; /* 0x00: Port0 control register */
Typ_IO __io(0x0a) _p4outcr_; /* 0x00: Port0 control register */
Typ_IO __io(0x0b) _p0prd_; /* 0x00: Port0 control register */
Typ_IO __io(0x0c) _p2prd_; /* 0x00: Port0 control register */
Typ_IO __io(0x0d) _p3prd_; /* 0x02: Port3 control register */
Typ_IO __io(0x0e) _p4prd_; /* 0x03: Port4 control register */
Typ_IO __io(0x0f) _p5prd_; /* 0x02: Port3 control register */
//Typ_IO __io(0x0f9b) _p6cr1_; /* 0x02: Port3 control register */
//Typ_IO __io(0x0f9c) _p6cr2_; /* 0x02: Port3 control register */
//Typ_IO __io(0x0f9d) _p7cr1_; /* 0x02: Port3 control register */
//Typ_IO __io(0x0f9e) _p7cr2_; /* 0x02: Port3 control register */
/*==Timer===============*/
Typ_IOW __io(0x10) _ttreg1a_; /* 0x10: Extend Timer0 Control Register */
Typ_IOW __io(0x12) _ttreg1b_; /* 0x10: Extend Timer0 Control Register */
Typ_IO __io(0x14) _ttreg3_; /* 0x18: Compare Register */
Typ_IO __io(0x15) _ttreg4_; /* 0x18: Compare Register */
Typ_IO __io(0x16) _ttreg5_; /* 0x18: Compare Register */
Typ_IO __io(0x17) _ttreg6_; /* 0x18: Compare Register */
Typ_IO __io(0x18) _pwmreg3_; /* 0x18: Compare Register */
Typ_IO __io(0x19) _pwmreg4_; /* 0x18: Compare Register */
Typ_IO __io(0x1a) _pwmreg5_; /* 0x18: Compare Register */
Typ_IO __io(0x1b) _pwmreg6_; /* 0x18: Compare Register */
//ADC
Typ_IO __io(0x1c) _adccr1_; /* 0x1a: UART0 control Register A */
Typ_IO __io(0x1d) _adccr2_; /* 0x1a: UART0 control Register A */
Typ_IO __io(0x1e) _adcdr2_; /* 0x1a: UART0 control Register A */
Typ_IO __io(0x1f) _adcdr1_; /* 0x1a: UART0 control Register A */
//sio
Typ_IO __io(0x20) _siocr_; /* 0x1e: UART0 control Register A */
Typ_IO __io(0x21) _siosr_; /* 0x1e: UART0 control Register A */
Typ_IO __io(0x22) _siodbr_; /* 0x1c: Data Buffer Register 0 */
//
Typ_IO __io(0x23) _tc2cr_; /* 0x14: Capture Register A */
Typ_IOW __io(0x24) _ttreg2_; /* 0x10: Extend Timer0 Control Register */
Typ_IO __io(0x26) _tc1cr_; /* 0x14: Capture Register A */
Typ_IO __io(0x27) _tc3cr_; /* 0x14: Capture Register A */
Typ_IO __io(0x28) _tc4cr_; /* 0x14: Capture Register A */
Typ_IO __io(0x29) _tc5cr_; /* 0x14: Capture Register A */
Typ_IO __io(0x2a) _tc6cr_; /* 0x14: Capture Register A */
Typ_IO __io(0x2b) _sio2tdb_; /* 0x14: Capture Register A */
Typ_IOW __io(0x2c) _eirde_; /* 0x3a: interrupt enable register */
Typ_IOW __io(0x2e) _ilde_; /* 0x3c: interrupt latch */
Typ_IO __io(0x31) _sio2cr_; /* 0x1e: UART0 control Register A */
Typ_IO __io(0x32) _sio2sr2_; /* 0x1e: UART0 control Register A */
Typ_IOW __io(0x34) _wdtcr_; /* 0x34: watchdog timer control register */
Typ_IO __io(0x36) _tbtcr_; /* 0x36: time base timer control register */
Typ_IO __io(0x37) _eintcr_; /* 0x37: external interrupt cntrol register */
Typ_IO __io(0x38) _syscr1_; /* 0x38: system control register 1 */
Typ_IO __io(0x39) _syscr2_; /* 0x39: system control register 2 */
Typ_IOW __io(0x3a) _eirl_; /* 0x3a: interrupt enable register */
Typ_IOW __io(0x3c) _ill_; /* 0x3c: interrupt latch */
Typ_IO __io(0x3f) _psw_; /* 0x3f: Program Status Word */
#pragma section area SFR1 0x0f90
Typ_IO _sbicra_; /* 0x0f90 */
Typ_IO _sbidbr_; /* 0x0f91 */
Typ_IO _iicar_; /* 0x0f92 */
Typ_IO _sbicrb_; /* 0x0f93 */
Typ_U8 SFR1REV1; /* 0x0f94 */
Typ_IO _uart1cr1_; /* 0x0f95 */
Typ_IO _uart1cr2_; /* 0x0f96 */
Typ_IO _tdbuf1_; /* 0x0f97 */
Typ_IO _uart2cr1_; /* 0x0f98 */
Typ_IO _uart2cr2_; /* 0x0f99 */
Typ_IO _tdbuf2_; /* 0x0f9a */
Typ_IO _p6cr1_; /* 0x0f9b */
Typ_IO _p6cr2_; /* 0x0f9c */
Typ_IO _p7cr1_; /* 0x0f9d */
Typ_IO _p7cr2_; /* 0x0f9e */
Typ_IO _stopcr_; /* 0x0f9f */
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -