Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Format and speed from question one: Format: 1 start bit, 8 data bits, 1 odd parity bit, 1 stop bit. Speed: baudrate of 9,600, transmitting

image text in transcribed

Format and speed from question one:

Format: 1 start bit, 8 data bits, 1 odd parity bit, 1 stop bit.

Speed: baudrate of 9,600, transmitting character 'W'

data rate = baud rate * (data bits / frame bits)

Complete the function below for serial send (char my txt) to implement the UART protocol in software. Implement the format and speed specified in Question 1. Assume that Port B was already initialized and configured by the main program so that pin 3 is an output. Partial code for the function is provided. Finish the remaining code. Assume you have the following function: wait_us (float WaitTime) waits for WaitTime microseconds before continuing // Send my_txt out of Port B pin 3 using the UART format // without using the UART hardware void serial_send (char my_txt) ;IICalculate this constant float BitTime = 7YOUR VARIABLES HERE // Send Start bit over PB3 GPIO PORTB DATA R = GPIO PORTB DATA R & 0b1111 0111; wait us (BitTime)i 7YOUR CODE HERE Complete the function below for serial send (char my txt) to implement the UART protocol in software. Implement the format and speed specified in Question 1. Assume that Port B was already initialized and configured by the main program so that pin 3 is an output. Partial code for the function is provided. Finish the remaining code. Assume you have the following function: wait_us (float WaitTime) waits for WaitTime microseconds before continuing // Send my_txt out of Port B pin 3 using the UART format // without using the UART hardware void serial_send (char my_txt) ;IICalculate this constant float BitTime = 7YOUR VARIABLES HERE // Send Start bit over PB3 GPIO PORTB DATA R = GPIO PORTB DATA R & 0b1111 0111; wait us (BitTime)i 7YOUR CODE HERE

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

Students also viewed these Databases questions