aethersdr / aethersdr/AetherSDR

TGXL: display and print stored tuner memories (frequency, L, C1, C2)

Open
#475 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement external devices GUI maintainer-review priority: low upstream
Dominant language
C++
Stars
221
Forks
117
Avg merge
2d 7h
Merged PRs (30d)
299

Description

Request preparation
  • I used an AI assistant to help structure this request
  • I checked for existing issues covering the same feature
What would you like?

Allow for a detailed print out and display of the saved TGXL memories showing frequency and L,C1,C2 settings.

It sounds like you’re working with a system (likely radio- or signal-related) that stores TGXL memories with parameters like frequency and capacitance values (L, C1, C2), and you want a way to print and display them in a detailed, structured format.

Since “TGXL memories” isn’t a widely standardized format, I’ll outline a practical approach you can adapt depending on your setup (embedded system, SDR software, microcontroller, etc.).


1. Define a Clear Memory Structure

Make sure each stored memory entry includes all required fields:

typedef struct {
    float frequency;   // MHz or Hz
    float L;           // Inductance (µH, nH, etc.)
    float C1;          // Capacitance (pF, nF, etc.)
    float C2;
    int usage_count;   // Optional: track frequency of use
} TGXL_Memory;

2. Store Multiple Memories

Example array:

TGXL_Memory memories[50];
int memory_count = 0;

3. Add a Detailed Print Function

This is the key part you’re asking for—clear, readable output:

void print_memories() {
    printf("---- TGXL Memory Dump ----\n");
    printf("Idx | Frequency |   L   |  C1  |  C2  | Uses\n");
    printf("---------------------------------------------\n");

    for (int i = 0; i < memory_count; i++) {
        printf("%3d | %9.3f | %5.2f | %5.2f | %5.2f | %4d\n",
            i,
            memories[i].frequency,
            memories[i].L,
            memories[i].C1,
            memories[i].C2,
            memories[i].usage_count
        );
    }

    printf("---------------------------------------------\n");
}

4. Optional: Sort by Frequency or Usage

For better usability:

void sort_by_frequency() {
    for (int i = 0; i < memory_count - 1; i++) {
        for (int j = i + 1; j < memory_count; j++) {
            if (memories[i].frequency > memories[j].frequency) {
                TGXL_Memory temp = memories[i];
                memories[i] = memories[j];
                memories[j] = temp;
            }
        }
    }
}

5. Optional: Export to File (CSV)

Useful for external viewing or spreadsheets:

void export_to_csv(const char* filename) {
    FILE *file = fopen(filename, "w");
    fprintf(file, "Index,Frequency,L,C1,C2,Usage\n");

    for (int i = 0; i < memory_count; i++) {
        fprintf(file, "%d,%.3f,%.2f,%.2f,%.2f,%d\n",
            i,
            memories[i].frequency,
            memories[i].L,
            memories[i].C1,
            memories[i].C2,
            memories[i].usage_count
        );
    }

    fclose(file);
}

6. If This Is for a UI (Display Screen)

Instead of raw printf, format like:

Memory #12
Freq: 14.200 MHz
L:    1.25 µH
C1:   120 pF
C2:   85 pF
Uses: 34

Or paginated list:

  • Knob/scroll → navigate memories
  • Button → expand details

7. Enhancements You Might Want

  • Highlight most-used memories
  • Filter by frequency range
  • Auto-calculate L/C from frequency (if applicable)
  • Add timestamp of last use

Quick Clarification

To tailor this exactly to your setup, tell me:

  • What system is this running on? (e.g., Arduino, SDR software, TGXL tuner, etc.)

  • Are you printing to:

    • Serial console
    • LCD/OLED display
    • PC software

I can then give you a drop-in implementation specific to your hardware/software.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the TGXL memory storage and the existing display and printing entry points in AetherSDR. Determine how frequency, L, C1, and C2 are represented and whether the request targets an on-screen view, printed output, or both. Done means stored tuner memories are shown and printed with those four values in a clear, usable format.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
desktop
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.