-
Notifications
You must be signed in to change notification settings - Fork 0
Configuring custom output patterns
Updated 15 Jan 2025
With all my decoder projects, you can simply edit the patterns in the code to produce any output activation pattern you need. I default to one pi per band but you can do weird stuff just as easily.
At my last QTH, I had 5-band transverter with 4 of the 5 bands going to high power amps. Each amp used a 12V power-on signal, I activated 1 at a time. 144 and 1296 had dedicated antennas. 222, 432 and 903 shared a common feedline to a LPDA. Each antenna had a bidirectional coupler for SWR.
On band change:
- One PA was powered up
- Transverter band selected
- Amp (or barefoot transverter output for 903) switched to the common feedline if it was 222, 432, or 903
- The appropriate coupler output lines for fwd and ref power (1 coupler per antenna feedline) were switched to the dual channel power detector inputs using a SP5T switch on each coupler output line.
- Finally, PTT was passed along to the transverter and to all of the amps which were connected in common through diodes. Since only 1 amp was powered on at a time, common PTT worked here. The diodes blocked differing voltage, 5, 12, or 28V from back feeding each other.
As I changed antenna config over time, I simply edited the assigned bit pattern and activated multiple ports as needed by editing and compiling, or later, using a Python app on my desktop.
For illustration, the particular band decoder used in the above scenario can be programmed by editing a config file and recompile, the same we will do for this project for now (details further down), but it is also USB or LAN connected, and the Python desktop app UI is used to set the patterns into EEPROM for you. I chose ‘custom’ mode to do the above scenario. Note the byte patterns in the fields below. They are decimal numbers but viewed in binary or hex format, they are placing 1 or 0 onto each of the 8 pins per port - per band. Some patterns will be applied to each band.
Given these ESP32-S3 CPUs are BLE and WiFi enabled, it is possible to do a similar thing. If we use a dual USB model CPU, then the 2nd port can connect to a PC and do this customization over USB. I would just need to make the control protocol the same as my existing decoders – simple ascii messages and can use this UI.
For now, we will just edit some lines for each Band Decoder Output and PTT Output in a file and compile. These are in Decoder.h.
Above are the CPU pin assignment to 13 functions - 6 band enable outputs, 6 PTT outputs, and 1 PTT input. These pin numbers will be fixed once the CPU is wired, but within each group of output types, you can swap pins. Normally you won't want to do this as it would alter the connector labeling or worse.
The above is where the magic happens. The pins are mapped into groups of 6 here, one for Band Select and one for PTT Output.
Band Select activates the programmed pin(s) when a particular band is active. They can be all high or low, all on at once, just some pins, just one pin, or none for each band.
PTT Output activates the programmed pin(s) per band when PTT is active. Same as above, could be just one pin, some or all of them for each band.
By default, I have 1 pin per band for each group as seen above.