SlideShare a Scribd company logo
Computer Programming and MCUs:
- Assembly Language
- STM32CubeIDE
- STM32F3DISCOVERY Board MCU
Objectives:
1. Create a function that can chase an LED around the LED circle. This means that only one LED
should be on, and the currently on LED will move either clockwise, or anti-clockwise around the
circle of LEDs. Provide a value to the function in R1 which selects whether the LED goes
clockwise or anti-clockwise. Provide a value to the function in R2 which selects how many LEDs
should be on at the same time (1 LED chasing, 2 LEDs chasing, etc).
2. Make a map between an ASCII character and a pattern of LEDs being on/off. Demonstrate this
with a function that uses an ASCII value stored in R1 to turn the LEDs on/off to show the pattern.
3. Use the discovery board user input button to step through the characters in an ASCII string and
show the LED patterns one at a time.
General Assumptions/hints:
- User Button located in GPIO port A (base address: 0x48000000)
- LEDs located in GPIO port E (base address: 0x48001000)
- LED circle located in GPIO port E, bits 8-15
- Use STM32F3-Reference-Manual-Large.pdf for register addresses/offsets
Basic steps:
1. Enable the clock for each I/O port we want to use
2. Setup GPIO Registers (Button = input, LEDs = output)
3. Read from input or write from output
STM32F3DISCOVERY Board MCU:
STM32CubeIDE:
P. Project Explorer x Thern arn no projects in ynur workspaca. To add a project: Create a mew
Makefile project in a directory centaining revisting cade Create a new C or Ct+ prodect Crate a
Naw STM37 prolact Craata a Naw StM37 Proinct fram an Fristing Create a project... timpert
projects... D itams selected

More Related Content

PDF
Computer Programming Task- Assembly Language- STM32F3 DISCOVERY.pdf
PPTX
Bidirect visitor counter
PDF
IOT WORKSHEET 1.4.pdf
PPTX
Python-in-Embedded-systems.pptx
PDF
Mechatronics material . Mechanical engineering
PPTX
Introduction to Arduino.pptx
PPSX
Arduino by yogesh t s'
DOCX
Lab Manual Arduino UNO Microcontrollar.docx
Computer Programming Task- Assembly Language- STM32F3 DISCOVERY.pdf
Bidirect visitor counter
IOT WORKSHEET 1.4.pdf
Python-in-Embedded-systems.pptx
Mechatronics material . Mechanical engineering
Introduction to Arduino.pptx
Arduino by yogesh t s'
Lab Manual Arduino UNO Microcontrollar.docx

Similar to Computer Programming and MCUs Assembly Language STM32Cu.pdf (20)

PPTX
Introduction to Arduino session and basically it depends how you us and where...
PDF
Programming the ARM CORTEX M3 based STM32F100RBT6 Value Line Discovery Board
PPTX
Arduino basics & programming skill development
PPTX
Arduino Introduction PPT for school students
DOCX
Arduino and Circuits.docx
PPT
Arduino is an open-source electronics platform that has an easy-to-use physic...
PDF
Rdl esp32 development board trainer kit
PPTX
Industrial Applications of Arduino using Ladder Logic
PPT
Arduino wk2
PPT
Fundamentals of programming Arduino-Wk2.ppt
PDF
Arduino: Arduino starter kit
PPT
ANALYSIS & DESIGN OF COMBINATIONAL LOGIC
PPTX
arduino and its introduction deep dive ppt.pptx
PPTX
Internet of Things prescribed by University
PDF
Weather monitoring System Using STM32
PDF
Arduino_IOT Arduino_IOT Arduino_IOTArdui
DOCX
A Report on Bidirectional Visitor Counter using IR sensors and Arduino Uno R3
PDF
VHDL or Verilog: describe your adder and correction logic
PPTX
6-MicrocontrollersSystemLessonOneSix.pptx
PDF
Contactless digital tachometer using microcontroller
Introduction to Arduino session and basically it depends how you us and where...
Programming the ARM CORTEX M3 based STM32F100RBT6 Value Line Discovery Board
Arduino basics & programming skill development
Arduino Introduction PPT for school students
Arduino and Circuits.docx
Arduino is an open-source electronics platform that has an easy-to-use physic...
Rdl esp32 development board trainer kit
Industrial Applications of Arduino using Ladder Logic
Arduino wk2
Fundamentals of programming Arduino-Wk2.ppt
Arduino: Arduino starter kit
ANALYSIS & DESIGN OF COMBINATIONAL LOGIC
arduino and its introduction deep dive ppt.pptx
Internet of Things prescribed by University
Weather monitoring System Using STM32
Arduino_IOT Arduino_IOT Arduino_IOTArdui
A Report on Bidirectional Visitor Counter using IR sensors and Arduino Uno R3
VHDL or Verilog: describe your adder and correction logic
6-MicrocontrollersSystemLessonOneSix.pptx
Contactless digital tachometer using microcontroller
Ad

