Greg Steiert / pegasus_dev

Dependents:   blinky_max32630fthr

Committer:
switches
Date:
Fri Dec 16 16:27:57 2016 +0000
Revision:
3:1198227e6421
Parent:
0:5c4d7b2438d3
Changed ADC scale for MAX32625 platforms to 1.2V full scale to match MAX32630 platforms

Who changed what in which revision?

UserRevisionLine numberNew contents of line
switches 0:5c4d7b2438d3 1 /*******************************************************************************
switches 0:5c4d7b2438d3 2 * Copyright (C) 2016 Maxim Integrated Products, Inc., All Rights Reserved.
switches 0:5c4d7b2438d3 3 *
switches 0:5c4d7b2438d3 4 * Permission is hereby granted, free of charge, to any person obtaining a
switches 0:5c4d7b2438d3 5 * copy of this software and associated documentation files (the "Software"),
switches 0:5c4d7b2438d3 6 * to deal in the Software without restriction, including without limitation
switches 0:5c4d7b2438d3 7 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
switches 0:5c4d7b2438d3 8 * and/or sell copies of the Software, and to permit persons to whom the
switches 0:5c4d7b2438d3 9 * Software is furnished to do so, subject to the following conditions:
switches 0:5c4d7b2438d3 10 *
switches 0:5c4d7b2438d3 11 * The above copyright notice and this permission notice shall be included
switches 0:5c4d7b2438d3 12 * in all copies or substantial portions of the Software.
switches 0:5c4d7b2438d3 13 *
switches 0:5c4d7b2438d3 14 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
switches 0:5c4d7b2438d3 15 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
switches 0:5c4d7b2438d3 16 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
switches 0:5c4d7b2438d3 17 * IN NO EVENT SHALL MAXIM INTEGRATED BE LIABLE FOR ANY CLAIM, DAMAGES
switches 0:5c4d7b2438d3 18 * OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
switches 0:5c4d7b2438d3 19 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
switches 0:5c4d7b2438d3 20 * OTHER DEALINGS IN THE SOFTWARE.
switches 0:5c4d7b2438d3 21 *
switches 0:5c4d7b2438d3 22 * Except as contained in this notice, the name of Maxim Integrated
switches 0:5c4d7b2438d3 23 * Products, Inc. shall not be used except as stated in the Maxim Integrated
switches 0:5c4d7b2438d3 24 * Products, Inc. Branding Policy.
switches 0:5c4d7b2438d3 25 *
switches 0:5c4d7b2438d3 26 * The mere transfer of this software does not imply any licenses
switches 0:5c4d7b2438d3 27 * of trade secrets, proprietary technology, copyrights, patents,
switches 0:5c4d7b2438d3 28 * trademarks, maskwork rights, or any other form of intellectual
switches 0:5c4d7b2438d3 29 * property whatsoever. Maxim Integrated Products, Inc. retains all
switches 0:5c4d7b2438d3 30 * ownership rights.
switches 0:5c4d7b2438d3 31 ******************************************************************************/
switches 0:5c4d7b2438d3 32
switches 0:5c4d7b2438d3 33 #ifndef _MXC_CRC_REGS_H_
switches 0:5c4d7b2438d3 34 #define _MXC_CRC_REGS_H_
switches 0:5c4d7b2438d3 35
switches 0:5c4d7b2438d3 36 #ifdef __cplusplus
switches 0:5c4d7b2438d3 37 extern "C" {
switches 0:5c4d7b2438d3 38 #endif
switches 0:5c4d7b2438d3 39
switches 0:5c4d7b2438d3 40 #include <stdint.h>
switches 0:5c4d7b2438d3 41 #include "mxc_device.h"
switches 0:5c4d7b2438d3 42
switches 0:5c4d7b2438d3 43 /*
switches 0:5c4d7b2438d3 44 If types are not defined elsewhere (CMSIS) define them here
switches 0:5c4d7b2438d3 45 */
switches 0:5c4d7b2438d3 46 #ifndef __IO
switches 0:5c4d7b2438d3 47 #define __IO volatile
switches 0:5c4d7b2438d3 48 #endif
switches 0:5c4d7b2438d3 49 #ifndef __I
switches 0:5c4d7b2438d3 50 #define __I volatile const
switches 0:5c4d7b2438d3 51 #endif
switches 0:5c4d7b2438d3 52 #ifndef __O
switches 0:5c4d7b2438d3 53 #define __O volatile
switches 0:5c4d7b2438d3 54 #endif
switches 0:5c4d7b2438d3 55
switches 0:5c4d7b2438d3 56
switches 0:5c4d7b2438d3 57 /*
switches 0:5c4d7b2438d3 58 Typedefed structure(s) for module registers (per instance or section) with direct 32-bit
switches 0:5c4d7b2438d3 59 access to each register in module.
switches 0:5c4d7b2438d3 60 */
switches 0:5c4d7b2438d3 61
switches 0:5c4d7b2438d3 62 /* Offset Register Description
switches 0:5c4d7b2438d3 63 ============= ============================================================================ */
switches 0:5c4d7b2438d3 64 typedef struct {
switches 0:5c4d7b2438d3 65 __IO uint32_t reseed; /* 0x0000 CRC-16/CRC-32 Reseed Controls */
switches 0:5c4d7b2438d3 66 __IO uint32_t seed16; /* 0x0004 Reseed Value for CRC-16 Calculations */
switches 0:5c4d7b2438d3 67 __IO uint32_t seed32; /* 0x0008 Reseed Value for CRC-32 Calculations */
switches 0:5c4d7b2438d3 68 } mxc_crc_regs_t;
switches 0:5c4d7b2438d3 69
switches 0:5c4d7b2438d3 70
switches 0:5c4d7b2438d3 71 /* Offset Register Description
switches 0:5c4d7b2438d3 72 ============= ============================================================================ */
switches 0:5c4d7b2438d3 73 typedef struct {
switches 0:5c4d7b2438d3 74 __IO uint32_t value16[512]; /* 0x0000-0x07FC Write Next CRC-16 Data Value / Read CRC-16 Result Value */
switches 0:5c4d7b2438d3 75 __IO uint32_t value32[512]; /* 0x0800-0x0FFC Write Next CRC-32 Data Value / Read CRC-32 Result Value */
switches 0:5c4d7b2438d3 76 } mxc_crc_data_regs_t;
switches 0:5c4d7b2438d3 77
switches 0:5c4d7b2438d3 78
switches 0:5c4d7b2438d3 79 /*
switches 0:5c4d7b2438d3 80 Register offsets for module CRC.
switches 0:5c4d7b2438d3 81 */
switches 0:5c4d7b2438d3 82
switches 0:5c4d7b2438d3 83 #define MXC_R_CRC_OFFS_RESEED ((uint32_t)0x00000000UL)
switches 0:5c4d7b2438d3 84 #define MXC_R_CRC_OFFS_SEED16 ((uint32_t)0x00000004UL)
switches 0:5c4d7b2438d3 85 #define MXC_R_CRC_OFFS_SEED32 ((uint32_t)0x00000008UL)
switches 0:5c4d7b2438d3 86 #define MXC_R_CRC_DATA_OFFS_VALUE16 ((uint32_t)0x00000000UL)
switches 0:5c4d7b2438d3 87 #define MXC_R_CRC_DATA_OFFS_VALUE32 ((uint32_t)0x00000800UL)
switches 0:5c4d7b2438d3 88
switches 0:5c4d7b2438d3 89
switches 0:5c4d7b2438d3 90 /*
switches 0:5c4d7b2438d3 91 Field positions and masks for module CRC.
switches 0:5c4d7b2438d3 92 */
switches 0:5c4d7b2438d3 93
switches 0:5c4d7b2438d3 94 #define MXC_F_CRC_RESEED_CRC16_POS 0
switches 0:5c4d7b2438d3 95 #define MXC_F_CRC_RESEED_CRC16 ((uint32_t)(0x00000001UL << MXC_F_CRC_RESEED_CRC16_POS))
switches 0:5c4d7b2438d3 96 #define MXC_F_CRC_RESEED_CRC32_POS 1
switches 0:5c4d7b2438d3 97 #define MXC_F_CRC_RESEED_CRC32 ((uint32_t)(0x00000001UL << MXC_F_CRC_RESEED_CRC32_POS))
switches 0:5c4d7b2438d3 98 #define MXC_F_CRC_RESEED_REV_ENDIAN16_POS 4
switches 0:5c4d7b2438d3 99 #define MXC_F_CRC_RESEED_REV_ENDIAN16 ((uint32_t)(0x00000001UL << MXC_F_CRC_RESEED_REV_ENDIAN16_POS))
switches 0:5c4d7b2438d3 100 #define MXC_F_CRC_RESEED_REV_ENDIAN32_POS 5
switches 0:5c4d7b2438d3 101 #define MXC_F_CRC_RESEED_REV_ENDIAN32 ((uint32_t)(0x00000001UL << MXC_F_CRC_RESEED_REV_ENDIAN32_POS))
switches 0:5c4d7b2438d3 102 #define MXC_F_CRC_RESEED_CCITT_MODE_POS 8
switches 0:5c4d7b2438d3 103 #define MXC_F_CRC_RESEED_CCITT_MODE ((uint32_t)(0x00000001UL << MXC_F_CRC_RESEED_CCITT_MODE_POS))
switches 0:5c4d7b2438d3 104
switches 0:5c4d7b2438d3 105
switches 0:5c4d7b2438d3 106
switches 0:5c4d7b2438d3 107 #ifdef __cplusplus
switches 0:5c4d7b2438d3 108 }
switches 0:5c4d7b2438d3 109 #endif
switches 0:5c4d7b2438d3 110
switches 0:5c4d7b2438d3 111 #endif /* _MXC_CRC_REGS_H_ */
switches 0:5c4d7b2438d3 112