Skip to content

Latest commit

 

History

History
126 lines (97 loc) · 3.21 KB

File metadata and controls

126 lines (97 loc) · 3.21 KB

Paddles Switched - Final Configuration

Current Configuration (FINAL)

The paddles are now configured as:

  • LEFT paddle = DAH (dash, -)
  • RIGHT paddle = DIT (dot, ·)

Changes Made

1. Code Logic (automatic_keyer_thread)

if left_pressed {
    // Generate DAH (left paddle = dah)
    decoder.lock().unwrap().add_element(false);  // false = dah
    // Play long tone (3 units)
    thread::sleep(Duration::from_millis(dah_ms as u64));
}

if right_pressed {
    // Generate DIT (right paddle = dit)
    decoder.lock().unwrap().add_element(true);   // true = dit
    // Play short tone (1 unit)
    thread::sleep(Duration::from_millis(dit_ms as u64));
}

2. UI Labels

The paddle status display now shows:

LEFT (Dah)    RIGHT (Dit)

How It Works Now

Paddle Behavior

Left Paddle (DAH):

  • Press LEFT → Hear LONG beep
  • Display shows: - (dash)
  • Duration: 3 units

Right Paddle (DIT):

  • Press RIGHT → Hear SHORT beep
  • Display shows: . (dot)
  • Duration: 1 unit

Testing Examples

Letter "T" (dah: -)

  1. Press LEFT paddle → long beep, see -
  2. Wait for timeout → see "T" ✓

Letter "E" (dit: ·)

  1. Press RIGHT paddle → short beep, see .
  2. Wait for timeout → see "E" ✓

Letter "A" (dit-dah: ·-)

  1. Press RIGHT paddle → short beep, see .
  2. Press LEFT paddle → long beep, see .-
  3. Wait for timeout → see "A" ✓

Letter "N" (dah-dit: -·)

  1. Press LEFT paddle → long beep, see -
  2. Press RIGHT paddle → short beep, see -.
  3. Wait for timeout → see "N" ✓

Letter "K" (dah-dit-dah: -·-)

  1. Press LEFT-
  2. Press RIGHT-.
  3. Press LEFT-.-
  4. Wait for timeout → see "K" ✓

Letter "S" (dit-dit-dit: ···)

  1. Press RIGHT.
  2. Press RIGHT..
  3. Press RIGHT...
  4. Wait for timeout → see "S" ✓

Letter "O" (dah-dah-dah: ---)

  1. Press LEFT-
  2. Press LEFT--
  3. Press LEFT---
  4. Wait for timeout → see "O" ✓

Visual Feedback

When you press a paddle:

  • Press LEFT → "LEFT (Dah)" turns RED, long beep, see -
  • Press RIGHT → "RIGHT (Dit)" turns RED, short beep, see .

Morse Code Reference

With this configuration:

Character Pattern Paddle Sequence
E · RIGHT
T - LEFT
A ·- RIGHT, LEFT
N LEFT, RIGHT
I ·· RIGHT, RIGHT
M -- LEFT, LEFT
S ··· RIGHT, RIGHT, RIGHT
O --- LEFT, LEFT, LEFT
K -·- LEFT, RIGHT, LEFT
R ·-· RIGHT, LEFT, RIGHT

Summary

Final Configuration:

  • LEFT paddleDAH (dash, long beep, -)
  • RIGHT paddleDIT (dot, short beep, ·)

UI Display:

┌────────────────────────────────────┐
│  Paddle Status:                    │
│  LEFT (Dah)       RIGHT (Dit)      │
│  └─ dash/-        └─ dot/·         │
└────────────────────────────────────┘

The code compiles successfully and the paddles are now correctly configured as requested!