More from ableelectronics (20)

PDF
Background InfoDichotomous keys can be used to help identify.pdf
PDF
At the beginning of the video Lead like the great conductors.pdf
PDF
7 TF The longer the password the tougher it is to crack.pdf
PDF
A researcher for the EPA measured the amount of arsenic in t.pdf
PDF
Earthquake Epicenter Locations and Depths The letters on th.pdf
PDF
6 Consider a random sample X1Xn of size n from a Gamma.pdf
PDF
11 Jacobs Co sat grevlileri ve yneticileri tarafndan i .pdf
PDF
Chief Complaint 23yearold man with immunce deficiency His.pdf
PDF
Why did we choose to process BMP image files rather than ot.pdf
PDF
Using the data in the table what is Walmarts NYSE WMT b.pdf
PDF
void f int x The above code is a c++ function In ter.pdf
PDF
This project is broken up into Windows and Mac versions lis.pdf
PDF
The as of Ct+11 allows what benefit It can be shared by .pdf
PDF
Tartma stemi Yantlamak iin aadaki sorulardan birini sein.pdf
PDF
Supportive leadership is the same as which of the following .pdf
PDF
System Analysis Assignment 4 Due date See LEARN Max Marks.pdf
PDF
Sarah tiene 30 aos y es madre de dos nios pequeos de 3 y.pdf
PDF
Real GDP per capita in the country of Arcadia grew from abou.pdf
PDF
Rex y Felix son los nicos accionistas de Dogs and Cats Corp.pdf
PDF
please use only these Part 1 Organize the code 85 Fo.pdf
Background InfoDichotomous keys can be used to help identify.pdf
At the beginning of the video Lead like the great conductors.pdf
7 TF The longer the password the tougher it is to crack.pdf
A researcher for the EPA measured the amount of arsenic in t.pdf
Earthquake Epicenter Locations and Depths The letters on th.pdf
6 Consider a random sample X1Xn of size n from a Gamma.pdf
11 Jacobs Co sat grevlileri ve yneticileri tarafndan i .pdf
Chief Complaint 23yearold man with immunce deficiency His.pdf
Why did we choose to process BMP image files rather than ot.pdf
Using the data in the table what is Walmarts NYSE WMT b.pdf
void f int x The above code is a c++ function In ter.pdf
This project is broken up into Windows and Mac versions lis.pdf
The as of Ct+11 allows what benefit It can be shared by .pdf
Tartma stemi Yantlamak iin aadaki sorulardan birini sein.pdf
Supportive leadership is the same as which of the following .pdf
System Analysis Assignment 4 Due date See LEARN Max Marks.pdf
Sarah tiene 30 aos y es madre de dos nios pequeos de 3 y.pdf
Real GDP per capita in the country of Arcadia grew from abou.pdf
Rex y Felix son los nicos accionistas de Dogs and Cats Corp.pdf
please use only these Part 1 Organize the code 85 Fo.pdf
Ad

Recently uploaded (20)

