ExamBank Scot · N5 Engineering Science question bank · All N5 Engineering Science questions

N5 Engineering Science 2022 Question 9

13 marks · Flowcharts and programs

Complete the flowchart for the sequence, with reference to the data booklet and input/output connections. Include all pin numbers and delay units in your flowchart. start A program used in a different control system is listed below. line program 1 main: let count = 0 2 label_1: switch on 4 3 4 5 6 7 8 9 10 switch on 5 pause 600 switch off 4 switch off 5 pause 600 let count = count + 1 if count = 20 then label_2 goto main 11 label_2: if Input0 is on then label_3 12 goto label_2 13 label_3: switch on 7 14 15 16 pause 3000 switch off 7 goto main Describe the function of line 16 in the program. Lines 2 to 9 should repeat twenty times before moving on to line 11. During testing an electronic engineer found that this did not happen. Explain why lines 2 to 9 did not repeat twenty times before moving on to line 11. In a swimming competition, a system is used to automatically measure a competitor’s time. The system is operated by a microcontroller. The input and output connections to the microcontroller are shown in the table below. Input connections Pin Output connections 7 buzzer 6 timer lane switch 1 master switch 0 The system operates using the following sequence. • A master switch is pressed • A buzzer then sounds on and then off three times over 1.5 seconds • The timer then starts • When a lane switch is pressed the timer stops • The system will then reset ready to be used again

Marking scheme

Pin 0 on ? with Y/N, loop and arrow in correct position – 1 mark. Pin 7 on and off in correct position – 1 mark. Both delays in correct position (ignore incorrect values and unit) - 1 mark. Total delay time(s) with unit = 0.5 s per cycle - 1 mark. X3 decision with Y/N in correct position – 1 mark. Loop and arrow (x3 decision) back to before pin 7 on – 1 mark. Pin 6 on and off in correct position – 1 mark. Pin 1 on? with Y/N, loop and arrow in correct position – 1 mark. Accept decision feedback loop to before pin 6 on. Continuous loop to start with arrow – 1 mark. All marked symbols correct – 1 mark. Ignore any additional steps. accept on/off repeated 3 times max 2 marks. To go back to line 1/main/restart the program To create a continuous loop. Descriptive response. 1 mark for looping program back to start. Accept reset the program. Do not accept go to main on its own. The program loops back to line 1/main/“let count = 0”/wrong line ...therefore it will reset the count/ the count will not pass 1/count will not reach 20. 1 mark for program looping back to the line 1 (cause). 1 mark for resetting the count (effect).

Previous question: N5 Engineering Science 2022 Question 8

Next question: N5 Engineering Science 2022 Question 10