Page 188 of 229 Start Back Next End ZBasic Language Reference 178 ZBasic Microcontrollers ZX-40 Series Power Source If you do not plan to use the Analog-to-Digital converter channels you can eliminate the inductor and the two capacitors on the right side of the diagram. In this case, pin 30 would be connected directly to the power source (as are pins 10 and 30) and pin 32 can be left open. Although not shown on this diagram, the ground pins of the ZX-40 (pins 11 and 31) must be connected to the common ground of the system. Clock Source The ZX-40 series devices require a clock source running at 14.7456MHz except for the ZX-40t which required a 7.3728MHz clock. The easiest way to provide this clock source is to connect a crystal of that frequency to pins 12 and 13 along with the necessary capacitors. Recommended Crystals Package 14.7456MHz 7.3728MHz HC-49/US ECS-147.4-20-4X (Digi-Key #X1102-ND) ECS-73-20-4X (Digi-Key #X1084-ND) HC-49/U ECS-147.4-20-1X (Digi-Key #X1032-ND) ECS-73-20-1X (Digi-Key #X978-ND) Cylinder ECS-147.4-18-9X (Digi-Key #XC-1382-ND) The capacitor value to use depends somewhat on the layout (e.g. stray capacitance). Values in the range of 22pF to 27pF have been used successfully in various situations. ZX-40 Series Clock Source If you already have a clock source at the required frequency you can feed that signal directly to pin 13. In this case there would be no connection to pin 12. Program Memory Some ZX-40 series devices require a serial EEPROM in which to store your program’s code. (The ZX- 40n, ZX-40r, ZX-40s and ZX-40t use internal Flash memory for Program Memory.) The recommended device to use is the Atmel AT25256A (Digi-Key #AT25256A-10PI-2.7-ND). Note, particularly, that the older part without the A suffix will not work due to its slower speed. An EEPROM capable of operation at 7.5MHz or more is required. An alternate part is the ON Semiconductor CAT25256LI-G (Digi-Key #ON Semiconductor CAT25256LI-G-ND). The recommended connection to the ZX-40 series is shown below. The value of the pullup resistor is non-critical, anything from 4.7K to 22K should work well. Higher values will reduce power consumption somewhat.