Answered step by step
Verified Expert Solution
Question
1 Approved Answer
2 . 4 Write codes in the void setupl to initialise the following: ( a ) Initialise the Serial port to operate at 9 6
Write codes in the void setupl to initialise the following:
a Initialise the Serial port to operate at ;
b Digital pin D D and D;
c Wait for SW to be press; and
d Send characters followed by via serial port to the Bluetooth module.
For c and d you are to call the respective functions in and
marks
Write codes in the forever loop assisted by the following comments: You are to declare any variables you used.
void loop
if the reading Erom PIR motion ia HIGH
Sound the pizea buzzer
Send a message To Bluetooth
marks
a Write codes to set bit and bit of the bit variable swVal to with the rest of the bits of swdal,remains unchanged
b Write codes to clear bits and of the bit variable numV to with the rest of the bits of pumbal. remains unchanged
a If the initial value in the variable num is what will be the new value in the variable num after executing the following instruction? Show your working as necessary
num num ;
b Write CStatements to print the value of num on Serial Monitor as shown in Figure
Figure
Where NNNNNNNNN is the value of num in binary aner executing
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started