Moved to Team 9.
Fork of LineScan by
LineScan.h@14:928254a609cb, 2015-04-18 (annotated)
- Committer:
- ng3600
- Date:
- Sat Apr 18 00:19:59 2015 +0000
- Revision:
- 14:928254a609cb
- Parent:
- 12:ce6d9f7dc76e
- Child:
- 18:8a65598abf2f
Updated Linescan library, searches for thinnest white line now. Consider adding a minimum line width later.
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
ng3600 | 0:2d546112b0b8 | 1 | #include "mbed.h" |
ng3600 | 0:2d546112b0b8 | 2 | #include "rtos.h" |
ikrase | 6:984ccef5ca19 | 3 | #include "telemetry-mbed.h" |
ng3600 | 0:2d546112b0b8 | 4 | |
ng3600 | 0:2d546112b0b8 | 5 | #define NUM_PIX 128 |
ng3600 | 8:b9ec2f3e12b6 | 6 | #define SKIP 15 |
ng3600 | 14:928254a609cb | 7 | #define UPDATE_RATE 20 //ms |
ng3600 | 0:2d546112b0b8 | 8 | |
ikrase | 1:f10ec868cd71 | 9 | /** Linescan functions (Nicholas Gan) |
ikrase | 1:f10ec868cd71 | 10 | * to capture linescan frames and process them. |
ikrase | 1:f10ec868cd71 | 11 | */ |
ikrase | 1:f10ec868cd71 | 12 | |
ng3600 | 0:2d546112b0b8 | 13 | uint16_t read1Bit(AnalogIn cam, DigitalOut *camClk); |
ng3600 | 0:2d546112b0b8 | 14 | void startRead(DigitalOut *camSi, DigitalOut *camClk); |
ng3600 | 14:928254a609cb | 15 | float processFn(uint16_t *array, int arraySz, int* exposure, telemetry::NumericArray<uint16_t, NUM_PIX - 2 * SKIP> &tele_linescan_diff); |
ng3600 | 14:928254a609cb | 16 | float getLinePos(AnalogIn cam, |
ng3600 | 14:928254a609cb | 17 | DigitalOut *camSi, |
ng3600 | 14:928254a609cb | 18 | DigitalOut *camClk, |
ng3600 | 14:928254a609cb | 19 | int *exposure, |
ng3600 | 14:928254a609cb | 20 | telemetry::NumericArray<uint16_t, 128> &tele_linescan, |
ng3600 | 14:928254a609cb | 21 | telemetry::NumericArray<uint16_t, NUM_PIX - 2 * SKIP> &tele_linescan_diff); |