Download Print this page

Parallax TSL1401-DB Instructions Manual page 44

Linescan camera module

Advertisement

Line
1-8
Some variables that aren't included in the template are defined here.
10
Exposure time is set to 60.
11
Binary acquisition parameters are set: Floating threshold = 0; Hysteresis = 1; Filter = 5
12
Beginning of the main program loop.
13
Wait for the spacebar.
Cue up and execute the commands that snap the picture and find the first dark object edges
14-16
(liquid meniscus) and the last dark object edges (cap).
17
Wait for everything that's been cued up to finish.
18
Start dumping the binary pixels.
19-24
Display the binary pixels in four lines, beginning two lines down from the previous output.
Start dumping the results of the FNDNXTs. Do you notice the 1 in the OWOUT statement?
25
This sends the reset that terminates the pixel dumping from line 21.
26
Read the results of the FNDNXTs.
27
Compute the cap size as the difference between its edge locations.
28
Compute the liquid level as the average of the two edge locations.
29
Test to make sure all the observed locations and sizes meet the specs.
30, 32
Print pass/fail.
34, 35
Print the observed data.
Here is what the output looks like:
© Bueno Systems, Inc. • TSL1401-DB (2009.10.01)
Description
Page 44 of 52

Advertisement

loading