Questions 2 cover CLO2 5 Marks a) consider the looping statement for (int i = 0; i < 10:1 +1) Assuming the body of the loop does not not break the loop or change i, how many times would the body of the loop be executed. Ans) b) On the Arduino, how would you configure pin 6 on the output headers to be an output and how would you set it high. For this question, use the Arduino commands. Ans) Questions 3 cover CLO3 5 Marks a) Write the Arduino C code to setup and then read the analog value on pin A3. Assume the pin is initially in an unknown configuration. Ans) Questions 4 cover CLO4 a) According to the distance, make an application that turn-on 4 LED in sequence If the distance; a. If it is between 00-15cm, 4 LED, b. If it is between 15-30cm, 3 LED, c. If it is between 30-40cm, 2 LED, D. If it is between 40-60cm, 1 LED, Ans) Show transcribed image text Questions 2 cover CLO2 5 Marks a) consider the looping statement for (int i = 0; i
Expert Answer
Answer to Questions 2 cover CLO2 5 Marks a) consider the looping statement for (int i = 0; i < 10:1 +1) Assuming the body of the l...