domenica 12 maggio 2019

Kenwood TS-480 SAT audio cable for digi modes


I'm a happy owner of the rig Kenwood TS-480SAT, I will share how I made the audio cable to interface the rig to a computer to work with digital modes like FT-8.

The minidin connector named DATA in the rig manual is basically the same as the old PS/2 cable for mouse or pc keyboard.
You can take an old keyboard and cut the cable on the keyboard side,
remove the outer sheath and the common sheild and then, with the help of a tester,
find which pin is connected to which internal cable, taking note of the colors.
for example, below is my case
PS/2 TS-480 audio data cable



PS/2 male connector - front view:
Pin 1 - yellow
Pin 2 - green
Pin 3 - blue
Pin 4 - red
Pin 5 - brown
Pin 6 - black





On the rig side:
Pin 1 - GND
Pin 2 - to pc speaker
Pin 6 - to pc microphone

Then we will take two male jack 3.5mm connectors:

To pc mic:

PS/2 TS-480 audio data cable

Pin 1 connected to PS/2 pin 6 (black cable in my case)
Pin 2 not connected
Pin 3 GND to PS/2 pin 1 (yellow) and outer sheild











To pc speaker:

PS/2 TS-480 audio data cable

Pin 1 connected to PS/2 pin 2 (green cable in my case)
Pin 2 not connected
Pin 3 GND to PS/2 pin 1 (yellow) and outer sheild










For your convenience you can label the two jack connectors and use an usb sound card, as you see in the pic below, to leave the native pc sound card free.



 Maybe you have to polish the PS/2 connector to fit in the rig.
PS/2 TS-480 audio data cable





giovedì 2 maggio 2019

RaspBRadio - A Raspberry Pi and RTL-SDR Based Boombox

Raspberry radio scanner from 0 to 1750MHz

Introduction:
I'm not a python developer, you will find a lot of "strange things" in the code cause it is copy-pasted here and there from the net... but it's working.
Please help improving the code.
Any question or comments will be accepted.
------------------------------------------------------------------
For this project I have used:

SHARP GF-450 H Boombox - only case, antenna, speakers and a red led remain in place
Raspberry Pi 3 Model B
Nooelec Nano 2
Nooelec Ham It Up v1.3 HF upconverter
TDA2822M audio amplifier - DON'T use PAM8403 cause it produces a lot of interference in HF
KY040 rotary switch
4x4 matrix keyboard
4 lines lcd display
i2c level shifter
various cables and connectors
------------------------------------------------------------------
Description:
As you can see from pics below, there are 4 rotary switch on the top of the radio, one, on the left, is the potentiometer directly attached to audio amplifier module that receive audio signal through jack-jack cable connected to raspberry.
Other 3 are the ky040 rotary switches, 1st is to go up and down in freq with 500Hz steps and if pushed decrease the squelch level, 2nd is with 5KHz steps and if pushed change demodulation, 3rd with 50KHz steps and if pushed raise the squelch level.
On the right there is a lever, is connected to the upconverter in the place of the original switch and plus select the antenna, the original stylus for frequency above 30MHz or an external antenna for frequency below 30MHz (when upconverted is turned on) with a BNC connector on the right side of the radio.
On the right side there is also power connector, i've just used original raspberry power adapter with a male-female generic dc plug in the middle of the cable cutted and soldered.
Power must reach raspberry, upconverter and audio amplifier.
On the front we can find the lcd, inside, where was the musicassette mechanics, connected to raspberry gpio through a i2c level shifter; and a 4x4 matrix keyboard.
On the back, just as a backup when wifi doesn't work, there is a rj45 female coming from raspberry.
Audio is also streamed on the network thorugh a vlc instance.
------------------------------------------------------------------
Usage:
use the ky040 to set frequency, squelch and demodulation as described above.
Press 'A' to enter a frequency manually then press '#' to confirm and exit the menu.
Press 'C' to enable upconverter then move on the right the lever switch on the top of the radio.
Press 'C' again to disable and move the lever on the left.
Press 'D' to set audio properties, in this menu you can press 1 or 2 to decrease or raise bass volume, 4 or 5 for middle, 7 or 8 for high, 3 or 6 for software volume, then press '#' to exit.
Press '*' to shutdown the system.
You can listen the audio streamed on the network using VLC and opening the network stream http://ip_address:8010
If you press the ky040 demodulation switch till "spyserver" appear on the display, you can connect to the radio with sdr#.
Open sdr#, set as souce "spy server" and point to spy://ip_address:5555/ ; the ip address of wifi and vpn is also shown on the display.
------------------------------------------------------------------
If you use the integrated wifi module, you will listen some noise coming out the speaker like a tick.
I observe that these ticks are related to the network usage, more bandwidth is used more noise is produced on the speaker. Issue is resolved disabling integrated wifi and using an usb wifi dongle.
------------------------------------------------------------------
Software requirements for running this python script are:
Raspbian OS updated
rtl_udp, rtl-sdr and spyserver ( check https://airspy.com/download/ )
pad4pi python libraries
cvlc from vlc suite
pulseaudio and alsamixer
wifi or lan configured(with or without openvpn) to use sdr# ( https://airspy.com/download/ )remotely.
------------------------------------------------------------------
Install:
Put the python script on /home/pi/RADIO/ directory, naming it ctrl_rtl.py , together with spyserver and spyserver.conf
Run: chmod +x ctrl_rtl.py; chmod +x spyserver
Edit spyserver.conf for your needs
To run it at startup add to /etc/rc.local the line:
su pi -c "sleep 20; nohup /home/pi/RADIO/ctrl_rtl.py &"
------------------------------------------------------------------
TBD:
- CW listening (and decoding? printing it on lcd?)
- RDS decoding when listening to BFM stations
- do something with 'B' key
- date and time display
- improve speed and stability
------------------------------------------------------------------

watch video below in fullscreen at 480p




raspberry ghettoblaster sdr radio scanner

raspberry ghettoblaster sdr radio scannerraspberry ghettoblaster sdr radio scanner


raspberry ghettoblaster sdr radio scanner

raspberry ghettoblaster sdr radio scannerraspberry ghettoblaster sdr radio scannerraspberry ghettoblaster sdr radio scannerraspberry ghettoblaster sdr radio scannerraspberry ghettoblaster sdr radio scanner