{"base":{"id":"cs11-09","subject":"Computer systems","title":"Automated control systems","scene":"mix","steps":[{"use":"cs11","mode":"control","eyebrow":"A control loop","title":"Sensor → processor → actuator","body":"A thermostat measures temperature, compares it with a set point and switches a heater. Start it and change the set point.","controls":[{"id":"set","label":"Set point","min":16,"max":26,"step":1,"value":21,"unit":"°C"}],"actions":[{"id":"run","label":"Start"}]},{"use":"code9","mode":"tempalarm","eyebrow":"Testing a control program","title":"Vary the input","body":"Test the program with readings below, at and above the threshold.","controls":[{"id":"temp","label":"Temperature","min":10,"max":40,"step":1,"value":22,"unit":"°C"}]},{"use":"code9","mode":"light","eyebrow":"Automatic lights","title":"Light level decides","body":"A light sensor switches street lights on when it gets dark.","controls":[{"id":"light","label":"Light level","min":0,"max":100,"step":5,"value":30}]},{"use":"cs11","mode":"quiz","look":"control","eyebrow":"Check yourself","title":"Parts","body":"In an automatic greenhouse window, what is the motor that opens the window?","question":"Choose one.","options":["A sensor","An actuator","A microprocessor"],"answer":1,"right":"Correct.","wrong":"Not quite."}],"more":[{"type":"cards","id":"worked","eyebrow":"Worked examples","title":"Step by step","items":[{"tag":"Pseudocode","title":"Thermostat","body":"REPEAT\n  READ temp\n  IF temp < setPoint THEN heater ← ON\n  ELSE heater ← OFF\nUNTIL FALSE","code":true},{"tag":"Greenhouse","title":"Two sensors","body":"IF temp > 28 THEN open window\nIF moisture < 30 THEN water ON","code":true},{"tag":"Data conversion","title":"ADC","body":"analogue sensor signal → ADC → digital value the processor can use","code":true},{"tag":"Safety","title":"Car","body":"airbag: accelerometer detects sudden stop → processor → inflator in milliseconds","code":true}]},{"type":"cards","id":"mistakes","eyebrow":"Common mistakes","title":"Watch out for these","items":[{"tag":"Mistake","title":"Calling the processor a sensor","body":"Sensors measure; processors decide; actuators act."},{"tag":"Mistake","title":"Forgetting the loop","body":"Control systems check continuously."},{"tag":"Mistake","title":"Forgetting analogue-to-digital conversion","body":"Most sensors give analogue signals that must be converted."}]},{"type":"cards","id":"deeper","eyebrow":"Go deeper","title":"More than the lesson","items":[{"tag":"Industry","title":"Factories","body":"Automated production lines use thousands of sensors and actuators controlled by programmable logic controllers (PLCs)."},{"tag":"Home","title":"Smart homes","body":"Smart thermostats learn your routine and adjust heating to save energy."}]},{"type":"cards","id":"challenge","eyebrow":"Challenge yourself","title":"Stretch your brain","intro":"Try each one on paper before opening the card.","items":[{"tag":"Challenge","title":"Design","body":"Design a control system for a car park barrier.\n\nAnswer: sensor (ticket reader or weight pad) → processor checks payment → actuator (motor) lifts barrier; loop continuously."},{"tag":"Challenge","title":"Explain","body":"Why does a thermostat usually switch at slightly different temperatures for on and off?\n\nAnswer: to avoid rapid on/off switching (hysteresis)."}]},{"type":"activities","id":"try","eyebrow":"Try it at home","title":"Try it yourself","items":[{"title":"Spot control systems","time":"15 minutes","need":["Your home and street"],"steps":["List 5 automatic systems.","Name the sensor, processor and actuator in each."],"why":"Control systems are everywhere.","safety":"Observe only."}]},{"type":"quiz","id":"quiz","eyebrow":"Quiz","title":"Eight more questions","questions":[{"question":"A sensor…","options":["moves things","stores files","measures a physical quantity"],"answer":2,"right":"Correct.","wrong":"Not quite."},{"question":"An actuator…","options":["produces movement or action","measures temperature","compares values"],"answer":0,"right":"Correct.","wrong":"Not quite."},{"question":"The processor…","options":["measures light","compares readings and decides","opens windows"],"answer":1,"right":"Correct.","wrong":"Not quite."},{"question":"An ADC converts…","options":["digital to analogue","text to numbers","analogue to digital"],"answer":2,"right":"Correct.","wrong":"Not quite."},{"question":"A thermostat uses a…","options":["temperature sensor","light sensor","pressure pad"],"answer":0,"right":"Correct.","wrong":"Not quite."},{"question":"Feedback means…","options":["user comments","the output affects the next input","printing"],"answer":1,"right":"Correct.","wrong":"Not quite."},{"question":"Which is an actuator?","options":["Thermistor","Microphone","Motor"],"answer":2,"right":"Correct.","wrong":"Not quite."},{"question":"Control systems run…","options":["in a continuous loop","once only","only at night"],"answer":0,"right":"Correct.","wrong":"Not quite."}]},{"type":"checklist","id":"check","eyebrow":"Self-check","title":"I can…","items":["describe sensors, processors and actuators","explain a control loop with feedback","write pseudocode for a control system","explain analogue-to-digital conversion","give examples of control systems"]},{"type":"keywords","id":"words","eyebrow":"Key words","title":"Words to know","items":[{"word":"Sensor","meaning":"Measures a physical quantity."},{"word":"Actuator","meaning":"A device that causes movement or action."},{"word":"Microprocessor","meaning":"Processes data and makes decisions."},{"word":"Feedback","meaning":"Output affecting future input."},{"word":"ADC","meaning":"Analogue-to-digital converter."}]},{"type":"sources","id":"sources","title":"Sources","items":["Raspberry Pi Foundation: physical computing","BBC Bitesize, GCSE Computer Science: embedded systems","International Society of Automation: what is automation?","US Department of Energy: programmable thermostats"]}]},"overlay":null}