Mastering Microcontroller with Peripheral Driver Development : GPIO,I2C,SPI,USART and more

Kiran Nayak, Embedded/Firmware Engineering

Play Speed
  • 0.5x
  • 1x (Normal)
  • 1.25x
  • 1.5x
  • 2x
185 Videos (8h 19m)
    • Course Overview

      6:21
    • GPIO pin and GPIO port

      2:22
    • GPIO behind the scene

      3:00
    • GPIO input mode with high impedance state

      1:13
    • GPIO input mode with pull up & down state

      1:15
    • GPIO output mode with open drain state

      5:53
    • GPIO output mode with push pull state

      2:47
    • Optimizing IO power consumption

      3:11
    • GPIO programming structure

      2:45
    • Exploring GPIO PORT and pins of STM32F4xx Discovery board

      0:57
    • GPIO Mode register(used to set mode for a pin)

      3:07
    • GPIO port output type register(used to specify Output type)

      1:22
    • GPIO port output speed register (how quick transition)

      1:22
    • GPIO port pull up&pull down register(used to activate or deactivate pull ups)

      1:36
    • GPIO port input data register (used to read from pin)

      1:00
    • GPIO port output data register(used to write to pin)

      0:52
    • Enabling and disabling GPIO peripheral clock

      2:41
    • GPIO alternate function register(used to set alternate functionality for a pin )

      3:44
    • Installing KEIL MDK 5

      2:16
    • Installing Software Packs

      2:06
    • Creating Your First KEIL Project

      3:50
    • Debugging Project using KEIL µVison 4 IDE

      4:00
    • Understaning The Discovery Board

      1:52
    • Overview of the driver development task

      1:34
    • Driver API Requirements

      1:47
    • Creating & Organizing project files in KEIL

      2:15
    • Locating MCU specific Header File

      1:18
    • Exploring MCU specific Header File

      3:20
    • GPIO irq numbers

      4:36
    • Vector table and IRQ handlers

      2:01
    • Adding interrupt handling apis to our driver

      1:58
    • Implementing APIs to Configure and Enable External Interrupts

      4:48
    • Clearing external interrupt (otherwise NVIC will keep getting kicked )

      1:11
    • Test interrupt APIs we developed by using button

      3:14
    • Introduction to SPI

      0:59
    • Understanding SPI protocol

      7:29
    • SPI behind the scene

      2:25
    • Significance of Polarity and Phase

      4:59
    • Different SPI Modes with Timing diagram

      3:21
    • Uni Directional and Bi Directional SPI

      4:05
    • Exploring SPI functional block

      3:07
    • SPI Peripheral clock and Serial clock

      5:36
    • Exploring SPI Control Registers(CR)

      4:44
    • Exploring SPI Data Registers

      1:43
    • Exploring SPI Status Registers(SR)

      1:20
    • Overview

      1:33
    • Driver API Requirements (2)

      1:11
    • Exploring different SPI Peripherals and pin packs of the MCU

      1:02
    • SPI Register Bit Definitions Macros

      2:42
    • SPI Data structures

      6:01
    • Driver exposed APIs to handle SPI

      3:17
    • Writing init function and helper functions

      0:52
    • Configuring mode, phase and polarity

      1:26
    • Configuring datasize, baudrate and direction

      1:25
    • Configuring NSS

      3:51
    • Enabling Disabling SPI Peripheral

      1:00
    • Implementing TX API for master

      2:57
    • Implementing RX API for master

      1:47
    • Implementing TX API for slave

      2:33
    • Implementing RX API for slave

      0:56
    • How does SPI master TX RX data

      7:33
    • How does SPI slave TX RX data

      4:00
    • Understanding SPI TX RX IRQ numbers

      4:11
    • Setting up TXE RXNE interrupt

      1:09
    • Writing SPI irq handler

      2:22
    • Handling spi Tx interrupt

      2:45
    • Handling RX done interrupt in ISR

      1:03
    • Understanding the Requirements

      2:19
    • Understanding connection diagram

      1:25
    • Initialization

      0:49
    • Defining various IRQ handlers

      2:09
    • Master write Sequences

      3:40
    • Master Receive Sequences

      1:29
    • Initialization

      0:49
    • Slave Handling Read Write command from master

      3:48
    • Initial testing on hardware

      2:33
    • Capture SPI transcation on Logic analyzer

      3:30
    • Decoding SPI transcation Using logic analyzer

      3:43
    • Common problems in SPI and Debugging Tips

      6:14
    • Intro to I2C protocol

      5:35
    • I2C Hardware Setup

      2:16
    • Basics

      2:14
    • Address phase

      0:59
    • Start Condition

      1:03
    • ACK NACK

      1:08
    • Stop Condition

      0:37
    • Master Read Write Data Phase

      2:34
    • Repeated start

      4:20
    • Clock Stretching

      3:30
    • I2C in fast mode and standard mode

      1:44
    • I2C duty cycle

      3:59
    • 7bit addressing

      1:35
    • 10 bit addressing

      1:32
    • Exploring I2C functional block in the MCU

      2:40
    • I2C peripheral clock and serial line clock

      4:36
    • I2C IRQs and Interrupt Mapping

      5:28
    • Exploring I2C IRQ numbers

      2:07
    • Exploring I2C Control Registers(CR)

      5:16
    • Exploring I2C Own Address Registers(OAR)

      1:09
    • Exploring I2C Data Register(DR)

      1:47
    • Exploring I2C Status Registers(SR)

      4:49
    • Exploring I2C Clock Control Register(CCR)

      2:43
    • How I2C Master TX data

      4:57
    • How I2C Master RX da

      11:09
    • How I2C Slave TX da

      1:35
    • Overview

      1:27
    • Understanding the Requirements

      0:50
    • Exploring different I2C Peripherals and pins of the MCU

      1:27
    • I2C Register Bit Definitions Macros

      2:41
    • I2C Data structures

      6:04
    • I2C Driver Exposed APIs

      1:46
    • Init API and Helper Functions

      0:57
    • Code Implementation to Enable Disable I2C peripheral

      0:39
    • Configure clock stretching , own address , auto ACKing

      1:45
    • Configure I2C mode, addressing mode and duty cycle

      1:50
    • Code to Initialize I2C Serial Clock

      2:53
    • Code to Generate Start Stop condition

      1:16
    • Enabling Disabling Buff, Event, and Error interrupts

      1:10
    • Other Helper Functions

      1:30
    • Lecture 1 Implementing TX API for MASTER

      3:04
    • Implementing RX API for MASTER

      2:10
    • Implementing TX API for SLAVE

      1:20
    • Implementing RX API for SLAVE

      1:04
    • Implementing event interrupt handler

      1:48
    • Handling of TXE event for master

      1:08
    • Handling of TX BTF event for master

      1:27
    • Handling of slave Address Match Event

      1:11
    • Handling of STOP detection event Interrupt

      1:28
    • Handling of TXE event Interrupt

      2:05
    • Handling of TX BTF event Interrupt

      0:37
    • Handling of RXNE and BTF event interrupt

      1:27
    • Writing Error interrupt handler

      2:13
    • Handling of Different I2C Errors

      2:07
    • Understanding the Requirements

      2:25
    • Understanding connection diagram

      0:39
    • I2C Initialization

      8:38
    • Implementing I2C IRQ Handlers

      1:56
    • Implementing master write Sequences

      2:11
    • Implementing master read Sequences(cmd,length,data)

      1:33
    • Slave Handling Read Write Command from master

      2:06
    • Initial testing on hardware

      2:13
    • Decoding and Analyzing I2C transaction using logic analyzer

      7:15
    • Common Problems in I2C and Debugging Tips

      3:50
    • Intro UART vs USART

      3:14
    • Understanding UART pins

      2:34
    • UART frame formats

      1:45
    • Baud Rate

      2:18
    • Synchronization bits

      1:28
    • UART Parity

      3:53
    • Exploring UART functional block

      2:26
    • UART peripheral clock

      1:53
    • UART Transmitter

      3:17
    • Uart Receiver

      4:29
    • Exploring UART Interrupt Mapping

      3:25
    • Exploring UART Control Registers

      4:12
    • Exploring UART Data Registers

      1:50
    • Exploring UART Status Registers

      4:02
    • UART Baudrate Calculation

      6:04
    • Overview

      1:22
    • Understanding the Requirements

      1:02
    • Exploring Different UART Peripherals and pins of the MCU

      1:33
    • UART Register Bit Definitions Macros

      1:26
    • Data Structures used and Driver exposed APIs

      4:14
    • Writing init function and helper functions

      3:34
    • Configuring Word length, Stop Bits

      1:20
    • Configuring Baudrate, oversampling and Interrupts

      5:02
    • Writing TX function

      2:22
    • Writing RX Function

      2:00
    • Implementing UART IRQ Handler

      6:00
    • Handling TXE interrupt

      2:00
    • Handling of TX Complete Interrupt

      1:52
    • Handling RXNE Interrupt

      3:04
    • Understanding the Requirements

      1:48
    • Understanding connection diagram

      2:12
    • Exploring uart sniffer software for pc

      2:09
    • UART Initializations and Txing

      3:55
    • Receiving commands from PC

      1:43
    • Testing on hardware

      2:00
    • Introduction

      1:01
    • Implementing UART print apis

      4:16
    • Creating static library in KEIL and testing

      4:48
    • Exploring System , AHB, APB clocks of the MCU

      9:03
    • locking MCU by using External Crystal Oscillator(HSE)

      3:23
    • Measuring HSE,HSI, PLL and System Clock

      9:04
    • Clocking MCU by Internal PLL

      6:38

