200 likes | 356 Views
Blogics!. It’s a logic circuit simulator aimed at beginners. It introduces simple concepts in the design of interactive physical computing systems such as sensors, actuators, processing and their relationship to the environment. Logic Gates. Basic operations of digital systems.
E N D
Blogics! • It’s a logic circuit simulator aimed at beginners. • It introduces simple concepts in the design of interactive physical computing systems such as sensors, actuators, processing and their relationship to the environment.
Logic Gates • Basic operations of digital systems. • Each logic gate has a number of inputs and produce an output accordingly. • Each input is a binary value (1 or 0) that correspond to truth values (true or false)
Example: AND gate • I will go to sleep if it is dark and I am tired. = ? Go to sleep + = ? + + = ? Stay awake + = ?
Example: AND gate • I will go to sleep if it is dark and I am tired. Go to sleep + ‘Go to sleep’ is true only when ‘dark’ and ‘tired’ are also true. + + Stay awake +
Example: OR gate • I will go to sleep if it is dark or I am tired. = ? Go to sleep + = ? + + = ? Stay awake + = ?
Example: OR gate • I will go to sleep if it is dark or I am tired. Go to sleep + ‘Go to sleep’ is true either when ‘dark’ or ‘tired’ are also true. + + Stay awake +
Logic models behaviour • By specifying the system’s behaviour with logic gates we can determine its outputs according to each combination of inputs.
Interactive systems ENVIRONMENT Interactive System Outputs Inputs HUMAN
Interactive systems ENVIRONMENT Sensors Processing Actuators Outputs Inputs HUMAN
Sensors • A sensor converts a physical quantity into an electrical signal. • There is an enormous variety of sensors available commercially, often for very low prices: • Sound • Chemicals • Electricity • Temperature • Proximity • Position • Humidity • And so on…
Sensors • The signal that a sensor emits varies according to its operating characteristics and the measured physical quantity captured from the environment or from human action. • Sensors can be digital or analogue.
Sensors in Blogics! Button Switch Thermometer Light Sensor Humidity Sensor Presence Sensor
Sensors in Blogics! • Each sensor measures a different physical quantity in the environment. • Light Sensor: Day/Night • Thermometer: Cold/Hot • Humidity: Wet/Dry • Presence: Someone/No one • Button/Switch: Human Action/No human action
Sensors in Blogics! • Sensors in Blogics! are binary, i.e. they are either on or off according to the environment variable they measure. • We simulate changes in the environment by connecting a different environment block to the sensor High temperature Output: 1 Low temperature Output: 0
Actuators • The other end of an interactive system is the actuation side. • Actuators convert an electric signal into mechanical motion. • To simplify the jargon, we use the term to denote any component that converts an electric signal into any kind of feedback to the user or the environment.
Actuators in Blogics! • LED - light • Fan - temperature • Buzzer - sound • Vibration motor - haptic
Processing • The data collected by the sensors is processed by the logic circuit.
Processing • We combine logic gates to create more complex logic statements. • Example: Turn on a fan if it is dark and hot We add the NOT gate, because the light sensor outputs 1 when it is bright
Summary • We can use logic to specify an interactive system’s behaviour. • When we design interactive systems, we need to think about: • what inputs it takes • what sensors do we need to obtain this input from the user or the environment • what kind of output we want to give • what actuators we need to use to provide this feedback to the user or the environment • how to process the inputs to generate the desired outputs