Ham Radio Projectshttps://dl8scu.wordpress.com
Wed, 13 Dec 2017 00:33:42 +0000enhourly1http://wordpress.com/https://s2.wp.com/i/buttonw-com.pngHam Radio Projectshttps://dl8scu.wordpress.com
How is svxlink going…https://dl8scu.wordpress.com/2013/02/10/how-is-svxlink-going/
https://dl8scu.wordpress.com/2013/02/10/how-is-svxlink-going/#respondSun, 10 Feb 2013 15:34:58 +0000http://dl8scu.wordpress.com/?p=176]]>So far the svxlink on raspi is working stable. It runs several days without problems, no system lockup or svxlink crash.

There is however a problem with the behaviour of svxlink. Besides the “normal” audio delay, svxlink sometimes sits there and does nothing…

The squelch events stop to be processed and there is no audio output. After a few seconds svxlink seems to catch up an at least a short audio tail is send. After this, everything is back to normal for a few more minutes.

Looking at the cpu usage of svxlink with top, it appears that during those hangs the cpu usage drops down to idle level from the normally higher cpu level associated with processing audio.

I took some strace of the svxlink process during such events, but I’m not familiar with the code enough…

In meanwhile I’m working on the pre-/de-emphasis of the repeater to make echolink/announcements AND repeated audio to sound good.

A recent article on audio processing shows that even low delay audio processing can be done on the raspi (<= 10ms) ! Have a look at:

]]>https://dl8scu.wordpress.com/2013/02/10/how-is-svxlink-going/feed/0dl8scuAre you lucky? No USB to serial converter needed!https://dl8scu.wordpress.com/2013/02/10/are-you-lucky-no-usb-to-serial-converter-needed/
https://dl8scu.wordpress.com/2013/02/10/are-you-lucky-no-usb-to-serial-converter-needed/#commentsSun, 10 Feb 2013 15:01:24 +0000http://dl8scu.wordpress.com/?p=133]]>All model B-V2 (and model A) owners can set-up their svxlink system without the need of an external USB-2-serial converter. All raspi versions offer a built-in serial port, but only the data signals (RXD/TXD) are available on the GPIO header (see http://elinux.org/RPi_Low-level_peripherals). With the arrival of the version 2 boards things improved. A new connector P5 was introduced. It is right next to the extension header P1, but as shipped there are no pins equipped.

Of interest to us are the pins 5+6 (GPIO30+GPIO31). The chip on the raspi allows different mappings as can be found at http://elinux.org/RPi_BCM2835_GPIOs . As can be seen there, GPIO30+GPIO31 can be switch to be RTS0/CTS0 in mode “ALT3”.

To use the IO pins we first need to “free” the serial port for our usage. The default configuration of the linux image uses the built in serial port to dump kernel messages and as a way to log into your raspi.

From /boot/cmdline.txt we need to remove the following options:

console=ttyAMA0,115200 kgdboc=ttyAMA0,115200

We also need to stop the system to spin up a terminal on the serial port. For this we put the following statement in /etc/inittab into comment (add # in front of the line):

#T0:23:respawn:/sbin/getty -L ttyAMA0 115200

OK, the serial port is ours, but we still need a tool to switch the GPIO assignment.

# as pi user,
cd /home/pi
mkdir rpi-tools
cd rpi-tools/
# if you have not yet installed git, this must be done upfront
# see comments section below on how to do this
git clone https://github.com/rewolff/bw_rpi_tools.git
cd bw_rpi_tools/gpio
# depending on the version or status of the tools you might need to fix the Makefile
# see comments section below
make
sudo make install

We can now check the current pin assignment:

sudo gpio_list

To reassign the pins to the RTS/CTS function we use the following command:

Bingo. We can now use the built-in serial port in the svxlink configuration by referring to the device: /dev/ttyAMA0 . In svxlink.conf we use:

SERIAL_PORT=/dev/ttyAMA0

Until the advent of direct raspi GPIO support in svxlink above few lines will be of help.

WARNING: When connecting external circuitry to the raspi GPIO pins, please be reminded that the Raspberry Pi only support 3.3V signal level. So in the best interest of your raspi keep this in mind!

]]>https://dl8scu.wordpress.com/2013/02/10/are-you-lucky-no-usb-to-serial-converter-needed/feed/21dl8scuAre you up for a challenge… USB and raspihttps://dl8scu.wordpress.com/2013/02/10/are-you-up-for-a-challenge-usb-and-raspi/
https://dl8scu.wordpress.com/2013/02/10/are-you-up-for-a-challenge-usb-and-raspi/#respondSun, 10 Feb 2013 14:28:43 +0000http://dl8scu.wordpress.com/?p=108]]>Unfortunately, there is a variety of problems surrounding the USB ports on the Raspberry Pi.

Even after all the improvements that happened in the firmware over last months, there are still problems with various devices and their drivers.

I had problems with a FTDI USB-2-serial converter used for the svxlink TRX interface. It would lock up the raspberry after a few hours Similar converters based on other chips (using other drivers) appear to be more well behaved.

I will have to add a dedicated post for USB audio, but a similar situation exists with such devices. Many provide choppy audio.

For all above problems there seems to be solution, even though with some limitations…

The USB port speed can be restricted to USB1.1 speeds by adding a kernel command line option. To do this, edit /boot/cmdline.txt and add the following option INTO THE SAME LINE as all the existing options you will find there:

dwc_otg.speed=1

