Skip to content

Commit 829276a

Browse files
Jacob-Scheifflerpetejohanson-adi
authored andcommitted
MAX32520: Fix I2C slave address register offset. (#384)
Co-authored-by: Scheiffler <[email protected]> MSDK-Commit: e5a58576da502c7b71cdf7e5b034c7d72b195d8c
1 parent 9a2b582 commit 829276a

File tree

1 file changed

+48
-47
lines changed
  • MAX/Libraries/CMSIS/Device/Maxim/MAX32520/Include

1 file changed

+48
-47
lines changed

MAX/Libraries/CMSIS/Device/Maxim/MAX32520/Include/i2c_regs.h

Lines changed: 48 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -5,37 +5,37 @@
55
*/
66

77
/******************************************************************************
8-
* Copyright (C) 2022 Maxim Integrated Products, Inc., All Rights Reserved.
9-
*
10-
* Permission is hereby granted, free of charge, to any person obtaining a
11-
* copy of this software and associated documentation files (the "Software"),
12-
* to deal in the Software without restriction, including without limitation
13-
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
14-
* and/or sell copies of the Software, and to permit persons to whom the
15-
* Software is furnished to do so, subject to the following conditions:
16-
*
17-
* The above copyright notice and this permission notice shall be included
18-
* in all copies or substantial portions of the Software.
19-
*
20-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
21-
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
22-
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
23-
* IN NO EVENT SHALL MAXIM INTEGRATED BE LIABLE FOR ANY CLAIM, DAMAGES
24-
* OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
25-
* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
26-
* OTHER DEALINGS IN THE SOFTWARE.
27-
*
28-
* Except as contained in this notice, the name of Maxim Integrated
29-
* Products, Inc. shall not be used except as stated in the Maxim Integrated
30-
* Products, Inc. Branding Policy.
31-
*
32-
* The mere transfer of this software does not imply any licenses
33-
* of trade secrets, proprietary technology, copyrights, patents,
34-
* trademarks, maskwork rights, or any other form of intellectual
35-
* property whatsoever. Maxim Integrated Products, Inc. retains all
36-
* ownership rights.
37-
*
38-
******************************************************************************/
8+
* Copyright (C) 2023 Maxim Integrated Products, Inc., All Rights Reserved.
9+
*
10+
* Permission is hereby granted, free of charge, to any person obtaining a
11+
* copy of this software and associated documentation files (the "Software"),
12+
* to deal in the Software without restriction, including without limitation
13+
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
14+
* and/or sell copies of the Software, and to permit persons to whom the
15+
* Software is furnished to do so, subject to the following conditions:
16+
*
17+
* The above copyright notice and this permission notice shall be included
18+
* in all copies or substantial portions of the Software.
19+
*
20+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
21+
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
22+
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
23+
* IN NO EVENT SHALL MAXIM INTEGRATED BE LIABLE FOR ANY CLAIM, DAMAGES
24+
* OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
25+
* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
26+
* OTHER DEALINGS IN THE SOFTWARE.
27+
*
28+
* Except as contained in this notice, the name of Maxim Integrated
29+
* Products, Inc. shall not be used except as stated in the Maxim Integrated
30+
* Products, Inc. Branding Policy.
31+
*
32+
* The mere transfer of this software does not imply any licenses
33+
* of trade secrets, proprietary technology, copyrights, patents,
34+
* trademarks, maskwork rights, or any other form of intellectual
35+
* property whatsoever. Maxim Integrated Products, Inc. retains all
36+
* ownership rights.
37+
*
38+
******************************************************************************/
3939

4040
#ifndef LIBRARIES_CMSIS_DEVICE_MAXIM_MAX32520_INCLUDE_I2C_REGS_H_
4141
#define LIBRARIES_CMSIS_DEVICE_MAXIM_MAX32520_INCLUDE_I2C_REGS_H_
@@ -103,8 +103,9 @@ typedef struct {
103103
__IO uint32_t ckh; /**< <tt>\b 0x38:</tt> I2C CKH Register */
104104
__R uint32_t rsv_0x3c;
105105
__IO uint32_t to; /**< <tt>\b 0x40:</tt> I2C TO Register */
106-
__IO uint32_t sla; /**< <tt>\b 0x44:</tt> I2C SLA Register */
106+
__R uint32_t rsv_0x44;
107107
__IO uint32_t dma; /**< <tt>\b 0x48:</tt> I2C DMA Register */
108+
__IO uint32_t sla; /**< <tt>\b 0x4C:</tt> I2C SLA Register */
108109
} mxc_i2c_regs_t;
109110

110111
/* Register offsets for module I2C */
@@ -130,8 +131,8 @@ typedef struct {
130131
#define MXC_R_I2C_CKL ((uint32_t)0x00000034UL) /**< Offset from I2C Base Address: <tt> 0x0034</tt> */
131132
#define MXC_R_I2C_CKH ((uint32_t)0x00000038UL) /**< Offset from I2C Base Address: <tt> 0x0038</tt> */
132133
#define MXC_R_I2C_TO ((uint32_t)0x00000040UL) /**< Offset from I2C Base Address: <tt> 0x0040</tt> */
133-
#define MXC_R_I2C_SLA ((uint32_t)0x00000044UL) /**< Offset from I2C Base Address: <tt> 0x0044</tt> */
134134
#define MXC_R_I2C_DMA ((uint32_t)0x00000048UL) /**< Offset from I2C Base Address: <tt> 0x0048</tt> */
135+
#define MXC_R_I2C_SLA ((uint32_t)0x0000004CUL) /**< Offset from I2C Base Address: <tt> 0x004C</tt> */
135136
/**@} end of group i2c_registers */
136137

137138
/**
@@ -502,6 +503,20 @@ typedef struct {
502503

503504
/**@} end of group I2C_TO_Register */
504505

506+
/**
507+
* @ingroup i2c_registers
508+
* @defgroup I2C_DMA I2C_DMA
509+
* @brief DMA Register.
510+
* @{
511+
*/
512+
#define MXC_F_I2C_DMA_TXEN_POS 0 /**< DMA_TXEN Position */
513+
#define MXC_F_I2C_DMA_TXEN ((uint32_t)(0x1UL << MXC_F_I2C_DMA_TXEN_POS)) /**< DMA_TXEN Mask */
514+
515+
#define MXC_F_I2C_DMA_RXEN_POS 1 /**< DMA_RXEN Position */
516+
#define MXC_F_I2C_DMA_RXEN ((uint32_t)(0x1UL << MXC_F_I2C_DMA_RXEN_POS)) /**< DMA_RXEN Mask */
517+
518+
/**@} end of group I2C_DMA_Register */
519+
505520
/**
506521
* @ingroup i2c_registers
507522
* @defgroup I2C_SLA I2C_SLA
@@ -520,20 +535,6 @@ typedef struct {
520535

521536
/**@} end of group I2C_SLA_Register */
522537

523-
/**
524-
* @ingroup i2c_registers
525-
* @defgroup I2C_DMA I2C_DMA
526-
* @brief DMA Register.
527-
* @{
528-
*/
529-
#define MXC_F_I2C_DMA_TXEN_POS 0 /**< DMA_TXEN Position */
530-
#define MXC_F_I2C_DMA_TXEN ((uint32_t)(0x1UL << MXC_F_I2C_DMA_TXEN_POS)) /**< DMA_TXEN Mask */
531-
532-
#define MXC_F_I2C_DMA_RXEN_POS 1 /**< DMA_RXEN Position */
533-
#define MXC_F_I2C_DMA_RXEN ((uint32_t)(0x1UL << MXC_F_I2C_DMA_RXEN_POS)) /**< DMA_RXEN Mask */
534-
535-
/**@} end of group I2C_DMA_Register */
536-
537538
#ifdef __cplusplus
538539
}
539540
#endif

0 commit comments

Comments
 (0)