Application: IR light barrier over a distance of 1m
Receiver: e.g. Vishay TSSP4038 IR sensor (tuned to 38 kHz)
Ambient temperature range: -10 to 40° C
Here I’ve found a circuit with a Schmidt trigger that should do the trick, if there was a crystal oscillating at 38 kHz. But I can’t find any. Digikey lists 38 kHz crystals, but – looking at the spec sheets – it turns out that they are actually 32,768 Hz crystals.
How do I get 38 kHz?
I’ve also considered an NE555 based circuit, but that’s not temperature stable, and it requires trimming. Another option, I’ve been told, would be using an Arduino to generate the 38 kHz, but that looks like overkill.
Update
Following the recommendation in the application note mentioned in Ali Chen's answer, I finally decided to use an Arduino Nano. For generating the 38 kHz, I used the timer as described in an Arduino forum post by Nick Gammon to the Arduino forum. His code example:
const byte LED = 11; // Timer 2 "A" output: OC2A
void setup() {
pinMode (LED, OUTPUT);
// set up Timer 2
TCCR2A = _BV (COM2A0) | _BV(WGM21); // CTC, toggle OC2A on Compare Match
TCCR2B = _BV (CS20); // No prescaler
OCR2A = 209; // compare A register value (210 * clock speed)
// = 13.125 uS, so frequency is 1/(2 * 13.125) = 38095 Hz
} // end of setup
void loop() { }
Via an interrupt pin, I hooked the Nano up to a Yún, which runs the main logic and which tells the Nano to turn the signal on or off. Keep in mind that the Vishay application note is about measuring the distance to an object, whereas my application is simply about measuring whether a beam is interrupted or not.
Next steps: Get rid of the Nano; Upgrade from 38 to 56 kHz for slightly faster sensing.