RTEMS 6.1-rc6
Loading...
Searching...
No Matches
Macros

Macros

#define NOR_ADDR_SHIFT(__NOR_ADDRESS, __NOR_MEMORY_WIDTH_, __ADDRESS__)
 NOR memory address shifting.
 
#define NOR_WRITE(__ADDRESS__, __DATA__)
 NOR memory write data to specified address.
 

Detailed Description

Macro Definition Documentation

◆ NOR_ADDR_SHIFT

#define NOR_ADDR_SHIFT (   __NOR_ADDRESS,
  __NOR_MEMORY_WIDTH_,
  __ADDRESS__ 
)
Value:
((uint32_t)(((__NOR_MEMORY_WIDTH_) == NOR_MEMORY_16B)? \
((uint32_t)((__NOR_ADDRESS) + (2U * (__ADDRESS__)))): \
((uint32_t)((__NOR_ADDRESS) + (__ADDRESS__)))))

NOR memory address shifting.

Parameters
__NOR_ADDRESSNOR base address
__NOR_MEMORY_WIDTH_NOR memory width
__ADDRESS__NOR memory address
Return values
NORshifted address value

◆ NOR_WRITE

#define NOR_WRITE (   __ADDRESS__,
  __DATA__ 
)
Value:
do{ \
(*(__IO uint16_t *)((uint32_t)(__ADDRESS__)) = (__DATA__)); \
__DSB(); \
} while(0)
#define __IO
Definition: core_cm4.h:239

NOR memory write data to specified address.

Parameters
__ADDRESS__NOR memory address
__DATA__Data to write
Return values
None