Skip to content

Commit

Permalink
Merge pull request #127 from MikroElektronika/new-feature/stm32l412_2…
Browse files Browse the repository at this point in the history
…2_sdk_support

Added SDK support for STM32L412/422
  • Loading branch information
StrahinjaJacimovic authored Oct 31, 2024
2 parents 0436be9 + 799e1f7 commit a61f839
Show file tree
Hide file tree
Showing 79 changed files with 9,107 additions and 5 deletions.
21 changes: 21 additions & 0 deletions SUPPORTED_CHIP_LIST.md
Original file line number Diff line number Diff line change
Expand Up @@ -2293,6 +2293,27 @@
| STM32L162VEYx | ARM | `FLASH1`;`RAM1` | `2.0.0+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L162ZDTx | ARM | `FLASH1`;`RAM1` | `2.0.0+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L162ZETx | ARM | `FLASH1`;`RAM1` | `2.0.0+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L412C8Tx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L412C8Ux | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L412CBTx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L412CBUx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L412K8Tx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L412K8Ux | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L412KBTx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L412KBUx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L412R8Ix | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L412R8Tx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L412RBIx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L412RBTx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L412T8Yx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L412TBYx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L422CBTx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L422CBUx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L422KBTx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L422KBUx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L422RBIx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L422RBTx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L422TBYx | ARM | `FLASH1`;`RAM1` | `2.11.5+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | | :heavy_check_mark: |
| STM32L431CBTx | ARM | `FLASH1`;`RAM1` | `2.0.0+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
| STM32L431CBUx | ARM | `FLASH1`;`RAM1` | `2.0.0+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
| STM32L431CBYx | ARM | `FLASH1`;`RAM1` | `2.0.0+` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
Expand Down
89 changes: 89 additions & 0 deletions changelog/v2.11.5/changelog.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
<p align="center">
<img src="http://www.mikroe.com/img/designs/beta/logo_small.png?raw=true" alt="MikroElektronika"/>
</p>

---

**[BACK TO MAIN FILE](../../changelog.md)**

---

# `v2.11.5`

+ released: 2024-11-01

## Changes

