The official Mbed 2 C/C++ SDK provides the software platform and libraries to build your applications.

Dependents:   hello SerialTestv11 SerialTestv12 Sierpinski ... more

mbed 2

This is the mbed 2 library. If you'd like to learn about Mbed OS please see the mbed-os docs.

Committer:
AnnaBridge
Date:
Wed Feb 20 20:53:29 2019 +0000
Revision:
172:65be27845400
Parent:
171:3a7713b1edbc
mbed library release version 165

Who changed what in which revision?

UserRevisionLine numberNew contents of line
AnnaBridge 171:3a7713b1edbc 1 /**
AnnaBridge 171:3a7713b1edbc 2 ******************************************************************************
AnnaBridge 171:3a7713b1edbc 3 * @file architecture.h
AnnaBridge 171:3a7713b1edbc 4 * @brief CM3 architecture specific inclusions and defines.
AnnaBridge 171:3a7713b1edbc 5 * @internal
AnnaBridge 171:3a7713b1edbc 6 * @author ON Semiconductor
AnnaBridge 171:3a7713b1edbc 7 * $Rev: $
AnnaBridge 171:3a7713b1edbc 8 * $Date: $
AnnaBridge 171:3a7713b1edbc 9 ******************************************************************************
AnnaBridge 171:3a7713b1edbc 10 * Copyright 2016 Semiconductor Components Industries LLC (d/b/a “ON Semiconductor”).
AnnaBridge 171:3a7713b1edbc 11 * All rights reserved. This software and/or documentation is licensed by ON Semiconductor
AnnaBridge 171:3a7713b1edbc 12 * under limited terms and conditions. The terms and conditions pertaining to the software
AnnaBridge 171:3a7713b1edbc 13 * and/or documentation are available at http://www.onsemi.com/site/pdf/ONSEMI_T&C.pdf
AnnaBridge 171:3a7713b1edbc 14 * (“ON Semiconductor Standard Terms and Conditions of Sale, Section 8 Software”) and
AnnaBridge 171:3a7713b1edbc 15 * if applicable the software license agreement. Do not use this software and/or
AnnaBridge 171:3a7713b1edbc 16 * documentation unless you have carefully read and you agree to the limited terms and
AnnaBridge 171:3a7713b1edbc 17 * conditions. By using this software and/or documentation, you agree to the limited
AnnaBridge 171:3a7713b1edbc 18 * terms and conditions.
AnnaBridge 171:3a7713b1edbc 19 *
AnnaBridge 171:3a7713b1edbc 20 * THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED
AnnaBridge 171:3a7713b1edbc 21 * OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF
AnnaBridge 171:3a7713b1edbc 22 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE.
AnnaBridge 171:3a7713b1edbc 23 * ON SEMICONDUCTOR SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL,
AnnaBridge 171:3a7713b1edbc 24 * INCIDENTAL, OR CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER.
AnnaBridge 171:3a7713b1edbc 25 * @endinternal
AnnaBridge 171:3a7713b1edbc 26 *
AnnaBridge 171:3a7713b1edbc 27 * @ingroup bsp
AnnaBridge 171:3a7713b1edbc 28 */
AnnaBridge 171:3a7713b1edbc 29
AnnaBridge 171:3a7713b1edbc 30 #ifndef ARCHITECTURE_H_
AnnaBridge 171:3a7713b1edbc 31 #define ARCHITECTURE_H_
AnnaBridge 171:3a7713b1edbc 32
AnnaBridge 171:3a7713b1edbc 33 /*************************************************************************************************
AnnaBridge 171:3a7713b1edbc 34 * *
AnnaBridge 171:3a7713b1edbc 35 * Header files *
AnnaBridge 171:3a7713b1edbc 36 * *
AnnaBridge 171:3a7713b1edbc 37 *************************************************************************************************/
AnnaBridge 171:3a7713b1edbc 38
AnnaBridge 171:3a7713b1edbc 39 //#include <ncs36510.h>
AnnaBridge 171:3a7713b1edbc 40 //#include <system_ncs36510.h>
AnnaBridge 171:3a7713b1edbc 41 //#include <core_cm3.h>
AnnaBridge 171:3a7713b1edbc 42
AnnaBridge 171:3a7713b1edbc 43 #include "NCS36510.h"
AnnaBridge 171:3a7713b1edbc 44 #include "system_NCS36510.h"
AnnaBridge 171:3a7713b1edbc 45 #include "core_cm3.h"
AnnaBridge 171:3a7713b1edbc 46 #include "cmsis.h"
AnnaBridge 171:3a7713b1edbc 47
AnnaBridge 171:3a7713b1edbc 48
AnnaBridge 171:3a7713b1edbc 49 /*************************************************************************************************
AnnaBridge 171:3a7713b1edbc 50 * *
AnnaBridge 171:3a7713b1edbc 51 * Symbolic Constants *
AnnaBridge 171:3a7713b1edbc 52 * *
AnnaBridge 171:3a7713b1edbc 53 *************************************************************************************************/
AnnaBridge 171:3a7713b1edbc 54
AnnaBridge 171:3a7713b1edbc 55 /* Interrupt Control and State Register (0xE000ED04)
AnnaBridge 171:3a7713b1edbc 56 * 31 NMIPENDSET R/W 0 NMI pended
AnnaBridge 171:3a7713b1edbc 57 * 28 PENDSVSET R/W 0 Write 1 to pend system call; Read value
AnnaBridge 171:3a7713b1edbc 58 * indicates pending status
AnnaBridge 171:3a7713b1edbc 59 * 27 PENDSVCLR W 0 Write 1 to clear PendSV pending status
AnnaBridge 171:3a7713b1edbc 60 * 26 PENDSTSET R/W 0 Write 1 to pend Systick exception; Read
AnnaBridge 171:3a7713b1edbc 61 * value indicates pending status
AnnaBridge 171:3a7713b1edbc 62 * 25 PENDSTCLR W 0 Write 1 to clear Systick pending status
AnnaBridge 171:3a7713b1edbc 63 * 23 ISRPREEMPT R 0 Indicate that a pending interrupt is going
AnnaBridge 171:3a7713b1edbc 64 * to be active in next step (for debug)
AnnaBridge 171:3a7713b1edbc 65 * 22 ISRPENDING R 0 External interrupt pending (excluding
AnnaBridge 171:3a7713b1edbc 66 * system exceptions such as NMI for
AnnaBridge 171:3a7713b1edbc 67 * fault)
AnnaBridge 171:3a7713b1edbc 68 * 21:12 VECTPENDING R 0 Pending ISR number
AnnaBridge 171:3a7713b1edbc 69 * 11 RETTOBASE R 0 Set to 1 when the processor is running
AnnaBridge 171:3a7713b1edbc 70 * an exception handler and will return to
AnnaBridge 171:3a7713b1edbc 71 * thread level if interrupt return and no
AnnaBridge 171:3a7713b1edbc 72 * other exceptions pending
AnnaBridge 171:3a7713b1edbc 73 * 9:0 VECTACTIVE R 0 Current running interrupt service routine
AnnaBridge 171:3a7713b1edbc 74 */
AnnaBridge 171:3a7713b1edbc 75 #define RUNNING_IN_ISR (((SCB->ICSR & 0x3FF) > 0 ) ? 1 : 0)
AnnaBridge 171:3a7713b1edbc 76
AnnaBridge 171:3a7713b1edbc 77 #endif /* ARCHITECTURE_H_ */