PPTX
Final Presentation General Medicine 03-08-2024.pptx
PPTX
202450812 BayCHI UCSC-SV 20250812 v17.pptx
PPTX
Introduction-to-Literarature-and-Literary-Studies-week-Prelim-coverage.pptx
PPTX
Pharmacology of Heart Failure /Pharmacotherapy of CHF
PPTX
Tissue processing ( HISTOPATHOLOGICAL TECHNIQUE
PDF
OBE - B.A.(HON'S) IN INTERIOR ARCHITECTURE -Ar.MOHIUDDIN.pdf
PDF
The Lost Whites of Pakistan by Jahanzaib Mughal.pdf
PPTX
human mycosis Human fungal infections are called human mycosis..pptx
PDF
Black Hat USA 2025 - Micro ICS Summit - ICS/OT Threat Landscape
PPTX
Pharma ospi slides which help in ospi learning
PPTX
Institutional Correction lecture only . . .
PDF
102 student loan defaulters named and shamed – Is someone you know on the list?
PPTX
GDM (1) (1).pptx small presentation for students
PDF
A GUIDE TO GENETICS FOR UNDERGRADUATE MEDICAL STUDENTS
PDF
RMMM.pdf make it easy to upload and study
PDF
01-Introduction-to-Information-Management.pdf
PPTX
PPT- ENG7_QUARTER1_LESSON1_WEEK1. IMAGERY -DESCRIPTIONS pptx.pptx
PDF
Chapter 2 Heredity, Prenatal Development, and Birth.pdf
PPTX
Lesson notes of climatology university.
PDF
2.FourierTransform-ShortQuestionswithAnswers.pdf
Final Presentation General Medicine 03-08-2024.pptx
202450812 BayCHI UCSC-SV 20250812 v17.pptx
Introduction-to-Literarature-and-Literary-Studies-week-Prelim-coverage.pptx
Pharmacology of Heart Failure /Pharmacotherapy of CHF
Tissue processing ( HISTOPATHOLOGICAL TECHNIQUE
OBE - B.A.(HON'S) IN INTERIOR ARCHITECTURE -Ar.MOHIUDDIN.pdf
The Lost Whites of Pakistan by Jahanzaib Mughal.pdf
human mycosis Human fungal infections are called human mycosis..pptx
Black Hat USA 2025 - Micro ICS Summit - ICS/OT Threat Landscape
Pharma ospi slides which help in ospi learning
Institutional Correction lecture only . . .
102 student loan defaulters named and shamed – Is someone you know on the list?
GDM (1) (1).pptx small presentation for students
A GUIDE TO GENETICS FOR UNDERGRADUATE MEDICAL STUDENTS
RMMM.pdf make it easy to upload and study
01-Introduction-to-Information-Management.pdf
PPT- ENG7_QUARTER1_LESSON1_WEEK1. IMAGERY -DESCRIPTIONS pptx.pptx
Chapter 2 Heredity, Prenatal Development, and Birth.pdf
Lesson notes of climatology university.
2.FourierTransform-ShortQuestionswithAnswers.pdf

Computer Programming and MCUs Assembly Language STM32Cu.pdf

  • 1. Computer Programming and MCUs: - Assembly Language - STM32CubeIDE - STM32F3DISCOVERY Board MCU Objectives: 1. Create a function that can chase an LED around the LED circle. This means that only one LED should be on, and the currently on LED will move either clockwise, or anti-clockwise around the circle of LEDs. Provide a value to the function in R1 which selects whether the LED goes clockwise or anti-clockwise. Provide a value to the function in R2 which selects how many LEDs should be on at the same time (1 LED chasing, 2 LEDs chasing, etc). 2. Make a map between an ASCII character and a pattern of LEDs being on/off. Demonstrate this with a function that uses an ASCII value stored in R1 to turn the LEDs on/off to show the pattern. 3. Use the discovery board user input button to step through the characters in an ASCII string and show the LED patterns one at a time. General Assumptions/hints: - User Button located in GPIO port A (base address: 0x48000000) - LEDs located in GPIO port E (base address: 0x48001000) - LED circle located in GPIO port E, bits 8-15 - Use STM32F3-Reference-Manual-Large.pdf for register addresses/offsets Basic steps: 1. Enable the clock for each I/O port we want to use 2. Setup GPIO Registers (Button = input, LEDs = output) 3. Read from input or write from output STM32F3DISCOVERY Board MCU: STM32CubeIDE: P. Project Explorer x Thern arn no projects in ynur workspaca. To add a project: Create a mew Makefile project in a directory centaining revisting cade Create a new C or Ct+ prodect Crate a Naw STM37 prolact Craata a Naw StM37 Proinct fram an Fristing Create a project... timpert projects... D itams selected