Beyond the Touchscreen: Smarter Control for the HaM5dsp
The HaM5dsp is so compact that using its touchscreen for configuration can sometimes be a challenge—or simply tedious. So, naturally, I asked myself: why not make it easier?
To improve usability, I implemented a serial communication interface that allows you to control the device more efficiently. Through simple terminal commands, you can trigger functions, adjust and store persistent settings, and query status information in both DSP and MP3 Player modes.
This approach makes the device far more flexible, especially during development, testing, or repetitive configuration tasks.
Since all commands can be sent from any standard terminal, there’s no need to rely solely on the touchscreen interface.
Additionally, to speed up the process of populating the Voice and CW/DIG memories, I wrote a small Python script that automates the task—making setup quick and painless.
And yes, the script send commands in a compact (“Machine Serial”) protocol; about this, in a future post.
The Human Serial commands look like this:
--------------------------------------------------------------------------------
Command Min/Max Values Short Description
--------------------------------------------------------------------------------
balance N -100 - 100 Stereo balance DSP. ARG
batv - Battery telemetry. ACTION
bypassoff - Disable DSP bypass. ACTION
bypasson - Enable full bypass. ACTION
cw - Enable CW live mode. ACTION
cw2d N 1 - 25 Set CW 2D delay. ARG
cw2doff - Disable CW 2D. ACTION
cw2don - Enable CW 2D. ACTION
cw3d N 1 - 10 Set CW 3D depth. ARG
cw3doff - Disable CW 3D. ACTION
cw3don - Enable CW 3D. ACTION
cwagcoff - Disable CW AGC. ACTION
cwagcon - Enable CW AGC. ACTION
cwbw N 25 - 1000 Set CW BPF bandwidth. ARG
cwcenter 400 - 900 Set CW BPF center frequency. ARG
cwconfidence N 0 - 10 Adjust CW robust threshold. ARG
cwmaxwpm N 12 - 60 Set maximum CW speed. ARG
cwminwpm N 5 - 20 Set minimum CW speed. ARG
cwnoisefloor - Show CW noise floor. ACTION
cwsamplesg1 N 64 - 512 Set Goertzel samples 1. ARG
cwsamplesg2 N 128 - 2048 Set Goertzel samples 2. ARG
displayspace N 0 / 1 / 2 Change Display Space page. ARG
dump - Show DSP and NVS status. ACTION
dumpall - Run all dumps. ACTION
dumpaxp - Dump AXP192 registers. ACTION
dumpes - Dump ES8388 registers. ACTION
fftfloor N 0.0 - 10.0 Set FFT floor level. ARG
fftrange N 0.1 - 10.0 Set FFT dynamic range. ARG
fftspanv N 500 - 8000 Set VOICE FFT span. ARG
hapton/off - Haptic global ON/OFF. ON/OFF
haptlong - Trigger long vibration. ACTION
haptlong N 10 - 2000 Set long vibration duration. ARG
haptshort - Trigger short vibration. ACTION
haptshort N 10 - 1000 Set short vibration duration. ARG
help - Show command list. ACTION
hicut N 1200 - 10500 Set VOICE Hi-cut filter. ARG
hpinfo N - Show headphone jack status. ACTION
igain N 0 - 8 Set ADC gain. ARG
inatt N 0 - 100 Set DSP input attenuation. ARG
loadmcX - Load CW preset X. ARG
loadmvX - Load VOICE preset X. ARG
lowcut N 25 - 800 Set VOICE low-cut filter. ARG
mallsd - Return number of tapes and tracks on SD card. ACTION
mcurtrack - Show current track index and name. ACTION
mcX2d N 0 / 1 - 25 Set CW preset X 2D delay. ARG
mcX3d N 0 / 1 - 10 Set CW preset X 3D depth. ARG
mcXbw 25 - 1000 Set CW preset X BPF bandwidth. ARG
mcXcf 400 - 900 Set CW preset X BPF center frequency. ARG
mcXslope N 0 - 3 Set CW preset X filter slope. ARG
mode N 0, 1 Set VOICE/CW mode. ARG
mpbal N -100 / 100 MP3 stereo balance. ARG
mpvol N 0 - 100 MP3 DAC volume. ARG
mute/unmute - Mute/unmute audio. ON/OFF
mvXhicut N 1200 - 10500 Set VOICE preset X Hi-cut. ARG
mvXlowcut N 25 - 800 Set VOICE preset X low-cut. ARG
mvXnragres N 1.0 - 10.0 Set VOICE preset X NR aggressiveness. ARG
mvXnron/off - VOICE preset X NR ON/OFF. ON/OFF
mvXslope N 0 - 3 Set VOICE preset X filter slope. ARG
mvXvas 0 / 1 VOICE preset X VAS. ON/OFF
next - Go to next track in active list. ACTION
nr N 1.0 - 10.0 Set Noise Reduction aggressiveness. ARG
nron/nroff - Noise Reduction live ON/OFF. ON/OFF
pause - Pause/resume playback (Toggle). ACTION
play - Play/resume current track. ACTION
prev - Go to previous track in active list. ACTION
repeat N 0, 1, 2 Set repeat mode (0=OFF, 1=Track, 2=All). ARG
shuffle N 0, 1 Enable/disable shuffle playback. ON/OFF
stop - Stop playback and reset position. ACTION
table - Show number of tracks in active playlist. ACTION
savetomem N 1 - 3 Save current live settings. ARG
scrbr N 0 - 100 Set LCD brightness. ARG
setdate dd.mm.yy Set RTC date. ARG
settime hh:mm:ss Set RTC time. ARG
slope N 0, 1, 2, 3 Set VOICE live filter slope. ARG
theme N 0 / 1 / 3 Change theme. ARG
time - Show local and UTC date/time. ACTION
timezone N -12 - 14 Set UTC offset. ARG
tonetest M off/l/r/both Activate 1kHz test tone. ARG
usercw - Return to manual CW live. ACTION
uservoice - Return to manual VOICE live. ACTION
vashang N 50 - 2000 Set VAS hang time. ARG
vasoff - Disable VAS live. ACTION
vason - Enable VAS live. ACTION
vaswin N 0.001 - 0.5 Set VAS detection threshold. ARG
voice - Enable VOICE live mode. ACTION
vol/gain N 0 - 100 Set unified audio volume. ARG
--------------------------------------------------------------------------------The detailed explanation of the commands can be found on the HaM5dsp project’s GitHub page.



