send dat tones thru 40m transmitter - SteveJustin1963/tec-DAT GitHub Wiki

tec1_JMON_rom_docs.pdf

code audio tones

The provided documentation describes a Z80 assembly routine for sending audio to a tape recorder to store program data. Here's a breakdown of how it works:

Overall Process (Tape Output Routine - 04F0 onwards)

The tape output routine (starting at address 04F0) handles the entire process of saving data to tape. It follows these steps:

  1. Leader Tone Output: A low-frequency tone "leader" is outputted first. This helps the tape recorder synchronize with the signal. The duration of this leader is set by loading HL with 3000h (04F0-04F3). The CALL 0680 instruction then initiates the low tone generation.
  2. File Information Block Output: After the leader, a 12-byte "File Information Block" is outputted (04F6-04FF).
    • HL is loaded with 08A4h, which is the start address of the file information block.
    • B is loaded with 0Ch (12 bytes), representing the number of bytes to output.
    • The accumulator A is cleared to initialize the checksum.
    • CALL 064B is used to call the OUT BLOCK routine, which handles the actual byte output and checksum calculation.
  3. Middle Sync Tone: Following the file information block, several seconds of a high-frequency "middle sync" tone are outputted (04FF-0505). This tone serves as a delay for the tape input routine to display the file number.
  4. Data Block Output Loop: The program data is then outputted in blocks of 256 bytes (0505 onwards).
    • The byte count (BC) is loaded with the total number of bytes.
    • A routine (CALL 05C9) is called to convert the block count (B register) to a display format and output it to Port 2. This routine also handles testing for zero blocks and updating the count.
    • If a full 256-byte block is to be outputted, a short high tone sync is outputted (CALL 0684) before each block.
    • The OUTBLOCK routine (CALL 064B) is then called to output the 256-byte block and its checksum.
    • A loop continues until all blocks are outputted.
  5. End of File Tone: Once all blocks are transmitted, a high-frequency "end of file" tone is outputted.

Subroutines Involved:

  • TONE ROUTINE (0686 onwards): This routine generates either a low-frequency (long period) or high-frequency (short period) tone based on the value in the L register and the C register (0680, 0684, 0686). It accounts for high-speed saves by halving the cycle count. The speaker is also toggled (0698).
  • OUTPUTS A SINGLE BIT (0666 onwards): This routine outputs a single bit to the tape (0666).
    • A logic 1 is represented by 2 short and 2 long periods.
    • A logic 0 is represented by 4 short periods and 1 long period.
    • The L register is loaded with double the low-speed cycle count (066B, 0670, 0674, 0679).
    • It calls either the HIGH TONE (0684) or LOW TONE (0680) routines depending on the bit value.
  • OUTPUTS A SINGLE BYTE (0657 onwards): This routine outputs a single byte (in register E) to the tape. The format includes a start bit (binary zero), eight data bits, and a stop bit (binary one) (0657). It uses CALL 0666 (Output Bit) to send each individual bit (065A, 065F).
  • OUT BLOCK (064A onwards): This routine outputs a block of data to the tape.
    • B holds the number of bytes in the block, and HL addresses the block (064A).
    • As each byte is outputted, a checksum is calculated by adding the byte to the accumulator (064B, 064C).
    • The OUT BYTE routine (CALL 0657) is called to send each byte (064E, 064F).
    • After all bytes, the checksum (incremented by 1) is sent to the tape (0654, 0655, 0656).
  • PERIOD MEASUREMENT (0630 onwards): This routine (CALL 0630) measures the period of each tape cell and compares it to a threshold to distinguish between short and long periods. It also echoes the tape level on the TEC speaker (0630).

This detailed approach ensures reliable storage of program data on a tape recorder by carefully controlling the audio signals, including leader, data blocks with checksums, and end-of-file markers.

modulation

[cite_start]The code you provided uses a form of frequency shift keying (FSK) for encoding or modulation, where different durations of high and low tones represent binary data[cite: 1380, 1381, 1382, 1422, 1423, 1424].

Specifically, the encoding works as follows:

  • [cite_start]Logic 0: Represented by 4 short periods of a high tone followed by 1 long period of a low tone[cite: 1381, 1424].
  • [cite_start]Logic 1: Represented by 2 short periods of a high tone and 2 long periods of a low tone[cite: 1381, 1423].

[cite_start]These descriptions refer to "high-speed figures," and for "low speed," these counts are doubled[cite: 1382]. [cite_start]The bits are decoded by counting the ratio of short periods to long periods[cite: 1383].

