Use a 40KHz Xtal and a 74C14 schmitt trigger:
________ <---------------- 2.2 M resistor
___| 2M2 |___
| |________| |
| |
| |
| |\ |
| | \ |
+-----| O------+--------> Output 40KHz
| | /
| |/ gate 1 of 74C14
|
|
--+--
XXX 40KHz Xtal
--+--
|
|
-----
---
-
This circuit has worked for me in many applications. (it might be an idea to buffer the signal befor using it. (There are still 5 unused gates in the ‘C14.. :-)
Sources
- Sebastian Filzek