Title: Software utilization of a sensor signal
1Software utilization of a sensor signal
Sensors Technology MED4
Lecturer Smilen Dimitrov
2Introduction
- The model that we introduced for ST
3Introduction
- The part where we focus in this lecture
4Data acquisition (DAQ) systems
- Main purpose measuring and digitizing sensor
signals. - Basic structure single channel DAQ
- Basic parameters sampling resolution and
sampling period - Repeat using applet
- Teleo
5Data acquisition (DAQ) systems
- Teleo is a multichannel DAQ system a DAQ board
- 4 inputs performance issues
6Computer architecture and program execution
- The hardware nature demands translation of the
high level program
7Computer architecture and program execution
- The hardware nature demands translation of the
high level program
8Computer architecture and program execution
- Once on the machine level, the program is
executed sequentially, synced by a clock signal
9Computer architecture and program execution
- Once on the machine level, the program is
executed sequentially, synced by a clock signal
10Computer architecture and program execution
- Execution of a machine instruction requires
complex synchronization between the parts of the
computer clock several stages of execution
11Computer architecture and program execution
- Fetch execute cycle
- Use PC to supply adress,
- Get instruction from memory,
- read registers,
- Use instruction to decide what to do,
- Solve instruction, write registers,
- Update PC.
12Computer architecture and program execution
- Fetch execute cycle and timing
13Computer architecture and program execution
- We implement branching by manipulating the
program counter PC from sequential execution
to loops - Although we should in general avoid fixed /
endless loops, that is how the OS and the
computer works on a low level - continuity
14Computer architecture and program execution
- New processes are started from an OS kernel that
runs in an infinite loop - Each individual process thread requires resources
time slots to execute / computer clock ticks
performance issues when calculating media
//process CPU instructions until the next screen
redraw while(!vertical_retrace)
tickspassedcpu_ProcessNextInstruction()
interrupts_Process(tickspassed)
video_Process(tickspassed)
sound_Process(tickspassed) //etc. for other
components
15Computer architecture and program execution
- Same endless loop metaphor when calculating media
drawing methods that repeat as long as the
program is running (rate say 25 fps) - Same endless loop metaphor when reading and
applying sensor signals application depends
completely on our design video audio render
frames - Interrupt / variable as a way to intervene in the
endless loop
While (1) var a ReadSensorValue(1) ApplyVal
ue(a)
While (1) var a ReadSensorValue(1) DrawCurr
entFrame(a)
16Practical issues
- Practical issues around interfacing a data
acquisition and software utilisation. - Here for our chosen board, Teleo Intro by Making
Things (see separate document on Sensor Tech
website) - Installing the Teleo driver
- Preparing the Teleo
- Example Flash program
- Example Max program
- Example Java via Max program