frequencies

Here's an approximation of the frequencies, assuming the Z80 CPU clock is 4MHz and based on the period measurement routine:

The PERIOD MEASUREMENT routine (starting at 0630h) measures the time a tape signal stays high or low. [cite_start]It increments the DE register within loops that are controlled by the tape input level[cite: 1].

[cite_start]Let's analyze the PERIOD MEASUREMENT routine[cite: 1]:

  • [cite_start]The routine initializes DE to 0000h[cite: 1].
  • [cite_start]It then enters a loop (0633h to 0637h and 063Ch to 0640h) where DE is incremented (INC DE) as long as the tape input level remains high or low[cite: 1].
  • Each INC DE instruction takes 6 clock cycles. [cite_start]The loop also contains IN A, (03) (11 cycles) and RLA (4 cycles), JR NC, 0633 (8 or 12 cycles) or JR C, 063C (8 or 12 cycles)[cite: 1].
  • [cite_start]At 0647h, the measured period (in E) is compared to 1Ah (26 decimal)[cite: 1]. [cite_start]This value 1Ah is the "threshold" between a short and long period[cite: 1].

While a precise calculation of the loop's clock cycles is complex without knowing the exact Z80 instruction timings for each instruction, we can estimate based on the threshold.

If a value of 1Ah in DE represents the threshold, and DE is incremented roughly once per loop iteration, then the number of loop iterations directly relates to the duration.

Estimated Calculation:

Let's assume an average loop iteration takes approximately 20-30 clock cycles (this is a rough estimate and would require precise Z80 instruction timings for accuracy).

  • If DE reaches 1Ah (26 decimal) for a "short" period, and assuming each increment of DE takes approximately X clock cycles:
    • Total clock cycles for a "short" period ≈ $26 * X$
  • [cite_start]The OUTPUTS A SINGLE BIT routine (starting at 0666h) defines the number of "half cycles" (represented in L) for high and low tones[cite: 1].
    • [cite_start]Logic 0: 4 short periods (high tone) and 1 long period (low tone)[cite: 1].
      • [cite_start]LD L, 10h (16 decimal) for high tone cycle count[cite: 1].
      • [cite_start]LD L, 04h (4 decimal) for low tone cycle count[cite: 1].
    • [cite_start]Logic 1: 2 short periods (high tone) and 2 long periods (low tone)[cite: 1].
      • [cite_start]LD L, 08h (8 decimal) for high tone cycle count[cite: 1].
      • [cite_start]LD L, 08h (8 decimal) for low tone cycle count[cite: 1].

[cite_start]The TONE ROUTINE (starting at 0686h) uses L as a cycle count and C as the period[cite: 1]. [cite_start]C is loaded with 29h (41 decimal) for a low tone and 11h (17 decimal) for a high tone[cite: 1].

[cite_start]These C values (29h and 11h) represent the number of times a tight DJNZ loop (0696h) executes for each half-cycle of the tone[cite: 1].

  • [cite_start]DJNZ takes 13 cycles if not zero, 8 cycles if zero[cite: 1].
  • [cite_start]Inside the loop, there are also XOR 80h (8 cycles), SBC HL, DE (15 cycles), and JR NZ, 0693 (12 or 7 cycles)[cite: 1].

So, for a high tone (C = 11h = 17 cycles), the duration of one "half-cycle" would be approximately: $17 * (13 + 8 + 15 + 12) \text{ cycles} \approx 17 * 48 \text{ cycles} \approx 816 \text{ clock cycles}$. Since the TONE ROUTINE toggles the speaker bit (XOR 80h) in a loop that occurs twice per cycle (once for high, once for low), this effectively means one full cycle takes approximately $2 * 816 = 1632$ clock cycles. Frequency = $4,000,000 \text{ Hz} / 1632 \text{ cycles} \approx 2450 \text{ Hz}$.

For a low tone (C = 29h = 41 cycles), the duration of one "half-cycle" would be approximately: $41 * 48 \text{ cycles} \approx 1968 \text{ clock cycles}$. One full cycle approximately $2 * 1968 = 3936$ clock cycles. Frequency = $4,000,000 \text{ Hz} / 3936 \text{ cycles} \approx 1016 \text{ Hz}$.

These are approximate frequencies. The actual frequencies would depend on the exact Z80 instruction cycle counts and any other overhead in the TONE ROUTINE loops.

