Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Do flowchart and pseducode 0x04 define LEDBLUE #define LEDGREEN #define LED YELLO #define LEDSKYBLUE #define LED WHITE #define LED PINK 0x04 // blueB 0x08 //

image text in transcribedDo flowchart and pseducode
0x04 define LEDBLUE #define LEDGREEN #define LED YELLO #define LEDSKYBLUE #define LED WHITE #define LED PINK 0x04 // blueB 0x08 // greenG0x08 0xoA 1/ yellow RG-OxOA 0x0C // sky blue -GB oxoC 0xOE // whiteRGB0x0E 0x06 // pinkR-B - - - 0x06 unsigned long sW1, SW2:// input from PF4, PFO unsigned long Out: // outputs to PE3, PE2, PF1 (multicolor LED) void PortF Init (void) : void Delay (void): void EnableInterrupts (void) ; main (void)( TExaS Init initializes the real board grader TExaS Init (SW PIN PF40, LED PIN PF321) // Call initialization of port PF4, PF3, PE2, PFI, PFO PortE InitO /f The grader uses interrupts EnableInterrupts 0 while (1) { int SW1GPIO PORTF DATA R&Ox102 SW2 GPIO PORTE DATA RCOx01: read PF4 into SWI // read PFO intS2 f both pressed GPIO PORTF DATA R LED BLUE: 1 elset LED is blue / bust swI pressed .nn: GPIO PORTF DATA R LED RED /7 LED is red elset if ((SW1)&& (SW2)) ( // just SW2 pressed GPIO PORTE DATA RLED GREEN: /LED is green 9 Jelse( // neither switch // LED is off GPO PORTF DATA R LEDOFF; - 6 PE4 and PFO are input SW1 and SW2 respectively PES, PE2, PEL are outputs to the LED :// These five pins are connected to hardware on the Launchpad 0x04 define LEDBLUE #define LEDGREEN #define LED YELLO #define LEDSKYBLUE #define LED WHITE #define LED PINK 0x04 // blueB 0x08 // greenG0x08 0xoA 1/ yellow RG-OxOA 0x0C // sky blue -GB oxoC 0xOE // whiteRGB0x0E 0x06 // pinkR-B - - - 0x06 unsigned long sW1, SW2:// input from PF4, PFO unsigned long Out: // outputs to PE3, PE2, PF1 (multicolor LED) void PortF Init (void) : void Delay (void): void EnableInterrupts (void) ; main (void)( TExaS Init initializes the real board grader TExaS Init (SW PIN PF40, LED PIN PF321) // Call initialization of port PF4, PF3, PE2, PFI, PFO PortE InitO /f The grader uses interrupts EnableInterrupts 0 while (1) { int SW1GPIO PORTF DATA R&Ox102 SW2 GPIO PORTE DATA RCOx01: read PF4 into SWI // read PFO intS2 f both pressed GPIO PORTF DATA R LED BLUE: 1 elset LED is blue / bust swI pressed .nn: GPIO PORTF DATA R LED RED /7 LED is red elset if ((SW1)&& (SW2)) ( // just SW2 pressed GPIO PORTE DATA RLED GREEN: /LED is green 9 Jelse( // neither switch // LED is off GPO PORTF DATA R LEDOFF; - 6 PE4 and PFO are input SW1 and SW2 respectively PES, PE2, PEL are outputs to the LED :// These five pins are connected to hardware on the Launchpad

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Oracle Database Administration The Essential Reference

Authors: Brian Laskey, David Kreines

1st Edition

1565925165, 978-1565925168

More Books

Students also viewed these Databases questions

Question

Describe your ideal working day.

Answered: 1 week ago