lab 3 setup

This commit is contained in:
Trevor Barnes
2019-10-01 16:05:43 -05:00
parent 32dc2af089
commit c5042a621f
25 changed files with 2767 additions and 1893 deletions

View File

@@ -0,0 +1,9 @@
# gpio.s
# Trevor Barnes
# CE2801-031
# Description: A file to handle the GPIO behavior of the Dev Board
.syntax unified
.cpu cortex-m4
.thumb
.section .text

25
lab3subroutines/src/led.s Normal file
View File

@@ -0,0 +1,25 @@
# led.s
# Trevor Barnes
# CE2801-031
# Description: A file for handling the LED pins on the Dev Board
# Lights are on PB5-PB15 except PB11
.syntax unified
.cpu cortex-m4
.thumb
.section .text
# Base RCC
.equ RCC_BASE, 0x40023800
# GPIOB Enable Register
.equ RCC_AHB1ENR, 0x30
# GPIOB Enable
.equ RCC_GPIOBEN, 1<<1
# Base GPIOB Location
.equ GPIOB_BASE, 0x40020400
# GPIO Mode Register
.equ GPIO_MODER, 0x00
# GPIO Output Data Register
.equ GPIO_ODR, 0x14

View File

@@ -0,0 +1,15 @@
# main.s
# Trevor Barnes
# CE2801-031
# Lab 3: Subroutines
# Description:
.syntax unified
.cpu cortex-m4
.thumb
.section .text
.global main
main: