core_cm4.h 554 B

123456789101112131415161718192021222324252627
  1. /*
  2. * Copyright (c) 2020 Oticon A/S
  3. * Copyright (c) 2021 Codecoup
  4. *
  5. * SPDX-License-Identifier: Apache-2.0
  6. */
  7. #ifndef _BSIM_CORE_CM4_H
  8. #define _BSIM_CORE_CM4_H
  9. #include <stdint.h>
  10. /* Include the original ext_NRF52_hw_models core_cm4.h */
  11. #include <../HW_models/core_cm4.h>
  12. /* Add missing function definitions */
  13. extern void NVIC_SetPriority(IRQn_Type IRQn, uint32_t priority);
  14. extern void NVIC_EnableIRQ(IRQn_Type IRQn);
  15. extern void NVIC_DisableIRQ(IRQn_Type IRQn);
  16. void __WFI(void);
  17. #ifndef __REV
  18. #define __REV __builtin_bswap32
  19. #endif
  20. #endif