In summary, for a 4MHz clock, the approximate frequencies are:

  • High Tone: ~2.45 kHz
  • Low Tone: ~1.02 kHz

send on CW radio

Feeding these FSK tones into a simple CW (Continuous Wave) 40m transmitter requires some adaptation, as CW typically involves simply turning a carrier on and off (on-off keying, OOK) at a specific frequency, while FSK uses two distinct frequencies.

Here's how you could approach it, with considerations for a "simple" transmitter:

1. Directly Modifying the VFO/Oscillator (Challenging for Simple CW):

  • Concept: The most direct way to implement FSK is to rapidly shift the frequency of your transmitter's Variable Frequency Oscillator (VFO) or main oscillator between the two calculated tone frequencies (e.g., ~2.45 kHz and ~1.02 kHz above or below your desired 40m CW operating frequency, or directly at those offsets from a nominal CW tone).
  • Challenges for Simple CW:
    • Frequency Stability: Simple CW transmitters often use basic oscillators (like a crystal oscillator or a simple LC VFO) that are designed for stability at a single frequency. Rapidly shifting their frequency by a few kilohertz without introducing significant drift, chirp, or instability is difficult.
    • Switching Speed: The rate at which you need to switch between the tones for data transmission (which dictates the "short" and "long" periods) might be too fast for a mechanically tuned VFO or a crystal-based oscillator to respond cleanly.
    • Control Mechanism: You'd need a voltage-controlled oscillator (VCO) or a varactor diode in your VFO circuit, with the digital output from your Z80 system (representing the FSK tones) driving a Digital-to-Analog Converter (DAC) or a simple voltage switch to control the varactor.

2. Audio Input to a Sideband Transmitter (More Common for FSK):

  • Concept: While you specified a "CW transmitter," if it has any form of audio input (like a simple AM or SSB modulator often found in slightly more complex QRP rigs), you could generate the FSK tones as actual audio and feed them into the transmitter's audio input. The transmitter would then transmit these audio tones as sidebands on the 40m carrier.
  • How it works:
    • [cite_start]The Z80 system generates the ~2.45 kHz and ~1.02 kHz audio tones (as described by the tone generation routines [cite: 1]).
    • These audio signals are then fed into the microphone or audio input of an SSB (Single Sideband) or even a simple AM transmitter.
    • The transmitter's modulator converts these audio frequencies into corresponding radio frequencies around the 40m band. For example, if you're on USB (Upper Sideband), a 1 kHz audio tone would be transmitted as $F_{carrier} + 1 \text{ kHz}$, and a 2.45 kHz tone as $F_{carrier} + 2.45 \text{ kHz}$.
  • Advantages: This is a much more common and stable way to transmit FSK with amateur radio equipment, as the audio generation and RF modulation are handled by separate, purpose-built stages.
  • Limitations: A "simple CW transmitter" might not have the necessary SSB or AM modulation capabilities.

3. External Modulator for On-Off Keying (Simulating FSK with OOK for simpler CW):

  • Concept: This is a compromise. A very simple CW transmitter is often just an oscillator that's keyed on and off. You cannot achieve true FSK with just on-off keying of a single frequency. However, you could simulate a form of "data over CW" by translating your FSK tones into varying on-off patterns, similar to how PSK31 or MFSK modes work by varying phase or multiple tones, but in a very basic way.
  • How it might work (limited FSK simulation):
    • You would choose one of your FSK tone frequencies as your "carrier tone" (e.g., the 2.45 kHz high tone).
    • When a "logic 1" is supposed to be sent, you transmit the carrier for a specific duration.
    • When a "logic 0" is supposed to be sent, you transmit the carrier for a different specific duration, or perhaps even transmit nothing (silence) for a duration.
    • The receiver would then have to interpret these varying on/off durations as logic 0s and 1s.
  • Limitations: This is not true FSK. It's a form of pulse-width modulation or baud-rate keying. It loses the spectral efficiency and noise immunity benefits of true FSK, and it relies heavily on precise timing at both the transmitter and receiver. It's also less robust than actual FSK.

Practical Considerations for a Simple CW 40m Transmitter:

