Add new driver implementations and workspace updates

This commit is contained in:
Kevin Thomas
2026-03-27 11:18:29 -04:00
parent 1c02ebd76e
commit bef5e91fbf
7844 changed files with 30810 additions and 2 deletions
+47
View File
@@ -0,0 +1,47 @@
/**
* FILE: stack.s
*
* DESCRIPTION:
* RP2350 Stack Initialization.
*
* BRIEF:
* Provides stack pointer initialization for Main and Process Stack
* Pointers (MSP/PSP) and their limits.
*
* AUTHOR: Kevin Thomas
* CREATION DATE: November 27, 2025
* UPDATE DATE: November 27, 2025
*/
.syntax unified // use unified assembly syntax
.cpu cortex-m33 // target Cortex-M33 core
.thumb // use Thumb instruction set
.include "constants.s"
/**
* Initialize the .text section.
* The .text section contains executable code.
*/
.section .text // code section
.align 2 // align to 4-byte boundary
/**
* @brief Initialize stack pointers.
*
* @details Sets Main and Process Stack Pointers (MSP/PSP) and their limits.
*
* @param None
* @retval None
*/
.global Init_Stack
.type Init_Stack, %function
Init_Stack:
ldr r0, =STACK_TOP // load stack top
msr PSP, r0 // set PSP
ldr r0, =STACK_LIMIT // load stack limit
msr MSPLIM, r0 // set MSP limit
msr PSPLIM, r0 // set PSP limit
ldr r0, =STACK_TOP // reload stack top
msr MSP, r0 // set MSP
bx lr // return