Hi Everyone,
I enjoy Zumo Robot for Arduino ver1.2.
I used “LineSensorTest” example to examine QTR_NO_EMITTER_PIN.
I want to use D2 pin (Emitter Pin: Arduino Uno) for alternate purposes:
for example, slide switch).
Could you teach me how to use D2 pin for other purpose ?
I want to know how to use “reflectanceSensors.init(QTR_NO_EMITTER_PIN);”.
I tried test codes (Case a and b). QTR_NO_EMITTER_PIN dose not work.
(1) program
void setup()
{
// Initialize the reflectance sensors module
byte pins[] = {4, A3, 11, A0, A2, 5};
reflectanceSensors.init(pins, 6,2000, QTR_NO_EMITTER_PIN );
// reflectanceSensors.init(QTR_NO_EMITTER_PIN);
(2) Results (serial monitor)
Code a
reflectanceSensors.init(pins, 6, 2000); <==== without QTR_NO—
<>
1052 852 1740 2000 1268 1224 E
1052 848 1736 2000 1300 1216 E
1052 848 1736 2000 1308 1220 E
1052 844 1732 2000 1304 1220 E
Code b
reflectanceSensors.init(pins, 6,2000, QTR_NO_EMITTER_PIN );
<>
2000 2000 2000 2000 2000 2000 E
2000 2000 2000 2000 2000 2000 E
2000 2000 2000 2000 2000 2000 E
2000 2000 2000 2000 2000 2000 E
Thank you