For a truly "simple CW 40m transmitter" that only does on-off keying (like a basic QRP "pixie" kit):

  • You would typically not feed an audio signal directly into the output. CW transmitters are designed to output a clean, unmodulated carrier. Feeding an audio signal into the RF output stage would result in distorted, wideband emissions.
  • [cite_start]The OUT (01), A and OUT (02), A instructions [cite: 1] indicate that the Z80 is controlling specific output ports that are likely connected to the speaker or other tone-generating hardware. To get these tones into an RF transmitter, you'd need a circuit that takes these audio-frequency tones and uses them to either:
    1. Shift the VFO frequency (complex for simple CW).
    2. Modulate an SSB/AM stage (if your CW rig has one).
    3. Key the transmitter on/off in a patterned way (simple but not true FSK).

Recommendation:

If your "simple CW 40m transmitter" is just a keyed oscillator, direct FSK as defined by the provided code is fundamentally incompatible without significant modifications to the transmitter's RF section (adding a varactor-tuned VFO and appropriate control circuitry).

The most practical approach to using these tones with amateur radio (even if your current rig is just CW) would be to:

  1. Generate the audio FSK tones from your Z80 system.
  2. Feed these audio tones into an SSB transmitter's audio input. This is the standard way to transmit FSK data modes.

If you are strictly limited to a basic on-off CW transmitter, you would have to adapt your data encoding to a simple on-off keying scheme, rather than true FSK.

modify xmtr

Modifying a simple CW transmitter to handle the FSK tones generated by the Z80 code presents a few options, each with varying levels of complexity and true FSK capability.

