IR Sensor Module wired to ESP8266 Micro-controller. Arduino UNO and NANO also used in many examples.
The model train projects on this site can be sub-divided into
1. The sensors
2. The train signals
3. Using multiple sensors to control the signals.
4. Transmitting information to the outside world.
This folder is concerned specifically with the IR_Sensor. Projects using the LDR sensor are on the LDR_Sensors page. The train signals page will use these sensors to control train signals. Since the sensors will be used to test the signals and vice versa many projects are relevant to both. Using multiple sensors and transmitting information are in the folder Model Trains
Basically the projects developed in the IR_Sensors page will generate a signal train_over_sensor( ) that will is used by the projects in the train signals page to control the signals.
IR Testing: Verifying operation for use in a model railroad.
IR_Sensor_Class: Project develops a sensor class that includes a public method train_over_sensor( )
1. LDR vs IR. IR more expensive, difficult to retro-fit, not sensitive to variations in ambient light levels
2. Filtering; Default program IR_Sensor_Class gives a 1 second filter. If other filtering required program LDR_Overload_Class can be adapted.
3. Micro-controller inputs: Default program IR_Sensor_Class assumes each IR sensor is wired to a single micro-controller pin. If a parallel to serial convertor is necessary use modify code from LDR_Serial_Sensors_Class.
See Train_Signals and Model_Trains pages