+ [`v2.11.5`](#v2115)
+ [Changes](#changes)
+ [mikroSDK](#mikrosdk)
+ [CORE](#core)
+ [NEW HARDWARE](#new-hardware)

### Improvements

#### mikroSDK

**New STM32L4 MCUs supported!**

| MCU | MCU | MCU |
| :---------------: | :--------------: | :---------------: |
| STM32L412C8 | STM32L412CB | STM32L422CB |
| STM32L412K8 | STM32L412KB | STM32L422KB |
| STM32L412R8 | STM32L412RB | STM32L422RB |
| STM32L412T8 | STM32L412TB | STM32L422TB |

**Supported modules:**

+ ADC (Full module support)
+ SPI (Full module support)
+ UART (Full module support)
+ I2C (Full module support)
+ PWM (Full module support)
+ GPIO (Full module support)
+ OW (Full module support)
+ RTC (Full module support)
+ DMA (Full module support)

+ Third party modules supported
+ TinyUSB (An open source cross-platform USB stack for embedded system)
+ FatFs (Generic FAT Filesystem Module)

**Files added:**

+ `./mcu_name/mcu_definitions.h` - `https://github.com/MikroElektronika/mikrosdk_v2/blob/master/targets/arm/mikroe/common/include/mcu_definitions/STM32/mcu_name/mcu_definitions.h`
+ `./mcu_name/can_definitions.h` - `https://github.com/MikroElektronika/mikrosdk_v2/blob/master/targets/arm/mikroe/common/include/mcu_definitions/STM32/mcu_name/can_definitions.h`
+ `./mcu_name/dma_definitions.h` - `https://github.com/MikroElektronika/mikrosdk_v2/blob/master/targets/arm/mikroe/common/include/mcu_definitions/STM32/mcu_name/dma_definitions.h`
+ Added for all new MCUs in mikroSDK where mcu_name is actual chip full name with package, i.e. `STM32L412C8Tx` etc.
+ `./mcu_name/mcu_reg_addresses.h.h` - `https://github.com/MikroElektronika/mikrosdk_v2/blob/master/targets/arm/mikroe/common/include/mcu_reg_addresses/STM32/mcu_name/mcu_reg_addresses.h`
+ Added for all new MCUs in mikroSDK where mcu_name is actual chip full name, i.e. `STM32L412C8` etc.


#### CORE

+ Added USB Clock schemes for the newly supported STM32L4 MCUs:
+ STM32L412C8
+ STM32L412K8
+ STM32L412R8
+ STM32L412T8
+ STM32L412CB
+ STM32L412KB
+ STM32L412RB
+ STM32L412TB
+ STM32L422CB
+ STM32L422KB
+ STM32L422RB
+ STM32L422TB

### NEW HARDWARE

> NOTE:
>> If any new hardware was added to current version, it will be listed here.
Support added for following hardware:

---

**[BACK TO MAIN FILE](../../changelog.md)**

---
4 changes: 2 additions & 2 deletions cmake/usbUtils.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,7 @@ function(usb_set_init_sequence file_path)
set(${file_path} "arm/st/implementation_4" PARENT_SCOPE)
elseif(${MCU_NAME} MATCHES "^STM32F7.[235679].+")
set(${file_path} "arm/st/implementation_5" PARENT_SCOPE)
elseif(${MCU_NAME} MATCHES "^STM32L4[3-9A][2-9].+")
elseif(${MCU_NAME} MATCHES "^STM32L4[1-9A][2-9].+")
set(${file_path} "arm/st/implementation_6" PARENT_SCOPE)
elseif(${MCU_NAME} MATCHES "^STM32L4[PQRS][579].+")
set(${file_path} "arm/st/implementation_7" PARENT_SCOPE)
Expand Down Expand Up @@ -418,7 +418,7 @@ function(check_usb_components has_usb has_usb_interrupts usb_list)
## TODO - Add device/host definitions for supported MCUs
## TODO - Be more specific with STM32G0 MCUs
if(${MCU_NAME} MATCHES "^STM32.+")
if ((${MCU_NAME} MATCHES "^STM32((L0.[23]|F0[47][028]|F[24].[1235679]|F10[57]|F7.[235679]|L4[3-9A][2-9]|L4[PQRS][579]|F373|F10[23]|L1).+|F30(2.[68BCDE]|3.[BCDE]))"))
if ((${MCU_NAME} MATCHES "^STM32((L0.[23]|F0[47][028]|F[24].[1235679]|F10[57]|F7.[235679]|L4[1-9A][2-9]|L4[PQRS][579]|F373|F10[23]|L1).+|F30(2.[68BCDE]|3.[BCDE]))"))
if (${MCU_NAME} MATCHES "STM32G0.+")
set(has_usb_interrupts "false" PARENT_SCOPE)
endif()
Expand Down
5 changes: 2 additions & 3 deletions cmake/utils.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -161,8 +161,7 @@ endfunction()
#############################################################################
function(find_chip_architecture _chip_architecture)
if((${CORE_NAME} MATCHES "M0") OR (${CORE_NAME} MATCHES "M3") OR
(${CORE_NAME} MATCHES "M4EF") OR (${CORE_NAME} MATCHES "M4DSP") OR
(${CORE_NAME} MATCHES "M7"))
(${CORE_NAME} MATCHES "M4") OR (${CORE_NAME} MATCHES "M7"))
if(${MCU_NAME} MATCHES "^STM.*")
set(${_chip_architecture} "arm" PARENT_SCOPE)
elseif(${MCU_NAME} MATCHES "^MK.*")
Expand Down Expand Up @@ -256,7 +255,7 @@ function(set_module_support listArg listModules chip_name layer)
set(DMA FALSE)
set(RTC FALSE)

if((${MCU_NAME} MATCHES "(^STM32(F(0([47](2|8G)|9[18])|10[357]|2[01]|3[023579][2-9]|4[0-467][2-9]|7[2-7])|L4).+$)") OR (${MCU_NAME} MATCHES "(^GD32.+$)") OR (${MCU_NAME} MATCHES "(^TM4C.+$)")
if((${MCU_NAME} MATCHES "(^STM32(F(0([47](2|8G)|9[18])|10[357]|2[01]|3[023579][2-9]|4[0-467][2-9]|7[2-7])|L4[3-9A-Z]).+$)") OR (${MCU_NAME} MATCHES "(^GD32.+$)") OR (${MCU_NAME} MATCHES "(^TM4C.+$)")
OR (${MCU_NAME} MATCHES "^PIC18L?F[2468][0-9]K?8[0-9]$") OR (${MCU_NAME} MATCHES "(^(ds)?PIC(24|33)(FJ(64GP[57]|128GP[57]|256GP)|EP(256(GU|MU)|512(M[CU]8))).+$|PIC24HJ(64|128|256)GP[56][01][06]A?)|PIC24EP512G[PU]8.+")
OR (${MCU_NAME} MATCHES "(^MK(V(4|5[68]F[15][1M][02]VL)|6(4F(N1M0V|X5)|0D(N[25][15][26]V[LM][DQ]|X256V[LM][QD])|6)).+$)") OR (${MCU_NAME} MATCHES "^PIC32M(Z[0-9]+EF[FKHM].+|X[75].+)$"))
if(NOT "${MCU_NAME}${_MSDK_PACKAGE_NAME_}" MATCHES "STM32F048G6Ux|STM32F091RCIx|STM32F098RCIx|STM32F427AGIx|STM32F427AIIx|STM32F429AGIx|STM32F429AIIx|STM32F437AIIx|STM32F439AIIx|STM32F469AEIx|STM32F469AEYx|STM32F469AGIx|STM32F469AGYx|STM32F469AIIx|STM32F469AIYx|STM32F479AGIx|STM32F479AGYx|STM32F479AIIx|STM32F479AIYx|STM32F722ICHx|STM32F722IEHx|STM32F723ICHx|STM32F723IEHx|STM32F723ZCJx|STM32F723ZEJx|STM32F732IEHx|STM32F733IEHx|STM32F733ZEJx|STM32F745IEHx|STM32F745IGHx|STM32F746IEHx|STM32F746IGHx|STM32F756IGHx|STM32F765IGHx|STM32F765IIHx|STM32F767IGHx|STM32F767IIHx|STM32F777IIHx|STM32F777IIHx|STM32L431VCHx|STM32L433VCHx|STM32L443VCHx|STM32L451VCHx|STM32L451VEHx|STM32L452VCHx|STM32L452VEHx|STM32L462VEHx")
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
/****************************************************************************
**
** Copyright (C) ${COPYRIGHT_YEAR} MikroElektronika d.o.o.
** Contact: https://www.mikroe.com/contact
**
** This file is part of the mikroSDK package
**
** Commercial License Usage
**
** Licensees holding valid commercial NECTO compilers AI licenses may use this
** file in accordance with the commercial license agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and The MikroElektronika Company.
** For licensing terms and conditions see
** https://www.mikroe.com/legal/software-license-agreement.
** For further information use the contact form at
** https://www.mikroe.com/contact.
**
**
** GNU Lesser General Public License Usage
**
** Alternatively, this file may be used for
** non-commercial projects under the terms of the GNU Lesser
** General Public License version 3 as published by the Free Software
** Foundation: https://www.gnu.org/licenses/lgpl-3.0.html.
**
** The above copyright notice and this permission notice shall be
** included in all copies or substantial portions of the Software.
**
** THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
** OF MERCHANTABILITY, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
** TO THE WARRANTIES FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
** DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT
** OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE
** OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
**
****************************************************************************/
/*!
* @file can_definitions.h
* @brief MCU specific CAN module definitions for STM32L412C8Tx.
*/

#ifndef _CAN_DEFINITIONS_H_
#define _CAN_DEFINITIONS_H_

#ifdef __cplusplus
extern "C"{
#endif

// CAN
// No CAN pins for this MCU.
// No CAN modules for this MCU.
// No CAN regs for this MCU.
// No CAN helper macros for this MCU.
// EOF CAN

#ifdef __cplusplus
}
#endif

#endif // _CAN_DEFINITIONS_H_
// ------------------------------------------------------------------------- END
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
/****************************************************************************
**
** Copyright (C) ${COPYRIGHT_YEAR} MikroElektronika d.o.o.
** Contact: https://www.mikroe.com/contact
**
** This file is part of the mikroSDK package
**
** Commercial License Usage
**
** Licensees holding valid commercial NECTO compilers AI licenses may use this
** file in accordance with the commercial license agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and The MikroElektronika Company.
** For licensing terms and conditions see
** https://www.mikroe.com/legal/software-license-agreement.
** For further information use the contact form at
** https://www.mikroe.com/contact.
**
**
** GNU Lesser General Public License Usage
**
** Alternatively, this file may be used for
** non-commercial projects under the terms of the GNU Lesser
** General Public License version 3 as published by the Free Software
** Foundation: https://www.gnu.org/licenses/lgpl-3.0.html.
**
** The above copyright notice and this permission notice shall be
** included in all copies or substantial portions of the Software.
**
** THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
** OF MERCHANTABILITY, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
** TO THE WARRANTIES FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
** DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT
** OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE
** OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
**
****************************************************************************/
/*!
* @file dma_definitions.h
* @brief MCU specific DMA module definitions for STM32L412C8Tx.
*/

#ifndef _DMA_DEFINITIONS_H_
#define _DMA_DEFINITIONS_H_

#ifdef __cplusplus
extern "C"{
#endif

// DMA
#define DMA_NUM_OF_MODULES 2
#define DMA_NUM_OF_STREAMS 7
#define DMA_NUM_OF_STREAMS_FAMILY 7
#define DMA_NUM_OF_CHANNELS 7
#define DMA_NUM_OF_CHANNELS_FAMILY 7
// EOF DMA

#ifdef __cplusplus
}
#endif

#endif // _DMA_DEFINITIONS_H_
// ------------------------------------------------------------------------- END
Loading

0 comments on commit a61f839

Please sign in to comment.