Work on documentation

This commit is contained in:
Andreas Eversberg
2016-05-05 18:31:34 +02:00
parent 1ce67c14e9
commit ba91ee82a7
37 changed files with 1661 additions and 205 deletions

View File

@@ -1,39 +1,90 @@
<html>
<head>
<link href="style.css" rel="stylesheet" type="text/css" />
<title>osmocom-analog</title>
</head>
<body>
<center><table border='0' cellspacing='0' cellpadding='0' width='816'><tr><td><font face="ARIAL" size='5'>
<center><table><tr><td>
<h2><center>Radio setup</center></h2>
<p align='justify'>
To emulate a base station, you need a linux machine with sound interface. The interface must be supported by <a href="http://www.alsa-project.org">Alsa</a> kernel driver.
<center><img src="setup.jpg"/></center>
<p>
The main idea of this project is to use a sound adapter to generate and analyze FM modulated signals.
Only a transmitter and a receiver is required.
All signal processing is done in software.
The software is written for Linux.
So the first thing you need is PC with a sound adapter.
This software uses <a href="http://www.alsa-project.org">Alsa</a> kernel driver to access audio input and output.
</p>
<center><img src="pc+sound.jpg"/></center>
<p align='justify'>
Use a radio transmitter for 2-meter band to transmit to the phone (downlink).
An amateur radio can be used, but be sure it is not limited to amateur radio frequencies.
<p>
Use a radio transmitter for 2-meter band to transmit to A-Netz or B-Netz phones.
Use a radio transmitter for 70-cm band to transmit to C-Netz or NMT phones.
An amateur radio can be used, but be sure it is not limited to amateur radio frequencies and channel rasters.
For A-Netz the transmitter must be able to transmit arround 162 MHz.
For B-Netz the transmitter must be able to transmit arround 153 MHz.
For C-Netz the transmitter must be able to transmit arround 465 MHz.
For NMT the transmitter must be able to transmit arround 463 MHz.
</p>
<p>
This image shows a two-band amateur radio receiver without limitations for the frequencies above:
</p>
<center><img src="transmitter.jpg"/></center>
<p align='justify'>
Use radio receiver for 2-methers band to receive from the phone. (uplink)
You cannot use the transmitter as well, since you need to transmit and receive simultaniously.
<p>
I built several transmitters out of modified taxi radios.
It features a simple digital PLL (configurable by junpers) and allows to directly connect the audio signal to the oscillator.
This is highly recommended for the C-Netz, because signalling is done by sifting the carrier directly.
One unit has a switch to change between A-Netz and B-Netz (2-meter version) and the other units to change between C-Netz and NMT (70-cm version).
I added an input to switch between two channels for the B-Netz.
(Whenever a B-Netz phone is paged, the channel must be temporarily switched to the paging channel.)
</p>
<center><img src="transmitter2.jpg"/></center>
<p>
Use radio receiver for 2-meter band to receive from A-Netz or B-Netz phones.
Use radio receiver for 70-cm band to receive from C-Netz or NMT phones.
The transmitter cannot be re-usedr, because all networks are full duplex.
A seperate radio is required to simultaniously transmit and receive.
For A-Netz the receiver must be able to receive arround 162 MHz and 157 MHz.
For B-Netz the receiver must be able to receive arround 153 MHz and 148 MHz.
The reason why the receiver must also receive on the transmitter frequency (downlink) is because you need to make a test loop for calibration process.
This is explained below.
For C-Netz the receiver must be able to receive arround 465 MHz and 455 MHz.
For NMT the receiver must be able to receive arround 463 MHz and 453 MHz.
The receiver must support both uplink and downlink frequencies, to make a test loop for the calibration process.
</p>
<p>
This image shows a two-band amateur radio receiver that supports all the frequencies:
(It is not sufficient for C-Netz, because it distorts the signal too much.)
</p>
<center><img src="receiver.jpg"/></center>
<p align='justify'>
<p>
The best solution I could find for low price is the Uniden UBC360CLT.
It is actually some kind of clock radio with scanner.
It supports all relevant bands up to about 950 MHz.
In all bands the channel raster is freely selectable.
Up to 300 channels can be stored and simply selected by using up/down keys.
</p>
<center><img src="receiver2.jpg"/></center>
<p>
I added a discriminator output to the radio, to get undistorted receive signal.
This is highly recommended for the C-Netz, because signalling is done by sifting the carrier directly.
</p>
<center><img src="discriminator.jpg"/></center>
<p>
In order to keep RF emission low, use a dummy load for lab test.
Use two seperated antennas for outside use of the mobile phone.
Connect one dummy load to the transmitter and another one to the mobile phone's antenna connector.
@@ -41,104 +92,77 @@ Connect one dummy load to the transmitter and another one to the mobile phone's
<center><img src="dummyload.jpg"/></center>
<p align='justify'>
For the radios and the phone, I use a sufficient power supply.
Especially for old A-Netz phones, be sure to have something close to 13.8 Volts and 5 Ampere or even more, depending on your phone.
My phone did not work correctly with a standard 12 Volts regulated power supply.
Amateur radio power supplies are made for 13.8 Volts.
Also you can use a fully charged car battery with a sufficient fuse.
In my case I use a modified ATX-2 power supply with 13.8 Volts and a built-in overcurrent protection.
<p>
For the radios and the phone, you nee a sufficient power supply.
Especially for old A-Netz phones, be sure to have something strong with 10 Ampere or even more, depending on your phone.
My phone did not work correctly with a 5 Ampere 12 Volts regulated power supply.
I suggest to use an amateur radio power supply with low ripple.
In my case I use modified ATX-2 power supply for 12 or 13.8 Volts.
The voltage can be adjusted in most power supplies, but 12 Volts is good enough.
These power supplies have built-in overcurrent/overvoltage protection.
The ATX-2 power supplies are regulated on the 12 Volts rail.
I added two plugs and a switch.
The switch connects to the PS-On line.
In case of an overcurrent, the switch can be used to reset the protection circuit.
Note that opening a switching power supply can be dangerous and may cause death.
If you don't have the knowledge about power supplies, ask an expert to help you.
</p>
<center><img src="power.jpg"/></center>
<p align='justify'>
<p>
Early tests were done without any wireing between radios and sound adapter.
This may worked for early tests with the B-Netz, but turned out to be a pain in the as.
It is not possible to keep the levels and avoid feedbacks.
</p>
<center><img src="headphone.jpg"/><img src="microphone.jpg"/></center>
<p>
The sound adapter must be connected to a transmitter and a receiver.
Coils are suggested for galvanic seperation.
I don't use coils, instead I add extra grounding wire between earth (power supply) and sound interface.
For adjustemnt I highly recommend to use variable resistors.
This makes the adjustment process faster.
I use 4.7 K resistor for connecting headphone output to radio input.
I use 10 K resistor for connecting radio output (discriminator) to microphone input.
</p>
<center><img src="poti.gif"/></center>
<p>
Connect the ground of input and output to one end of the resistor. (shown in the picture as 'Masse')
Select this side to which the slider moves, if the knob turned all the way left (or moved all the way down).
Connect the input signal ('Signaleingang') to the other end of the resistor.
At least connect the output signal ('Signalausgang') to the slider of the resistor.
</p>
<p>
During development process, I ended up like this:
</p>
<center><img src="chaos.jpg"/></center>
<p>
After figuring out how everything works, I decided to build a small box with knobs on the front and 3.5mm audio jacks in the back.
It allows to connect two radio transmitters and two radio receives to one stereo sound card.
Also it has a banana plug to ground the box.
</p>
<center><img src="stellwerk.jpg"/></center>
<p>
And finally you need a classic working phone.
Be sure to connect the phone to a dummy load and the transmitter to another one.
Be sure to connect the phone to a dummy load too.
Place both dummy loads (transmitter and phone) close together (several centimeters).
Put an antenna on the receiver.
If your phone has built in antenna and cannot be connected to a dummy load (C-Netz / NMT), stay a few meters away from transmitter (dummy load) and receiver.
</p>
<center><img src="b-netz-display.jpg"/></center>
<p align='justify'>
There are two ways to couple the receiver and transmitter with your sound card. You can use a headset and a microphone. The pro is that you can monitor what you actually transmitting and receiving. The problem is that you might get audio from RX side mixed with TX side. You get echo and the base station may detect self-generated tones. This might cause malfuntion to the base station software. Better you put the microphone inside a headset and keep TX and RX side away from each other.
</p>
<center><img src="microphone.jpg"/></center>
<p align='justify'>
The better way is to use inductive coil and resistors.
How to couple your sound card with radios is beyond the scope of this document.
Because you have radios and all the electronics that is required, I assume you have the knowledge to do it right.
</p>
<center><img src="coil.jpg"/></center>
<p align='justify'>
To adjust input and output levels of your sound card, run 'alsamixer'.
</p>
<center><img src="alsa.png"/></center>
<p align='justify'>
To avoid echo of audio input (mic), mute the input (select item and press 'm').
We want to capture microphone, but not echo it back to the audio output.
Also we want audio on line/headset output and capture from microphone imput.
</p>
<p align='justify'>
Now we want to calibrate transmitter and receiver audio level.
Run the B-Netz base station in loopback test mode (-L 2).
Even if you plan to setup A-Netz base station, use B-Netz base station for calibration.
</p>
<font size='4'><pre>
# src/bnetz/bnetz -k 1 -L 2
bnetz.c:268 info : Entering IDLE state, sending 'Gruppenfreisignal' 2 on channel 1.
Base station ready, please tune transmitter to 153.010 MHz and receiver to 148.410 MHz.
To call phone, switch transmitter using pilot tone to 153.370 MHz
</pre></font>
<p align='justify'>
Tune your transmitter AND reciever to 153.010 MHz.
Press the PTT button on you transmitter and check if you hear your voice at a normal level from the receiver.
Then connect the audio output (line out) to your transmitter or couple it with a headphone.
You should hear now the whistle sound clearly on the receiver.
Adjust the audio output, so that the tone is not overdriven but loud enough to match any regular received voice.
</p>
<p align='justify'>
Now connect the audio input (microphone) to your receiver or couple it with a microphone to the speaker of your receiver.
Enable the transmitter. (PTT button)
You should now see the signal beeing decoded by the base station:
</p>
<font size='4'><pre>
bnetz.c:474 notice : Received telegramm 'Ziffer 2'. (quality=99% level=33%)
bnetz.c:478 notice : Round trip delay is 0.053 seconds
bnetz.c:474 notice : Received telegramm 'Ziffer 3'. (quality=98% level=33%)
bnetz.c:478 notice : Round trip delay is 0.054 seconds
bnetz.c:474 notice : Received telegramm 'Ziffer 4'. (quality=99% level=31%)
bnetz.c:478 notice : Round trip delay is 0.053 seconds
bnetz.c:474 notice : Received telegramm 'Ziffer 5'. (quality=97% level=30%)
bnetz.c:478 notice : Round trip delay is 0.054 seconds
</pre></font>
<p align='justify'>
Adjust the input level. (using 'alsamixer')
Try to maintain an input level arround 30%.
The quality should be 90% or better.
</p>
<p align='justify'>
Now you have connected the base station to your radio eqipment and roughly adjusted the levels.
</p>
<p align='justify'>
Finally store the settings using "alsactl store" command.
Do this whenever you want to keep your adjustments.
</p>
[<a href="index.html">Back to main page</a>]
</font></td></tr></table></center>
</td></tr></table></center>
</body>
</html>