20COA202 Embedded Systems Programming 26/04/2021 12:01
20COA202 Embedded Systems Programming
Coursework Questions and Answers Iain Phillips
Semester 2 2020-2021
1 Introduction
Here I will keep a set of questions and answers about the coursework. Please refer to these before emailing me.
1.1 Questions on the spec
1. doestheArduinoneedtostoreavariableforthelightslevelorthetimers on/off or does it just need to output it in terms of a string to the serial monitor. e.g. when I navigate to bedroom 1 light can it just have a default value of 0 which I can then change and send off to the serial monitor or does it need to remember what I have previously entered and start at that?
Yes, it has to remember. The operation to send to the Serial Monitor could be long after the operation to set the level/value.
2. theoperationtosendtotheserialbusoutputseverythingforeveryobjectin the house, all lights and heaters and lamps and water controllers from every room or is it just of the last thing entered?
Yes everything all in one batch.
file:///Users/bowensun/Desktop/%20Embedded%20Systems%20Programming.webarchive ⻚码:1/3
20COA202 Embedded Systems Programming 26/04/2021 12:01
3. Onthe20COA202courseworkdoweneedtoprogramtheArduinosowe can use the buttons to navigate through the menu or navigate through it using the serial monitor? I saw that you mentioned it should be communicated over the serial port but I’m not sure if this refers to the buttons of the serial monitor input.
Navigation through the menus, entering levels and on/off etc must be done with the buttons. The Serial Monitor is for dumping the data structure and writing BASIC/ENHANCED and the other descriptors to be read externally.
4. AlsoIhavethoughtaboutusingclassesandobjectsasawayofstoringthe house,rooms,etc but I’m not sure if this is appropriate, can you give some input on this?
You can use whatever language features you like providing that: 1. ThecodecompilesonastandardArduinoIDE
2. Youonlyusethelibrarieslistedinthespec-specifiedby.hfiles
5. Whenwearedoingtheextensiontaskofhavingasoftmenu.Soweneedthe ability to add more types of object or is only being able to add light heater lamp and water controller okay?
The only types expected are Light, Heat and Water.
6. Doineedtosupportlampsineveryroom?
Yes. So you could have Lamp/Desk/1 and Lamp/Bed/2 and Lamp/Bed/Left etc.
7. Doesthewatercontrollerhavealevelsetting? You can assume no, just on or off.
8. IstheoutputfromtheextensionQUERY(Qsent)thesameasthemenu option?
Yes – this should be an easy piece of code.
9. TheSOFTmenuextensionseemsverycomplicated.Didyoumeanittobe like that?
file:///Users/bowensun/Desktop/%20Embedded%20Systems%20Programming.webarchive ⻚码:2/3
20COA202 Embedded Systems Programming 26/04/2021 12:01
Yes, this is the hard bit that only the best of you might be able to complete. It may be very difficult or impossible in the availbale resources. If you decide this to be the case, then I will be interested in your approach and techniques used more than total success.
10. Isthereanyparticularwayinwhichthemenusshouldbenavigated?
No there is not. Please implement something sensible and efficient. Reducing the number of unnecessary button presses while maintaining usability is something to aim for.
11. ExactlywhatdoIneedtosendovertheSerialMonitor?WhatcanIdisplay on the LCD screen?
1. Theideaoftheprogramisyoumaintainasetofdataaboutthehouse.
2. Themenusallowyoutoupdatethisdata-thesearedisplayedintheLCD
screen.
3. Thereisa“senddatatoserialmonitor”menuoptionwhichoutputsthe
whole data structure properly formatted at once to the Serial monitor.
4. TheonlytimedatashouldbesenttotheSerialMonitor,inthebasic
specification, is via the “send data to serial monitor” menu item.
file:///Users/bowensun/Desktop/%20Embedded%20Systems%20Programming.webarchive ⻚码:3/3