Microcontroller Lab Pulse Width Modulation Spring 2019 with LED Test Mode

ece 3567 microcontroller lab ece 3567 n.w
1 / 12
Embed
Share

"Explore the ECE 3567 Microcontroller Lab focusing on Pulse Width Modulation and LED Test Mode for Spring 2019. Download project files, compile, program, and add pulse width definitions for LED colors like red, orange, yellow, green, and blue."

  • microcontroller lab
  • LED test mode
  • pulse width modulation
  • ECE 3567
  • Spring 2019

Uploaded on | 0 Views


Download Presentation

Please find below an Image/Link to download the presentation.

The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author. If you encounter any issues during the download, it is possible that the publisher has removed the file from their server.

You are allowed to download the files provided on this website for personal or commercial use, subject to the condition that they are used lawfully. All files are the property of their respective owners.

The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author.

E N D

Presentation Transcript


  1. ECE 3567 Microcontroller Lab ECE 3567 Microcontroller Lab Lab #3 Pulse Width Modulation and the LED Test Mode Spring 2019 Dr. Gregg Chapman 1

  2. ECE 3567 Microcontroller Lab ECE 3567 Microcontroller Lab This week, you are given MOST of the code for LED Test Mode. 2

  3. Lab 3 Main() Lab 3 Main() 3

  4. ECE 3567 Microcontroller Lab ECE 3567 Microcontroller Lab Download and install the project from the ECE 3567 Lab 3 website. 4

  5. Lab 3 The LED Test Mode First of THREE Modes: 1. LED Test Mode 2. Temperature Measurement Mode 3. RC Voltage Feedback Mode 5

  6. Lab 3 Compile and Program Lab Add the following Commands to parse_Command() LT Activate LED Test Mode LR = Red LED LO = Orange LY Yellow LG Green LB Blue LP Purple LD LED Test Mode Disable 6

  7. Lab 3 Compile and Program Lab Add the following Pulse Width Definitions in update_RGB() NOTE: This is in RGB_LED.c if(LED_Test == TRUE) { if(LED_Color == Red) // Red. Includes Flash { duty_cycle_red = 0x070; duty_cycle_green = 0x000; duty_cycle_blue = 0x000; 7

  8. Lab 3 Add the following Pulse Width Definitions in update_RGB() NOTE: This is in RGB_LED.c } else if(LED_Color == Orange) // Orange { duty_cycle_red = 0x0E4; //FF duty_cycle_green = 0x014; // 30 duty_cycle_blue = 0x000; } 8

  9. Lab 3 Add the following Pulse Width Definitions in update_RGB() NOTE: This is in RGB_LED.c } else if(LED_Color == Yellow) // Yellow { duty_cycle_red = 0x0E4; //FF duty_cycle_green = 0x08B; // D7 duty_cycle_blue = 0x000; } 9

  10. Lab 3 Add the following Pulse Width Definitions in update_RGB() NOTE: This is in RGB_LED.c else if(LED_Color == Green) // Green { duty_cycle_red = 0x000; duty_cycle_green = 0x04A; duty_cycle_blue = 0x000; } else if(LED_Color == Blue) // Blue { duty_cycle_red = 0x003; duty_cycle_green = 0x003; duty_cycle_blue = 0x07A; } 10

  11. Lab 3 Add the following Pulse Width Definitions in update_RGB() NOTE: This is in RGB_LED.c else if(LED_Color == Green) // Green { duty_cycle_red = 0x000; duty_cycle_green = 0x04A; duty_cycle_blue = 0x000; } else if(LED_Color == Blue) // Blue { duty_cycle_red = 0x003; duty_cycle_green = 0x003; duty_cycle_blue = 0x07A; } 11

  12. Lab 3 Checkpoints 1. Green LED illuminates when the UART is Connected 2. LT is written to the LCD when the command is sent 3. All 6 colors appear for the Color Commands in LT Mode. 4. LD disables the LED 5. LE Enables the LED 12

More Related Content