About This Class

b153ecb4

Do you Want to learn Microcontroller and its peripheral programming completely from scratch ?

Do you want to understand behind the scene working of most commonly used peripherals like GPIOs, SPI, I2C, USART,etc and build a s/w driver for it completely from scratch ?

Do you want to master the concepts such as Clocks, PLL, BUS,NVIC,IRQs,HCLK,PCLK with hands on programming ?

How about decoding and debugging protocols such as SPI, I2C, USART using USB logic analyser hardware and software ?

So, in short do you want to develop a sound knowledge in the domain of Microcontroller and its peripheral programming?

What you will learn ??

  • Understand Right ways of Handling and programming MCU Peripherals
  • Understand complete Driver Development steps right from scratch for GPIO,SPI,I2C and USART.
  • Explore MCU data sheets, Reference manuals, start-up Codes to get things done
  • Explore MCU data sheets, Reference manuals, start-up Codes to get things done
  • Demystifying behind the scene working details of SPI,I2C,GPIOs,USART etc.
  • Understand right ways of enabling/configuring peripheral clocks/serial clocks/baud rates of various serial protocols
  • Learn about different MCU clocks like HCLK, PCLK, PLL,etc
  • Learn about Quick ways of debugging peripheral issues with case studies
  • Learn Right ways of handling/configuring Interrupts for various peripherals
  • Learn about Configuration/status/Control registers of various Peripherals
  • Learn about Configuration/status/Control registers of various Peripherals
  • Learn about Configuration/status/Control registers of various Peripherals
  • Learn to capture/decode/analyze traces of serial protocols on Logic analyzer 

