Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Embedded systems/ assembly code question thanks!! Fill in the immediate operands with hexadecimal numbers that initialize Port B. Bits 0, 1, and 2 are input.

Embedded systems/ assembly code question thanks!! image text in transcribed
Fill in the immediate operands with hexadecimal numbers that initialize Port B. Bits 0, 1, and 2 are input. Bits 3 and 5 are output. PortB_Init LDR R1, =SYSCTL_RCGCGPIO_R LDR R0, [R1] ORR R0, R0, ------------------------------------------- STR R0, [R1] NOP NOP LDR R1, =GPIO_PORTB_DIR_R LDR R0, [R1]/-- ORR R0, R0, #-----------------------------------------------/BIC R0, R0, #-----------------------------------------------------\ STR R0, [R1] \---- LDR R1, =GPIO_PORTB_AFSEL_R LDR R0, [R1] BIC R0, R0, #-------------------------- STR R0, [R1] LDR R1, =GPIO_PORTB_DEN_R LDR R0, [R1] ORR R0, R0, #------------------------- STR R0, [R1] BX LR Write an assembly language main program that first calls the initialization and then performs steps 2, 3, and 4 over and over infinitely. execute PortB_Init defined in Question 1.1. read the inputs; if all three inputs are equal to each other (inputs are 000 or 111) then toggle output bit 3, otherwise (inputs are 001, 010, 011, 100, 101, or 110) toggle output bit 5. Write friendly code. Comments are allowed but not needed

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

Next Generation Databases NoSQLand Big Data

Authors: Guy Harrison

1st Edition

1484213300, 978-1484213308

More Books

Students also viewed these Databases questions

Question

Why is the System Build Process an iterative process?

Answered: 1 week ago