Monday, 10 November 2014

F452 - Development.

Writing bad code is easy; writing good code is difficult; writing really good code is REALLY difficult.


What’s a bug?



A bug is where the software (or system) does something unexpected or undesirable.
Not all bugs are accidents though.


Types of bugs:



  • Functional: (car will not start)
  • Non functional: (the car travels extremely slowly)
  • Reproducible:
  • Non-reproducible:


[All software has bugs.]


How to write good code:

  • Easy to read (Notation).
  • Robust/ functional.
  • Proceeded by planning.
  • Comments.
  • Well formatted, readable code.
  • Error handling.
  • Documentation.
  • “Brain sized” chunks.
  • Well tested code.
  • Understandable by others.


What do you need to design software?



  • Brain.
  • Pen and paper.


{NO computers, mood room or IDE.}


You CAN (not) do everything.



  • Use teams of people to split up work.
  • Use software tools to make the interaction easier.


Humans suck at doing stuff; computers suck at designing.


Tools for software development:



  • API’s 
[Application Programming Interface](Library of code for use).
  • Source control 
(controls additions to the source code, updates everyone's)(versioning; checking in-&-out; branching).
  • Build tools 
[compiler] (brings the code together for execution; turns a high level language into machine code)
  • Artifact control 
(keeps a compiled copy).
  • Documentation.
  • Bug tracking software.
(Prioritises issues and assigns tasks to correct the code; links with versioning)

  • Automated testing.
  • Continuous integration servers/ automated build tools 
(keeps track of everyone's addition and brings it together)
  • Automated deployment 
(,e.g: ios distribution).


Software development lifecycles:



Waterfall (traditional):
  • Requirements.
  • Design.
  • Code.
  • Test.
  • Deploy.
  • Support.
  • End of life.


Agile (the upstart):
Rough requirement.
Build something that works.
(but that is fully functional).
Refine the requirements.
Build something that works a bit better.


The computer does the testing.
“If the test fails give me a ring; if the test works don’t bother me.”


!xiety (Bangxiety) meter:



  • Designed to tell the user when the battery is going to run out.
  • Every system has inputs and outputs, even this piece of tech.


Some of the design challenges:



  • Reading the wheel speed.
  • Recording how much power the batter has used.
  • Key presses.

No comments:

Post a Comment