OpenMPTL - ARM Cortex (common)
C++ Microprocessor Template Library
dwt.hpp
Go to the documentation of this file.
1 /*
2  * OpenMPTL - C++ Microprocessor Template Library
3  *
4  * Copyright (C) 2012-2017 Axel Burri <axel@tty0.ch>
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 3 of the License, or
9  * (at your option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program. If not, see <http://www.gnu.org/licenses/>.
18  *
19  */
20 
21 #ifndef ARM_CORTEX_COMMON_REG_DWT_HPP_INCLUDED
22 #define ARM_CORTEX_COMMON_REG_DWT_HPP_INCLUDED
23 
24 #include <register.hpp>
25 
26 namespace mptl {
27 
28 /**
29  * DWT Register
30  *
31  * For details, see "Cortex-M3 Technical Reference Manual":
32  * <http://infocenter.arm.com/help/topic/com.arm.doc.subset.cortexm.m3/index.html>
33  */
34 struct DWT
35 {
36  using CTRL = reg<uint32_t, 0xE0001000, rw>; /**< Control Register */
37  using CYCCNT = reg<uint32_t, 0xE0001004, rw>; /**< Cycle Count Register */
38  using CPICNT = reg<uint32_t, 0xE0001008, rw>; /**< CPI Count Register */
39  using EXCCNT = reg<uint32_t, 0xE000100C, rw>; /**< Exception Overhead Count Register */
40  using SLEEPCNT = reg<uint32_t, 0xE0001010, rw>; /**< Sleep Count Register */
41  using LSUCNT = reg<uint32_t, 0xE0001014, rw>; /**< LSU Count Register */
42  using FOLDCNT = reg<uint32_t, 0xE0001018, rw>; /**< Folded-instruction Count Register */
43  using PCSR = reg<uint32_t, 0xE000101C, ro>; /**< Program Counter Sample Register */
44  using COMP0 = reg<uint32_t, 0xE0001020, rw>; /**< Comparator Register0 */
45  using MASK0 = reg<uint32_t, 0xE0001024, rw>; /**< Mask Register0 */
46  using FUNCTION0 = reg<uint32_t, 0xE0001028, rw>; /**< Function Register0 */
47  using COMP1 = reg<uint32_t, 0xE0001030, rw>; /**< Comparator Register1 */
48  using MASK1 = reg<uint32_t, 0xE0001034, rw>; /**< Mask Register1 */
49  using FUNCTION1 = reg<uint32_t, 0xE0001038, rw>; /**< Function Register1 */
50  using COMP2 = reg<uint32_t, 0xE0001040, rw>; /**< Comparator Register2 */
51  using MASK2 = reg<uint32_t, 0xE0001044, rw>; /**< Mask Register2 */
52  using FUNCTION2 = reg<uint32_t, 0xE0001048, rw>; /**< Function Register2 */
53  using COMP3 = reg<uint32_t, 0xE0001050, rw>; /**< Comparator Register3 */
54  using MASK3 = reg<uint32_t, 0xE0001054, rw>; /**< Mask Register3 */
55  using FUNCTION3 = reg<uint32_t, 0xE0001058, rw>; /**< Function Register3 */
56  using PID4 = reg<uint32_t, 0xE0001FD0, ro, 0x04 >; /**< Peripheral identification registers */
64  using CID0 = reg<uint32_t, 0xE0001FF0, ro, 0x0D >; /**< Component identification registers */
68 };
69 
70 } // namespace mptl
71 
72 #endif // ARM_CORTEX_COMMON_REG_DWT_HPP_INCLUDED
DWT Register.
Definition: dwt.hpp:34