Requirements

Students don't need any experience in Microcontroller programming. This course will cover everything you need to get started with Microcontroller, Important peripherals, Programming with peripherals, Reading data sheets and reference manuals and finally developing your own peripheral driver by scratch.

About the Course :

You're here because you want to learn about Microcontroller and its programming, right? 

Believe me this is the perfect place to start. Because, unlike other courses, this course walks you right from the fundamentals. This complete course is designed for beginners like you who have no idea, fundamentally how Microcontrollers and its peripherals like GPIOs, SPI, I2C, USART,CLOCKS,PLLs,BUS interface work.

Why you should take this course?

Whenever a beginner in the domain of embedded system encounters terminologies like GPIOs,SPI,I2C,USART,CLK,PLL,AHB,APB,NVIC,IRQs,ISRs they don't feel comfortable and carry the notion that these are advanced concepts and difficult to learn. In this course i take you through step by step procedure to understand most of the important details of the MCU and how to code some of the peripherals entirely from scratch along with debugging sessions

At the end of this course, you will really feel confident in handling any MCU you have at your hand and you will learn lots of practical details about programming the peripherals. Remember that this is a generic course and not tied to one particular MCU. The knowledge you gain from this course can be leveraged to any MCU you have

Master Behind the Scene working!

I created this course because I believe your time is precious, and you shouldn't have to hunt around to get a practical foundation In Embedded System Programming. In this course, you are going to learn writing your own peripheral driver for most of the commonly used peripherals such as GPIOs, I2C, SPI, USART, etc. and interesting thing is that you are going to learn everything from scratch.

No 3rd party libraries!

No blind coding!

Write your own Driver APIs by dealing with the Peripheral Registers of the MCU!

Hardware used in this course 

In this course, STM32F407VG Discovery board is used. But students can use any development board they have provided it is based on ARM Cortex M based processor. 

Also if a student wants to buy any low cost development board to start his/her embedded programming journey, then you may consider buying the STM32 Nucleo boards.

17

Students

--

Projects

0

Reviews (0)

Kiran Nayak

Embedded/Firmware Engineering

Courses designed by the instructor who has 10+ years of industry experience and worked with some of the leading chip manufacturing companies in the domain of Firmware and Embedded Engineering, Embedded Software Development, Real time systems, etc. BLE SDK development, Low power wireless protocol stack development, etc.

Our YT channel : https://goo.gl/6JWftD

Facebook : www.facebook.com/fastbiteba

See full profile