Question: Write a sub procedure named Calculate _ Received _ Power that calculates the power ( in watts ) of a radio frequency ( RF )

Write a sub procedure named Calculate_Received_Power that calculates the power (in watts) of a radio frequency (RF) signal received by an antenna in an indoor wireless communications system. In any type of wireless communications system, the power of a RF signal disperses with distance. Therefore, a receiving antenna with a fixed area will capture less RF signal power the farther it is from the transmitting antenna. The RF signal power received by a receiving antenna in an indoor wireless communications system is calculated using the formula:
Pr=PtGrGt2(4d)2; where =cf
The Excel VBA code in sub procedure Calculate_Received_Power must implement the exact algorithm depicted by the flowchart included on page 4 of this document. For the purposes of this problem, assume that the user will always provide valid input values. In other words, you are not responsible for validating user input via Excel VBA code.
a) The following inputs must be entered by the user into the spreadsheet "Prob1".
Pt= Transmitted signal power (in watts)
d= Distance between transmitting and receiving antennas (in meters)
f= Carrier frequency (in hertz)
Gt= Gain of the transmitting antenna (dimensiontess)
Gr= Gain of the receiving antenna (dimensionless)
The values for the constants c(i.e., speed of light) and should be considered as internal inputs. Therefore, the user should not be asked to provide them. Your Excel VBA code must then assign the values of all inputs to variables of the appropriate type. These variables will then be used to calculate the power (in watts) of a RF signal received by an antenna in an indoor wireless communications system:
b) The result for Pr(i.e., received power) should be reported using engineering notation (i.e.,0.00E+00) in its corresponding spreadsheet cell. This requirement must be implemented via Excel VBA code (Hint: Research the function Format and/or the NumberFormat property of the Range object).
c) Your sub procedure should end by selecting the cell where the user enters the value of Pt.
Assign the sub procedure Calculate_Received_Power to a rectangular shape button. The caption of the rectangular shape button should read "Calculate Received Power".
2. Write a sub procedure named Clear_Values that will clear all the input values provided by the user, as well as both the label and value for the output, Pr. This sub procedure should end by selecting the cell where the user enters the value of Pt. Assign the sub procedure clear_values to a rectangular shape button. the caption of the rectangular shape should read clear.
Please provide a photo of the code working on your sude when submitting please. Thank you!
Write a sub procedure named Calculate _ Received

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!