Why a beat in AM ? [incorrect IQ offset]

edited May 2017 in Problems Now Fixed

Normally, in AM, there is no BFO (at least with a "real" receiver, nor in most SDR receivers). But KiwiSDR has a beat frequency (woooooooo) as soon as we are not tuned exactly on the carrier of an AM station, showing that a sort of BFO is in use.
Why ?

Best regards


  • edited May 2017
    I don't experience that here. 

    Try listening on my station  http://rx.jimlill.com:8073 [jks edit: URL fixed]
  • >Adresse introuvable
    Not found
  • Hi J-Luc,

    It may be that your SDR I/Q balance has been disturbed. I have had this happen to me when a user adjusted it incorrectly.

    Open up the IQ_Display extension.

    Set the IQ gain to about 80dB.

    Disconnect the antenna at the SDR so that no signals are being received.

    Press the yellow IQ bal button.

    Reconnect you antenna and all should now be OK.

    John - maybe the balance control should only be available to Admins ?


    Martin - G8JNJ

  • jksjks
    edited May 2017
    Yes, this is a case of the "IQ bal" button on the IQ display having been pushed when receiving an unbalanced signal (e.g. not set to a quiet part of the band).
    Previous discussions:

    The button has never changed the balance unless you are an administrator since this is essentially a configuration setting. Several releases ago I made the button do nothing at all because too many admins were pressing it without really understanding what it did (and getting a beat tone in AM mode as a result). But I realize now what I should also have done is added code to reset the I and Q offsets to 0.05, which experience has shown to be an adequate value for all Kiwis. This would remedy the case of the IQ being out of balance before I nullified the button (I think that's the case here).

    Or you could make the argument I should leave the button active but add a confirmation dialog with a stern warning about its use so that a Kiwi that happens to require IQ balance other than 0.05/0.05 could be accommodated. The button is on the IQ display, instead of the admin page, because it's important to see that the IQ balance is visually correct before setting it (i.e. the noise pattern from being in a quiet part of the band is centered at the origin of the crosshairs).

  • Hi John

    I think I'd prefer it to remain an admin only option but with an extra confirmation dialog.


    Martin - G8JNJ
  • Ok. I never touched this but I will try. Need to learn all the mecanisms :-)
  • Well, if you're sure you've never pushed the button then that's another story. To double check bring up the "log" tab on the admin page. In the top section of messages look for one that says: INIT DC_offset: I 0.05 Q 0.05

    If it says that, but you are getting a tone when offset on an AM station, then I would very much like to understand why. If the Kiwi could be made publicly available so I could connect and take a look that would be very helpful.

  • The DC offsets are far too high, -5/-2 maybe the button has been clicked one day :-/
    Nevetheless, I will need to go on site to unplug the antenna to have the RX quiet while reseting the IQ as this is not easy to do remotely :-))).
  • >with an extra confirmation dialog

    Hem hem... yes :-) good idea.
  • perhaps you can tune to some quiet freq up near 30 MHz for the time being
  • You will have the problem with AM when the I and Q offset values are very different and if you go to the IQ display extension, adjust the gain and see that the pattern is offset from the crosshair origin.

    As a stopgap it is possible to edit the configuration file by hand and restart the server. Login to the Beagle as root, "cd kiwi.config", then run a text editor you're familiar with (such as "nano") and edit the file "kiwi.json". Change the values so they look like this:


    The file is one very long line. So you and your editor have to be able to deal with that. Be very careful not to change the file in any other way. Do a "cdp", "ku" to restart the server.

    Jim, no, the point is the button has been disabled for a while now. So he can't fix his current problem by following the old IQ adjustment procedure.

  • if he could ssh in could he do it? I have my systems here such that I can ssh into them.
  • edited May 2017
    I will SSH when I will be on the same network. Remotely only the port 8073 is open. Thanks for your help. :-)
  • The operation is planned for this WE, also the PLC (CPL in french) adapters will be removed from the house, they make too much broadband noise. I will use an ethernet to wifi client to connect the KiWi to the WiFi. :-).
  • edited May 2017
    Hi there,

    I have spent this afternoon in a reorganisation of the network in my parent's house :-)

    - I have moved the modem-router up to the first floor
    - I have removed the $%@# PLC couplers from all the house, put an ethernet-to-wifi little box to connect the Kiwi to the internet. The Kiwi is in the attic. The GPS antenna in on the roof, outside :-)
    - The noise floor is now a lot better, the wideband spikes have disapeared

    But :

    - I was unable to connect to Kiwi by using SSH : after answering "root" to the "log-in" question, it has always asked for a password. But normally there is no password. I was unable to reset the I/Q compensations.:-((( . A button in the "admin" interface would do the job.

    - I find the kiwi laking sensitivity in the 20, 40m ham bands. Could this come from very strong signals in long waves (France Inter 162KHz)... ?


    J-Luc F1JEK

  • did you try ssh root@<yourip>   or just ssh <yourip>

  • edited May 2017
    Using PuTTY : ipaddress is enough. Then log-in and password (or not). I use this tool everyday for other Linux systems.

  • try using debian as the user and then temppwd as PW
  • Ouaouh... will try next week when I will come back at the Kiwi's house :-)
  • Nobody else having an issue on this ?
  • I think v1.85 fixes this
  • :-) in fact the 1.86 seems to have reset the I/Q offsets so I will no need to connect as root. Coooool !
  • Hi John,

    The I/Q balance has drifted on one of my SDR's and I'm hearing hetrodynes at about -20dB on AM BC stations if they are slightly offtune.

    The current method of adjustment is a real pain :-(

    Please could the original method (with some safeguards) be reinstated ?


    Martin - G8JNJ

  • jksjks
    edited July 2017
    v1.104 brings back the "IQ balance" button on the IQ display extension. But this time with a confirmation dialog.

    But there is something else strange going on here. Some time ago I noticed that the default IQ offset (really DC offset) values needed to be constant (+0.05) for all Kiwis. There was some static offset someplace that was common to all Kiwis manufactured. But not like an analog DC offset that has to be measured and corrected individually for quadrature sampling SDRs. It's a fixed value that compensates for some other issue in the digital domain, like a rounding error or scaling error.

    But I've checked a bunch of Kiwis again and they all now seem to need -0.02 instead of +0.05 as the offset. I don't understand why this has changed. They can't all have "drifted" -0.07 all of a sudden to this new value. What has changed recently is the audio sample rate. We went from 9.6 kHz to 12 kHz. So maybe this has something to do with it.

  • Yeah, okay, this has something to do with the main FIR filter. You can see this if you haven't already corrected the offset. If you bring up the IQ display, select USB or LSB, then as soon as you slide the lower edge of the passband over the carrier position (0 Hz) the IQ will offset that small amount. In AM mode the default passband of course is centered at 0 Hz, so you see the problem straight away.

    The computation of the FIR filter coefficients depends on the sample rate. So that probably explains why the offset changed with the recent change in sample rate. This FIR filter is a fast convolution FFT filter taken from CuteSDR. So I'm going to have to study it and try and figure out what's wrong. The offset is quite small (but enough to cause AM carrier leak). 0.02 on the max IQ values of +/- 32k is about 0.6 ppm.

  • Hi John,

    Great thanks for doing this.

    The strange thing is that one of my KiWi's was OK but the other (older one) wasn't. I just assumed that something had drifted (perhaps with the heat) as it's been very hot (for the UK) for the past few weeks.


    Martin - G8JNJ
  • I checked my unit and found that the original 0.05 is still OK. It's been running for months but in a 22 deg C basement
  • You have to look using the right conditions to decide if the +0.05 value is resulting in correct operation or not. The difference on the IQ display between +0.05, -0.02 and no offset at all will be washed out unless the noise level is less than S3 on the S-meter in AMN. It's really best to disconnect the antenna to achieve this low level.

    I looked at your public Kiwi Jim and it's the same as all the others. The +0.05 value is no longer okay. It needs -0.02. Here's an example: Tune to 27.610 USB. The level should be just above S1. Select the IQ display extension. Increase the gain to about 96 dB. Note the noise pattern is centered on the crosshairs. Now select AMN and hit clear. The noise pattern will have shifted to the lower right quadrant. If you now hit IQ balance the corrections values shown will be around -0.06 which will take the offset to about -0.02 and the pattern in AMN will jump back to the center of the crosshairs.
  • edited July 2017
    Same for me. I have had exactly what you expected. It's corrected.

    On the console :
    cd /
    cd kiwi.config
    cat kiwi.json

    And I see : "DC_offset_I":-0.01963078,"DC_offset_Q":-0.019625889999999993"
Sign In or Register to comment.