bg3mdo / pisdr_hat

This is budget Raspberry Pi SDR project.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

pisdr_hat

This is a budget Raspberry Pi SDR project by Yuan Wang (BG3MDO)

2021 Easter holiday project Apr 5, 2021 (first upload V0.01)

The aim is to make a cheaper PI HAT to do HF/6m band SDR TRX, while using Raspberry Pi to do the digital signal processing (DSP).

Frequency range: 3.2MHz to 58MHz, in this range, Si5351 can produce good 90-degree I Q signals. It can go down to 500k-1.5MHz where is used to receive MW band radios - VCO phase will not meet 90 degrees, but it is okay for demod AM signals.

Currently, it uses Quisk to process signals.

I have Quisk configuration files (Python scripts) attached.

Set up:

  • Raspberray Pi official OS installed
  • Raspberray Pi 4 with PI SDR HAT pluged in - this project PCB
  • Install Quisk, and setup using the attached configuration Python scrips
  • Extra CM108 USB sound card for speaker and micphone

Quisk install can be as easy as using:

sudo pip3 install quisk

Quisk uses wxpython, you might need to install the following to compile wxpython:

sudo apt install libjpeg-dev libtiff5-dev libnotify-dev libgtk2.0-dev libgtk-3-dev libsdl1.2-dev libgstreamer-plugins-base0.10-dev libwebkitgtk-dev freeglut3 freeglut3-dev

Then:

sudo pip3 install wxpython

you also need this:

sudo apt install libfftw3-dev

Sound card configurations:

Uninstall Pluseaudio, and fallback to alsa sound layer using
sudo apt remove pluseaudio

/boot/config.txt adding the following statements to enable i2c/i2s/i2s-mmap and wm8731 device tree for Linux

dtparam=i2c_arm=on
dtparam=i2s=on
dtoverlay=i2s-mmap
dtoverlay=audioinjector-wm8731-audio

You might use alsamixer to setting wm8731, enable input and adjust gains. Max. bandwidth is 96K.

To do list:

  • Fix Quisk frequency offset issue, this is due to sound card crystal osc is not accurate.
  • I Q need to be balanced, new HW design?
  • Modify Linux kernel to overclock audio codec to do more bandwidth?
  • Adding RF gain stage? or ATT stage?
  • Adding VHF/UHF RX by placing a TV dongle silicon tuner - still using I2C bus to control?
  • Adding VHF/UHF TX by adding AX5043/ADF7021 to produce a pure carrier, or maybe ADF4351? and a mixer, for example SA612, to do upconverter?

13/04 2021 update (V0.02):

  • swap the audio output from line out to headphone output so alsamixer can control the TX I Q level -- yes, new PCB needed.
  • carefully tuning the DAC (mixer bias) to get better DC offset (mine DAC I mcp4725 value to 1500, Q mcp4725 value to 1900)
  • reduce the mixer cap from 47nF to 10nF (better using NPO caps), giving better 96k bandwidth, also reduce the I Q unbalance
  • increase the RX OPA gain (Rf from 10k to 33k), and reduce feedback cap to flat bandwidth (1.5nF to 47pF)
  • found I Q swapped, change the code
  • wm8731 causes 300Hz offset (should be 12.288/128 = 96k), so change sound wm8731 to a 12.288MHz TCXO (cheaper one, for example 25ppm, is good enough - to get 12.288 is important, a lot of 12.28 crystal on the market)

This project idea is based many hams' SDR projects, this is a combine and development of current ideas, thanks to different contributors in this area.

This project will follow CC BY-SA4 license, you are free to use and modify to fit your idea in.

More to follow, many thanks, DE BG3MDO

About

This is budget Raspberry Pi SDR project.


Languages

Language:Python 100.0%