Here are the primary options for modifying a simple CW transmitter:

  1. Direct VFO Frequency Shifting (True FSK - Most Complex for Simple CW):

    • Concept: This method involves directly altering the frequency of your transmitter's Variable Frequency Oscillator (VFO) or main oscillator between the two FSK tone frequencies. For example, if your nominal 40m CW frequency is 7.020 MHz, you might shift it to 7.02102 MHz for the low tone (~1.02 kHz offset) and 7.02245 MHz for the high tone (~2.45 kHz offset), or vice-versa, depending on your FSK standard.
    • How to Modify:
      • Varactor Diode: Integrate a varactor (variable capacitance) diode into the VFO's LC (Inductor-Capacitor) tank circuit. The capacitance of a varactor changes with an applied reverse voltage, thus changing the resonant frequency of the VFO.
      • Voltage Control: Your Z80 system, through a simple Digital-to-Analog Converter (DAC) or two carefully chosen voltage levels (generated perhaps by resistors and transistors controlled by the Z80's output port), would apply the appropriate voltage to the varactor to select between the two frequencies.
    • Challenges:
      • Stability: Maintaining frequency stability while rapidly switching can be difficult for simple VFO designs, potentially leading to "chirp" (frequency shifting during keying) or drift.
      • Switching Speed: The varactor and VFO must be able to respond quickly and cleanly to the digital signal rates (short and long periods) defined by your FSK modulation.
      • Design Expertise: This option typically requires a good understanding of RF circuit design and oscillator theory.
  2. Audio Input to an Existing Modulator (Pseudo-FSK/AFSK - If Transmitter has Modulator):

    • Concept: If your "simple CW transmitter" is actually a more versatile rig that includes an Amplitude Modulation (AM) or Single Sideband (SSB) modulator (even a basic one), you can generate the FSK tones as audio frequencies from your Z80 and feed them into the transmitter's audio input. The transmitter would then transmit these audio tones as sidebands on the 40m carrier.
    • How to Modify:
      • Audio Output: Connect the Z80's audio output (after appropriate filtering and amplification to line level) to the microphone or auxiliary audio input of your transmitter.
      • Transmitter Mode: Set the transmitter to AM or SSB mode (e.g., USB or LSB, depending on your preference for how the sidebands will appear on the spectrum).
    • Advantages: This is a much more common and stable method for transmitting FSK data modes in amateur radio, as the audio generation and RF modulation are handled by dedicated stages.
    • Limitations: Many truly "simple CW transmitters" (like basic QRP kits) are designed solely for on-off keying and lack an internal AM/SSB modulator. Adding one would essentially mean building a new part of the transmitter.
  3. On-Off Keying (OOK) Simulation (Simplest, but Not True FSK):

    • Concept: If your CW transmitter only supports on-off keying, you cannot achieve true FSK. However, you can use the timing of your Z80's FSK "bits" to control the on/off state of the CW carrier, effectively creating a form of pulse-width modulation or simple baud-rate keying.
    • How to Modify:
      • Keying Interface: Connect an output from your Z80 (perhaps through a transistor switch or opto-isolator for isolation) directly to the CW keying input of your transmitter.
      • Software Adaptation: In your Z80 code, instead of generating different frequencies, you would translate your FSK logic (0s and 1s) into varying durations of "key down" (carrier on) or "key up" (carrier off). For instance, a "logic 1" might be a short "on" pulse followed by a short "off" period, while a "logic 0" might be a longer "on" pulse followed by an "off" period.
    • Advantages: This is the easiest modification for a basic OOK CW transmitter.
    • Limitations:
      • Not True FSK: This is not true FSK, as you are not shifting frequencies, only the duration of a single frequency carrier.
      • Decoding Complexity: The receiver would need to be specifically designed to interpret these timing differences rather than frequency shifts.
      • Performance: Less robust against noise and interference compared to true FSK.

Summary of Options for a "Simple CW Transmitter":

For a truly simple CW transmitter (just an on-off keyed oscillator), option 3 is the most straightforward to implement without significant additional RF design. However, it compromises on the true FSK modulation. If you want proper FSK, you would need to either build in VFO frequency shifting (option 1, complex) or find a transmitter with an existing AM/SSB modulator (option 2).

modify

image

Let's analyze the provided "Ten Minute Transmitter" circuit and discuss how to modify it to send FSK tones, keeping in mind its simple CW (Continuous Wave) nature.

The "Ten Minute Transmitter" circuit is a very basic crystal oscillator, followed by a simple output stage. It's designed for On-Off Keying (OOK), where the "KEY" switch simply turns the entire transmitter on or off.

To modify this specific circuit for FSK (Frequency Shift Keying) from your Z80's generated tones, we primarily need to look at Option 1: Direct VFO Frequency Shifting from our previous discussion, as it's a fixed-frequency crystal oscillator.

Challenges with this specific circuit:

  • Crystal Stability: The XTAL 3560 (3.560 MHz) crystal is designed for a very stable, fixed frequency. Shifting its frequency significantly and cleanly is challenging. Crystals have a very high Q-factor, meaning they resist frequency changes.
  • Simple Design: This circuit is extremely minimalist. It lacks any dedicated VFO stage or modulation inputs that would simplify FSK implementation.
  • "Ten Minute" Nature: The design prioritizes simplicity and quick build time. Adding FSK capability will invariably increase complexity.

Modification Strategy (Direct Crystal Frequency Shifting - VFO-like behavior):

The goal is to slightly "pull" the crystal frequency between two discrete values. This is commonly done using a varactor diode.

  1. Introduce a Varactor Diode:

    • Placement: The varactor diode would be placed in series or parallel with the crystal, or within the crystal's resonant tank circuit. A common approach for crystal pulling is to place a varactor in series with the crystal and a small capacitor to ground.
    • Component: You'll need a varactor diode (e.g., BB109, MV2109, or even a common 1N4001 diode can act as a varactor if reverse-biased).
    • Circuit Change:
      • Remove or reduce the fixed capacitor in parallel with the crystal (if one were present, though not explicitly shown in this very basic diagram).
      • Add the varactor diode in series with the crystal's connection to the transistor's base, or in parallel across the crystal, with appropriate DC blocking and RF bypass capacitors.
  2. Voltage Control for the Varactor:

    • From Z80: Your Z80 system, generating the two distinct frequencies (e.g., ~1.02 kHz and ~2.45 kHz), needs to produce two corresponding DC voltage levels.
    • DAC (Ideal): The most precise way would be to use a simple 8-bit Digital-to-Analog Converter (DAC) connected to a Z80 output port. The Z80 would output byte values that correspond to the desired voltage for each FSK frequency.
    • Transistor Switch (Simpler): A simpler approach for two frequencies might involve using two NPN transistors (or one dual-output transistor) controlled directly by two Z80 output pins. Each transistor would switch a different resistor value into a voltage divider, creating the two required DC voltage levels for the varactor.
    • Connection: This modulated DC voltage would be fed to the varactor diode through a high-value resistor (e.g., 100kΩ to 1MΩ) to isolate the RF from the control voltage, and a DC blocking capacitor (e.g., 0.01uF) to prevent the DC voltage from interfering with the crystal's oscillation.
  3. Keying the Transmitter:

    • The KEY switch in the original circuit simply enables/disables the entire transmitter. For FSK, you don't want to turn the transmitter completely off between "bits" if you're sending continuous data.
    • You would replace the manual KEY switch with a transistor switch driven by a Z80 output pin. This output pin would ideally be active whenever data needs to be transmitted, allowing the FSK modulation to occur.

Revised (Conceptual) Circuit Snippets for Crystal Pulling:

Original Circuit:

        +12V
         |
         .
         . (rest of circuit)
         |
       +-----+
       | XTAL|
       | 3560|
       +-----+
         |
         |
      Base of BFY51

Conceptual Modification with Varactor:

        +12V
         |
         .
         . (rest of circuit)
         |
       +-----+
       | XTAL|
       | 3560|
       +-----+
         |
         +----||----+ (DC Blocking Capacitor, e.g., 0.01uF)
         |          |
        ---         |
        /|\ Varactor|
         | Diode    |
         |          +----(RF Choke, e.g., 100uH)----+
         |          |                                |
         +----[R]---+ (High-value Resistor, to isolate Z80 control from RF)
         |
     Control Voltage (from Z80/DAC)

How the Z80 would control it:

  • The Z80's tone generation routines (which currently control speaker output) would be repurposed to generate the necessary voltage levels.
  • When the Z80's code indicates a "logic 0" tone, it would set its output pins (connected to the DAC or voltage switch) to produce Voltage A.
  • When the Z80's code indicates a "logic 1" tone, it would set its output pins to produce Voltage B.
  • These voltages would pull the crystal frequency slightly, thus implementing FSK.

Important Considerations for Success:

  • Frequency Deviation: Crystals can only be "pulled" by a small amount (tens of Hz to a few kHz) before oscillation becomes unstable. You'll need to experiment with the varactor and biasing to achieve the desired ~1.02 kHz and ~2.45 kHz offsets without losing oscillation. This is the biggest hurdle for this very simple design.
  • Filtering: The output of your Z80's voltage control might be noisy. You'll need good filtering (RC networks) on the control voltage line to ensure a clean shift and prevent spurious emissions.
  • RF Isolation: Ensure good RF isolation between the Z80 digital logic and the sensitive RF oscillator. Use bypass capacitors and short leads.
  • Receiver Compatibility: Your receiving station must be capable of decoding FSK signals. Simple CW receivers are typically OOK and won't inherently detect frequency shifts without a dedicated FSK demodulator (e.g., using PLLs or tone decoders).

Given the simplicity of the "Ten Minute Transmitter," achieving reliable FSK from it will be a significant engineering challenge, primarily due to the crystal's fixed nature. It's more common to use a dedicated VFO or DDS (Direct Digital Synthesis) circuit for FSK modulation if you're building a new transmitter.

Using two transistors to switch between two crystals is a viable approach to generate two distinct frequencies for FSK, especially with a simple transmitter design like the "Ten Minute Transmitter." This method is often called a multi-crystal oscillator or crystal switching.

Here's how you could modify the "Ten Minute Transmitter" concept to implement FSK using two transistors and two crystals:

1. The Concept: Instead of trying to "pull" a single crystal, you would have two separate crystals, each tuned to a slightly different frequency (e.g., one at 3.560 MHz and another at 3.562 MHz for a 2 kHz shift). Your Z80 system would then electronically switch between these two crystals, allowing only one to oscillate and feed the transmitter's output stage at any given time.

2. Circuit Modifications:

  • Two Crystals: You'll need two crystals. One for your "mark" frequency (e.g., 3.560 MHz) and one for your "space" frequency (e.g., 3.562 MHz).

  • Switching Transistors/Diodes: You can use additional transistors (e.g., small signal NPN like 2N3904 or 2N2222) or PIN diodes to act as switches.

    • Transistor Switching: This is a common and relatively simple method. Each crystal would have its own switching transistor connected to its oscillation path.
    • PIN Diode Switching: PIN diodes, when forward biased, act like a low resistance, and when reverse biased, act like a high resistance, making them excellent RF switches. This can sometimes offer better isolation.
  • Revised Oscillator Section (Conceptual):

            +12V
             |
             RFC 100uH
             |
        +----+-------------------------+
        |                              |
        |                              |
      [Resistor]                   [Resistor]
        |                              |
      +-------+                      +-------+
      | XTAL1 |                      | XTAL2 |
      | 3560  |                      | 3562  |
      +-------+                      +-------+
        |                              |
        |                              |
        |                              |
      Base of BFY51   <--- This connection is now switched.
    

    Detailed Oscillator Switching (Example with NPN Transistors):

            +12V
             |
             RFC 100uH
             |
        +----+-------------------------+
        |                              |
        |                              |
      [Resistor]                   [Resistor]
        |                              |
      +-------+                      +-------+
      | XTAL1 |                      | XTAL2 |
      | 3560  |                      | 3562  |
      +-------+                      +-------+
        |                              |
        |                              |
      Emitter of Q1                  Emitter of Q2
        |                              |
      Base of BFY51 <---- Connect the Collector of Q1 and Q2 here (after RF combining)
        | (Transmitter's original oscillator transistor)
    
    (Q1, Q2 are switching transistors, e.g., 2N3904)
    Q1 Collector connected to BFY51 Base (via RF combining network)
    Q2 Collector connected to BFY51 Base (via RF combining network)
    
    Q1 Base <---- Control Line 1 (from Z80 output)
    Q2 Base <---- Control Line 2 (from Z80 output)
    
    Q1 Emitter & Q2 Emitter are connected to ground via small resistors for biasing, or directly.
    
    *You'd need careful RF combining/isolation so only one crystal's signal reaches BFY51 at a time.*
    *Additional capacitors might be needed around the crystals for proper oscillation and pulling.*
    

3. Z80 Control Logic:

  • Your Z80 program, based on whether it needs to send a "logic 0" or "logic 1" FSK tone, would control two output pins.
  • Mutually Exclusive Control: It's crucial that only one crystal is active at a time. If both are active, they will "fight" and create instability, wideband noise, or simply fail to oscillate correctly.
    • If sending "logic 0" tone: Z80 Output Pin 1 HIGH, Z80 Output Pin 2 LOW. (Activates XTAL1)
    • If sending "logic 1" tone: Z80 Output Pin 1 LOW, Z80 Output Pin 2 HIGH. (Activates XTAL2)
  • The Z80's tone generation routines would then determine the duration for which each crystal is active, corresponding to the "short" and "long" periods for the FSK modulation.

4. Keying the Transmitter (Again):

  • Similar to the varactor method, the original KEY switch in the "Ten Minute Transmitter" is for OOK. For FSK, you want the transmitter to be continuously on while data is being sent.
  • The KEY input should be replaced with a transistor switch controlled by a Z80 output pin that stays "on" for the entire duration of the data transmission.

Advantages of Two Crystals:

  • Better Frequency Stability: Crystals inherently offer good frequency stability compared to simple LC VFOs. Switching between two stable crystal frequencies can result in a cleaner FSK signal than "pulling" a single crystal too far.
  • Defined Frequencies: The two frequencies are precisely defined by the crystals chosen.
  • Reduced Chirp: If designed well, this method can minimize frequency "chirp" during keying.

Challenges and Considerations:

  • Crystal Availability/Cost: You need two crystals with the precise frequency difference you desire. This might require custom-ordered crystals or careful selection from standard values. The frequency difference needed is typically small (e.g., 100 Hz to a few kHz) for common FSK modes like RTTY.
  • Switching Speed: While better than pulling, there's still a limit to how fast you can reliably switch between crystals without inducing transient effects. The "short" and "long" periods from your Z80 code (which represent the baud rate) will determine this.
  • Oscillator Design: Integrating two crystals into a single oscillator circuit requires careful design to ensure reliable oscillation of only the selected crystal and minimal interaction between them. You might need small inductors or capacitors in the switching paths to optimize this.
  • RF Isolation: Proper isolation between the two crystal paths and the control lines is crucial to prevent spurious oscillations or unwanted mixing products.
  • Power Output Consistency: Ensure that switching between crystals doesn't cause significant variations in the transmitter's output power, which can distort the FSK signal.
  • Receiver Compatibility: Your receiver must still be capable of decoding FSK, as it's looking for frequency shifts, not just on/off keying.

This "two-crystal" approach is a more robust way to achieve FSK with a crystal-based oscillator than attempting to pull a single crystal by large amounts. It's a commonly used technique in simple FSK transmitters.

You're proposing an interesting hybrid approach, which is indeed a valid way to create two frequencies for FSK, particularly for a simple crystal-based transmitter. The idea is to use the crystal for one stable frequency and then use a ceramic resonator to "pull" or slightly shift the crystal's frequency for the second FSK tone.

Let's break down this concept and how it would apply to the "Ten Minute Transmitter":

Concept:

  • Fixed Frequency (Mark): One of your FSK tones (e.g., the "mark" frequency) would be generated by the crystal oscillating at its fundamental, unperturbed frequency (or as close to it as possible within the circuit).
  • Shifted Frequency (Space): For the other FSK tone (e.g., the "space" frequency), a ceramic resonator would be switched into the crystal's tank circuit. A ceramic resonator, while not as stable as a crystal, has a much lower Q-factor. This lower Q allows it to "pull" or shift the crystal's frequency more significantly than a varactor alone might, or in a more controlled manner than just relying on the crystal's natural pulling range with a varactor. The ceramic resonator would essentially dominate the resonant frequency when switched in, subtly bending the crystal's natural frequency.

Circuit Modification (Conceptual):

You would primarily modify the oscillator section of the "Ten Minute Transmitter".

  1. Crystal (XTAL1): The original 3560 kHz crystal remains the primary oscillating element.
  2. Ceramic Resonator: You'll need a ceramic resonator (e.g., in the 3.5 MHz range, similar to your crystal's frequency, but not necessarily exact). These typically have three pins (center pin to ground, outer two for connection).
  3. Switching Mechanism: You would use a transistor (or a PIN diode, as discussed) to switch the ceramic resonator into or out of the crystal's circuit.

Conceptual Modification Example:

Original circuit part:

        +12V
         |
         .
         . (rest of circuit)
         |
       +-----+
       | XTAL|
       | 3560|
       +-----+
         |
         |
      Base of BFY51

Modified Oscillator Section (with Ceramic Resonator Switching):

        +12V
         |
         .
         . (rest of circuit)
         |
       +-----+
       | XTAL|
       | 3560|
       +-----+
         |
         +----||----+ (DC Blocking Capacitor, e.g., 0.01uF)
         |          |
         |         [Resistor] (e.g., 1k - 10k, for current limiting/biasing)
         |          |
         |        +-----------+
         |        |           |
         |      Ceramic Resonator (e.g., 3.5MHz range)
         |        |           |
         |        +-----------+
         |          |
         |         Q1 Collector (Switching Transistor, e.g., 2N3904)
         |          |
         +----------+ (Connects to BFY51 Base after combining)
         |
      Base of BFY51 (Original Transistor)
      (rest of original oscillator components)

     Q1 Base <---- Control Line (from Z80 output pin)
     Q1 Emitter to Ground (or appropriate biasing)

How the Z80 would Control it:

  • Output Pin: You would typically use a single Z80 output pin to control the switching transistor (Q1).
  • Logic 0 (Mark Frequency - Crystal Only): Z80 output LOW. This turns Q1 OFF. The ceramic resonator is effectively disconnected, and the crystal oscillates at its base frequency (or as determined by the surrounding passive components).
  • Logic 1 (Space Frequency - Crystal + Ceramic Resonator): Z80 output HIGH. This turns Q1 ON. The ceramic resonator is switched into the circuit, interacting with the crystal and shifting the overall oscillation frequency.
  • The Z80's tone generation routines (which output the short/long period control signals) would now drive this single control line for switching the ceramic resonator in and out.

Advantages of this Approach:

  • Distinct Frequencies: Provides two reasonably distinct and stable frequencies for your FSK tones.
  • Simpler Switching: Only one switching transistor/diode is strictly necessary, compared to switching between two full crystal paths.
  • Controllable Pulling: Ceramic resonators offer a more predictable and larger "pulling" effect on crystals compared to simple varactor diode tuning, which can be very subtle.
  • Common Components: Ceramic resonators are readily available and inexpensive.

Challenges and Considerations:

  • Frequency Offset: You'll need to experiment with the specific ceramic resonator and possibly small capacitors/inductors in its path to achieve the exact desired frequency shift (e.g., 1.02 kHz or 2.45 kHz from the crystal's fundamental). This might require trial and error.
  • Oscillation Stability: Ensure that when the ceramic resonator is switched in, the combined circuit remains stable and oscillates cleanly, without glitches or harmonics.
  • Switching Speed: As with any FSK scheme, the switching speed of your transistor (Q1) and the response time of the oscillator circuit need to be fast enough for your desired data rate (defined by the short/long periods).
  • RF Isolation: Proper RF decoupling and bypassing for the Z80 control line are essential to prevent digital noise from affecting the RF output.
  • Keying: Remember to replace the original KEY switch with a Z80-controlled switch that keeps the transmitter continuously active during data transmission.

This hybrid approach is a very practical and common way to generate FSK signals from a single crystal oscillator in simple QRP (low power) transmitter designs.