The downside seems to be with USB keyboards. If connected they seem to lock up. This was no issue for me, as I only connect to the system over the network… talking of which – the Ethernet network will also be limited by this change. The 12 Mpbs still provide enough bandwidth for full-duplex audio and an echolink connection

]]>https://dl8scu.wordpress.com/2013/02/10/are-you-up-for-a-challenge-usb-and-raspi/feed/0dl8scuInstalling svxlink trunk versionhttps://dl8scu.wordpress.com/2013/02/10/installing-svxlink-trunk-version/
https://dl8scu.wordpress.com/2013/02/10/installing-svxlink-trunk-version/#respondSun, 10 Feb 2013 14:08:11 +0000http://dl8scu.wordpress.com/?p=104]]>For the more ventures girls and guys there is also the possibility to install the development version of svxlink. In my limited testing there was no difference in behaviour between the released and the trunk version.

]]>https://dl8scu.wordpress.com/2013/02/10/installing-svxlink-trunk-version/feed/0dl8scuInstalling svxlinkhttps://dl8scu.wordpress.com/2013/02/10/installing-svxlink/
https://dl8scu.wordpress.com/2013/02/10/installing-svxlink/#commentsSun, 10 Feb 2013 13:58:37 +0000http://dl8scu.wordpress.com/?p=98]]>The basic description (in German language) can be found in the article by Stefan http://svxlink.de/?page_id=1606 as shown in an earlier post.

]]>https://dl8scu.wordpress.com/2013/02/10/installing-svxlink/feed/1dl8scuUpdating kernel and the firmwarehttps://dl8scu.wordpress.com/2013/02/10/updating-kernel-and-the-firmware/
https://dl8scu.wordpress.com/2013/02/10/updating-kernel-and-the-firmware/#respondSun, 10 Feb 2013 13:48:20 +0000http://dl8scu.wordpress.com/?p=87]]>Once the initial OS set-up is completed, we want to update the kernel and firmware. A description can be found at https://github.com/Hexxeh/rpi-update

A reboot will be required to activate the newly downloaded kernel & firmware.

]]>https://dl8scu.wordpress.com/2013/02/10/updating-kernel-and-the-firmware/feed/0dl8scusysinfo.shhttps://dl8scu.wordpress.com/2013/02/10/sysinfo-sh/
https://dl8scu.wordpress.com/2013/02/10/sysinfo-sh/#respondSun, 10 Feb 2013 13:39:02 +0000http://dl8scu.wordpress.com/?p=78]]>I haven’t posted any details on overclocking and firmware update yet, and before I do it is possibly a good idea to recommend adding the following script to your system (as can be found e.g. at http://youresuchageek.blogspot.de/2012/09/howto-raspberry-pi-openelec-on.html):

]]>https://dl8scu.wordpress.com/2013/02/10/sysinfo-sh/feed/0dl8scuMy raspi hardwarehttps://dl8scu.wordpress.com/2013/02/10/my-raspi-hardware/
https://dl8scu.wordpress.com/2013/02/10/my-raspi-hardware/#respondSun, 10 Feb 2013 13:25:12 +0000http://dl8scu.wordpress.com/?p=62]]>Just posting the initial OS install info, I thought it might be helpful to point out that there are three different hardware version of Raspberri Pi:

Model B, Version 1: This is the initial version. Several hundred thousand units got shipped. Model B is the better equipped version with an Ethernet port and 2 USB ports. This version was shipped with 256MB of RAM.

Model B Version 2: Improved version that replaced Version 1 in autumn 2012. A few shortcomings of the initial board got improved, e.g .USB port power fuses. It now comes with 512MB RAM. It also gained an additional IO connector called P5.

Model A: released in January 2013, this model comes without Ethernet and only has 1 USB port. The memory is 256MB. Main advantage is a significantly reduced power consumption (I haven’t checked, but some say about 1/3 of model B)

For my svxlink activities I started with the model B-V1, swiftly to be replaced with a model B-V2.

]]>https://dl8scu.wordpress.com/2013/02/10/my-raspi-hardware/feed/0dl8scuInitial Linux Installhttps://dl8scu.wordpress.com/2013/02/10/initial-linux-install/
https://dl8scu.wordpress.com/2013/02/10/initial-linux-install/#respondSun, 10 Feb 2013 13:09:52 +0000http://dl8scu.wordpress.com/?p=40]]>I used the “official” Rapspberri Pi Linux Distribution based on Debian, as can be downloaded at http://www.raspberrypi.org/downloads – look for the “Raspian wheezy” section.

A stripped down, RAM only, svxlink optimised OS image would be great, but to start with I decided to go for the best supported distribution. You’ll be able to find a nice description on how to get started on http://www.raspberrypi.org/archives/2892 – just click on the Quich Start Guide link to download the PDF.

I did all my setup without any keyboard or monitor installed. The image is pre-configured to start up a DHCP client to get an IP address automatically and it will also start an SSH server. So connectibg it to your home network and connecting power will be all you need to get started. You will need to know the IP address that was assigned to you raspi. A good place to search could be in your home router. Many routers allow on their configuration pages to check for the IP addresses that where handed out by the router. Use your favourite SSH client to log into the raspi. A good SSH client for windows is putty.

Below you can find my steps to setup the OS after the downloaded OS image was copied onto an SD card, the raspberry pi booted and login (some basic linux skills are required :

]]>https://dl8scu.wordpress.com/2013/02/10/initial-linux-install/feed/0dl8scuFirst Things First – Powerhttps://dl8scu.wordpress.com/2013/02/10/first-things-first-power/
https://dl8scu.wordpress.com/2013/02/10/first-things-first-power/#respondSun, 10 Feb 2013 12:22:34 +0000http://dl8scu.wordpress.com/?p=32]]>Many forum posts discuss stability problems of the raspi, especially with USB devices connected. The first thing one should check is the voltage as can be measured on the board between TP1 and TP2. Recommended Voltage is in the range of 4.75V-5.25V.