mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-28 12:23:35 +08:00
Add arch/z80/src/z180/z180_iomap.h
git-svn-id: http://svn.code.sf.net/p/nuttx/code/trunk@5427 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
@@ -49,7 +49,7 @@
|
||||
* Pre-processor Definitions
|
||||
****************************************************************************/
|
||||
|
||||
/* Bits in the Z80 FLAGS register ***************************************************/
|
||||
/* Bits in the Z180 FLAGS register ******************************************/
|
||||
|
||||
#define Z180_C_FLAG 0x01 /* Bit 0: Carry flag */
|
||||
#define Z180_N_FLAG 0x02 /* Bit 1: Add/Subtract flag */
|
||||
@@ -58,19 +58,7 @@
|
||||
#define Z180_Z_FLAG 0x40 /* Bit 5: Zero flag */
|
||||
#define Z180_S_FLAG 0x80 /* Bit 7: Sign flag */
|
||||
|
||||
/* Register access macros ***********************************************************/
|
||||
|
||||
#ifndef __ASSEMBLY__
|
||||
|
||||
# define getreg8(a) (*(volatile uint8_t *)(a))
|
||||
# define putreg8(v,a) (*(volatile uint8_t *)(a) = (v))
|
||||
# define getreg16(a) (*(volatile uint16_t *)(a))
|
||||
# define putreg16(v,a) (*(volatile uint16_t *)(a) = (v))
|
||||
# define getreg32(a) (*(volatile uint32_t *)(a))
|
||||
# define putreg32(v,a) (*(volatile uint32_t *)(a) = (v))
|
||||
|
||||
#endif
|
||||
|
||||
/* Z180 Chip Definitions ****************************************************/
|
||||
/* Z800180
|
||||
*
|
||||
* The 8-bit Z80180 MPU provides the benefits of reduced system costs and
|
||||
|
||||
@@ -58,19 +58,6 @@
|
||||
#define Z80_Z_FLAG 0x40 /* Bit 5: Zero flag */
|
||||
#define Z80_S_FLAG 0x80 /* Bit 7: Sign flag */
|
||||
|
||||
/* Register access macros ***********************************************************/
|
||||
|
||||
#ifndef __ASSEMBLY__
|
||||
|
||||
# define getreg8(a) (*(volatile uint8_t *)(a))
|
||||
# define putreg8(v,a) (*(volatile uint8_t *)(a) = (v))
|
||||
# define getreg16(a) (*(volatile uint16_t *)(a))
|
||||
# define putreg16(v,a) (*(volatile uint16_t *)(a) = (v))
|
||||
# define getreg32(a) (*(volatile uint32_t *)(a))
|
||||
# define putreg32(v,a) (*(volatile uint32_t *)(a) = (v))
|
||||
|
||||
#endif
|
||||
|
||||
/************************************************************************************
|
||||
* Public Function Prototypes
|
||||
************************************************************************************/
|
||||
|
||||
Reference in New Issue
Block a user