From matthew.quirke at gmail.com Thu Feb 7 23:48:59 2019 From: matthew.quirke at gmail.com (matthew quirke) Date: Fri, 08 Feb 2019 12:48:59 +1300 Subject: FL2K replace MT34TL/AS11D buck chip with LDO Message-ID: <1549583339.9044.4.camel@gmail.com> Has anyone tried replacing the MT34TL/AS11D buck converter/supply chip?with a LDO regulator as Steve Markgraf suggested - my goal is to remove the harmonics, for HF tx. The?MT34TL/AS11D(xx) datasheet is available online so it seems very do- able - just considering all the pitfalls - issues/ obvious things I missed ;) Any input/advice is much appreciated. -Matt From 246tnt at gmail.com Fri Feb 8 06:59:25 2019 From: 246tnt at gmail.com (Sylvain Munaut) Date: Fri, 8 Feb 2019 07:59:25 +0100 Subject: FL2K replace MT34TL/AS11D buck chip with LDO In-Reply-To: <1549583339.9044.4.camel@gmail.com> References: <1549583339.9044.4.camel@gmail.com> Message-ID: Hi, > Has anyone tried replacing the MT34TL/AS11D buck converter/supply > chip with a LDO regulator as Steve Markgraf suggested - my goal is to > remove the harmonics, for HF tx. Remove the harmonics ? The fl2k will always have harmonics, that's just the way it is. Only way to get rid of theses is to post-filter. What a clean supply does is remove the spurs. Cheers, Sylvain From mueller at kit.edu Fri Feb 8 12:02:10 2019 From: mueller at kit.edu (=?utf-8?B?TcO8bGxlciwgTWFyY3VzIChDRUwp?=) Date: Fri, 8 Feb 2019 12:02:10 +0000 Subject: FL2K replace MT34TL/AS11D buck chip with LDO In-Reply-To: References: <1549583339.9044.4.camel@gmail.com> Message-ID: <6794685e1b08d08befc1de58d6a67e477c943ace.camel@kit.edu> I'd like to expand on that: the fl2k is just a DAC without reconstruction filtering. Like every DAC without a filter, harmonics mathematically must exist. That's not a bug or something due to imperfect design ? that's just the theory behind DAC; especially: has nothing to do with the power supply :) In essence, you can think of a (perfect?) DAC as something that produces a series of extremely sharp impulses of the correct amplitude at sampling rate, with zero in between. So, let's imagine these amplitudes would form a nice cosine of say 20 MHz if you "connected the dots" ? but you don't do that connecting electrically just yet. * * * | | * +--*---+---|---|---+---*---+---|---|---+---*-- ? * * | | * * * ^ ^ |____________ T=1/(20MHz) _____________| When you think of the spectrum of that, I'd say we both agree that there's power at 20 MHz, so obviously the PSD must have a peak at 20 MHz. But hey, if this was *actually* a sine of 20 MHz, then there would be "smooth" connections between the signal impulses (the "*" in my ASCII drawing). There are not; so, there must also be a signal component which "suppresses" the 20 MHz sine in between. Whilst there's fine math theory which lets us derive this directly, I simply imagine there being 1-0-1-0? wave that I multiply with the "pure" sine to arrive there ? first one of twice the sampling rate, to "zero out" the middle between amplitude instants, then another one with higher multiples of the sampling rate and so on. As someone dealing with HF, you probably know what happens when I multiply one sine with a wave of a different frequency: You mix one tone by the other. And that's exactly what you'll see at the output of *every* DAC: the spectrum you produced in the baseband, and a repetition every sampling rate distance. These repetitions are fittingly called /images/, and you often (and you, especially, in this case) suppress them with a simple low-pass filter. The effect of that /reconstruction/ filter is that it actually smooths out these impulses ? it "connects the dots"! Good thing is that the sampling rate of the fl2k is plenty high enough to cover your HF band at once ? you don't need to rely on this imaging to get to any portion of that band. In case you haven't seen that, the fact that imaging exists is even useful: By selecting an image that is far above the baseband, you can, with a DAC that has ~160 MHz sampling rate, even generate signals in the 900 MHz GSM band, for example, without any mixer. So, what you need is a filter with a cutoff frequency above HF and below half your sampling rate. By the way, power supply effects *can* lead to harmonics, but usually in amplifiers: when your power supply is insufficient for your amplifier, then that amplifier can't reach high amplitudes as fast as it should ? that's a nonlinearity. Nonlinearities lead to mixing, i.e. harmonics. My suspicion is that you meant "spurs", not "harmonics", caused by the buck converter. You're referring to http://people.osmocom.org/steve-m/fl2k_slides/osmo-fl2k.html#(17) ,right? Well, in fact, these seem to be harmonics, but my best guess it's they're harmonics of the boost switching clock, mixed with the signal of interest, not of your signal itself. We typically refer to tones that aren't harmonics of the signal of interest but are generated within a device as spurs. Anyway, that's just semantics, in the end. You want to get rid of them; first, make sure you actually need to do that - they are present in 1 MHz steps, as it seems on that slide above, so chances are that if you choose your rates cleverly, you can avoid seeing them in-band at all. Before replacing any complete buck converter, I'd try to uppen its output smoothening: find the large output caps after the inductors, and parallel/on top solder another 10?F; follow the positive voltage trace and solder a good 10nF onto where that connects to the fl2k; connect a very solid wire to ground to the other end. Maybe that's already sufficient at surpressing things. Best regards, Marcus ----------------------------------------------------------------------- ? "real" DACs often work slightly different, e.g. do zero-order hold or such, but that doesn't actually matter for the principle of images ? what matters is that the "difference" between the "pure" smooth signal and the DAC's output has frequency components at multiples of the sampling rate. On Fri, 2019-02-08 at 07:59 +0100, Sylvain Munaut wrote: > Hi, > > > Has anyone tried replacing the MT34TL/AS11D buck converter/supply > > chip with a LDO regulator as Steve Markgraf suggested - my goal is to > > remove the harmonics, for HF tx. > > Remove the harmonics ? The fl2k will always have harmonics, that's > just the way it is. Only way to get rid of theses is to post-filter. > What a clean supply does is remove the spurs. > > Cheers, > > Sylvain -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/x-pkcs7-signature Size: 6582 bytes Desc: not available URL: From makrisj at gmail.com Fri Feb 8 18:47:08 2019 From: makrisj at gmail.com (Ioannis Makris) Date: Fri, 8 Feb 2019 20:47:08 +0200 Subject: FL2K replace MT34TL/AS11D buck chip with LDO Message-ID: I have managed to replace both buck DC-DC converters with AMS1117 3.3 & lm317 linear regulators and I successfully got rid of the mentioned 1 MHz buck converter clock to obtain as pure a signal as possible. Do not expect miracles as the DAC's are 8-bit and have a best case SNR of -48dB, but getting the sideband modulation out of the signal surely improves the resulting spectrum a lot. I have performed the mod on 4 fl2k adapters. Two of them came with a 1.2V AMS1117 for the 1.2V and a buck psu for the 3.3V. Another two came with 2 buck psu's Using 2 LM317 is a bit complex but can be done, as my proof of concept testbed has demostrated. One could actually fit them inside the plastic box. Mind you, linear regulators can get quite hot. Still not hot enough to inflict any damage after a 8-hour operation of the device. Another notable effect was the total elimination of "cb status 1" message on the testbed. The testbed suffered a lot of USB connection drops due to poor power delivery to the chip, which is also the plague of those devices that is causing bad reviews along with the poor assembly of the cable from those that use the device in regular vga output mode. The workaround is extremely simple; we use the onboard capacitors for filtering the output of the linear regulators, I install them inverted and add metal pins from 1/4W resistors to patch the power from the pin of the buck chip to the input of the linear regulator. Same with ground. Of course we are using USB3 interface that can provide more than 2.5W (500mA) of output power. I haven't thorougly tested device operation and stability under USB2.0 which has the aforementioned power limiting. The device looks stable though. There are implementations utilizing a pair of AMS1117 from factory. [image: 20190125_194224_001.jpg] -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: 20190125_194224_001.jpg Type: image/jpeg Size: 239036 bytes Desc: not available URL: From matthew.quirke at gmail.com Fri Feb 8 18:53:43 2019 From: matthew.quirke at gmail.com (Matthew Quirke) Date: Sat, 9 Feb 2019 07:53:43 +1300 Subject: FL2K replace MT34TL/AS11D buck chip with LDO In-Reply-To: <6794685e1b08d08befc1de58d6a67e477c943ace.camel@kit.edu> References: <1549583339.9044.4.camel@gmail.com> <6794685e1b08d08befc1de58d6a67e477c943ace.camel@kit.edu> Message-ID: Hi Marcus, thanks for your input, Yes my bad? I was referring to these ?spurs? which seem to be modulation products AND harmonics of the switching frequency of the buck converter ( @ 1.1Mhz ) - As Steve sugged in his video - here @ [22min.22s] for clarification. https://www.youtube.com/watch?v=VRvLVjLQSaw&t=1366s The LDO approach appeals to me to get rid of the most noise and I have a few suitable LDO?s sitting on my desk looking very bored. ;) On Sat, 9 Feb 2019 at 01:02, M?ller, Marcus (CEL) wrote: > I'd like to expand on that: the fl2k is just a DAC without > reconstruction filtering. Like every DAC without a filter, harmonics > mathematically must exist. That's not a bug or something due to > imperfect design ? that's just the theory behind DAC; especially: has > nothing to do with the power supply :) > > In essence, you can think of a (perfect?) DAC as something that > produces a series of extremely sharp impulses of the correct amplitude > at sampling rate, with zero in between. So, let's imagine these > amplitudes would form a nice cosine of say 20 MHz if you "connected the > dots" ? but you don't do that connecting electrically just yet. > > * * > * | | * > +--*---+---|---|---+---*---+---|---|---+---*-- ? > * * | | * > * * > ^ ^ > |____________ T=1/(20MHz) _____________| > > When you think of the spectrum of that, I'd say we both agree that > there's power at 20 MHz, so obviously the PSD must have a peak at 20 > MHz. But hey, if this was *actually* a sine of 20 MHz, then there would > be "smooth" connections between the signal impulses (the "*" in my > ASCII drawing). There are not; so, there must also be a signal > component which "suppresses" the 20 MHz sine in between. Whilst there's > fine math theory which lets us derive this directly, I simply imagine > there being 1-0-1-0? wave that I multiply with the "pure" sine to > arrive there ? first one of twice the sampling rate, to "zero out" the > middle between amplitude instants, then another one with higher > multiples of the sampling rate and so on. > > As someone dealing with HF, you probably know what happens when I > multiply one sine with a wave of a different frequency: You mix one > tone by the other. And that's exactly what you'll see at the output of > *every* DAC: the spectrum you produced in the baseband, and a > repetition every sampling rate distance. These repetitions are > fittingly called /images/, and you often (and you, especially, in this > case) suppress them with a simple low-pass filter. The effect of that > /reconstruction/ filter is that it actually smooths out these impulses > ? it "connects the dots"! > > Good thing is that the sampling rate of the fl2k is plenty high enough > to cover your HF band at once ? you don't need to rely on this imaging > to get to any portion of that band. In case you haven't seen that, the > fact that imaging exists is even useful: By selecting an image that is > far above the baseband, you can, with a DAC that has ~160 MHz sampling > rate, even generate signals in the 900 MHz GSM band, for example, > without any mixer. > > So, what you need is a filter with a cutoff frequency above HF and > below half your sampling rate. > > By the way, power supply effects *can* lead to harmonics, but usually > in amplifiers: when your power supply is insufficient for your > amplifier, then that amplifier can't reach high amplitudes as fast as > it should ? that's a nonlinearity. Nonlinearities lead to mixing, i.e. > harmonics. > > My suspicion is that you meant "spurs", not "harmonics", caused by the > buck converter. You're referring to > http://people.osmocom.org/steve-m/fl2k_slides/osmo-fl2k.html#(17) ,right? > Well, in fact, these seem to be harmonics, but my best guess it's > they're harmonics of the boost switching clock, mixed with the signal > of interest, not of your signal itself. We typically refer to tones > that aren't harmonics of the signal of interest but are generated > within a device as spurs. Anyway, that's just semantics, in the end. > You want to get rid of them; first, make sure you actually need to do > that - they are present in 1 MHz steps, as it seems on that slide > above, so chances are that if you choose your rates cleverly, you can > avoid seeing them in-band at all. > > Before replacing any complete buck converter, I'd try to uppen its > output smoothening: find the large output caps after the inductors, and > parallel/on top solder another 10?F; follow the positive voltage trace > and solder a good 10nF onto where that connects to the fl2k; connect a > very solid wire to ground to the other end. Maybe that's already > sufficient at surpressing things. > > Best regards, > Marcus > > ----------------------------------------------------------------------- > ? "real" DACs often work slightly different, e.g. do zero-order hold or > such, but that doesn't actually matter for the principle of images ? > what matters is that the "difference" between the "pure" smooth signal > and the DAC's output has frequency components at multiples of the > sampling rate. > > On Fri, 2019-02-08 at 07:59 +0100, Sylvain Munaut wrote: > > Hi, > > > > > Has anyone tried replacing the MT34TL/AS11D buck converter/supply > > > chip with a LDO regulator as Steve Markgraf suggested - my goal is to > > > remove the harmonics, for HF tx. > > > > Remove the harmonics ? The fl2k will always have harmonics, that's > > just the way it is. Only way to get rid of theses is to post-filter. > > What a clean supply does is remove the spurs. > > > > Cheers, > > > > Sylvain > -- *Matthew Quirke* New Zealand contact me: Matthew.quirke at gmail.com mobile:+64 022 185 77 22 Skype-me: matthew_quirke This message may be protected by a GnuPGP digital signature. For secure email communication please use my public PGPkey (matthew.quirke http://keyserver.ubuntu.com) -------------- next part -------------- An HTML attachment was scrubbed... URL: From 246tnt at gmail.com Fri Feb 8 18:54:47 2019 From: 246tnt at gmail.com (Sylvain Munaut) Date: Fri, 8 Feb 2019 19:54:47 +0100 Subject: FL2K replace MT34TL/AS11D buck chip with LDO In-Reply-To: References: Message-ID: Hi, I have managed to replace both buck DC-DC converters with AMS1117 3.3 & > lm317 linear regulators and I successfully got rid of the mentioned 1 MHz > buck converter clock to obtain as pure a signal as possible. Do not expect > miracles as the DAC's are 8-bit and have a best case SNR of -48dB, but > getting the sideband modulation out of the signal surely improves the > resulting spectrum a lot. > Well they might be 8 bits, but they're massively oversampled for HF, so with good filtering and noise shaping, you can get more SNR. Cheers, Sylvain -------------- next part -------------- An HTML attachment was scrubbed... URL: From makrisj at gmail.com Fri Feb 8 18:56:42 2019 From: makrisj at gmail.com (Ioannis Makris) Date: Fri, 8 Feb 2019 20:56:42 +0200 Subject: FL2K replace MT34TL/AS11D buck chip with LDO In-Reply-To: References: Message-ID: Thanks for the tip! On Fri, Feb 8, 2019, 20:54 Sylvain Munaut <246tnt at gmail.com> wrote: > Hi, > > I have managed to replace both buck DC-DC converters with AMS1117 3.3 & >> lm317 linear regulators and I successfully got rid of the mentioned 1 MHz >> buck converter clock to obtain as pure a signal as possible. Do not expect >> miracles as the DAC's are 8-bit and have a best case SNR of -48dB, but >> getting the sideband modulation out of the signal surely improves the >> resulting spectrum a lot. >> > > Well they might be 8 bits, but they're massively oversampled for HF, so > with good filtering and noise shaping, you can get more SNR. > > Cheers, > > Sylvain > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From amin at gilani.me Tue Feb 12 22:11:56 2019 From: amin at gilani.me (Amin Shah Gilani) Date: Wed, 13 Feb 2019 03:11:56 +0500 Subject: Bus error using rtl-sdr Message-ID: Hi I'm experiencing a "bus error" everytime rtl-sdr tries to interact with my SDR. Here's a sample: rtl_fm -f 1000000 Found 1 device(s): 0: Realtek, RTL2838UHIDIR, SN: 00000001 Using device 0: Generic RTL2832U OEM Found Rafael Micro R820T tuner Tuner gain set to automatic. [R82XX] PLL not locked! Tuned to 1252000 Hz. Oversampling input by: 42x. Oversampling output by: 1x. Buffer size: 8.13ms Exact sample rate is: 1008000.009613 Hz Allocating 15 zero-copy buffers Bus error I'm running Kali on a Raspberry Pi, and I've used the repository version, and compiled from source ? no change. The only thing that makes this error go away in `rtl_test` is to pass it the -S flag (forcing synchronous) flow. Does anyone have any idea how to fix this? If you'd like the Karma and would like to help solve this problem publicly for future users, Stack Overflow question continuously being updated is here: https://stackoverflow.com/questions/54657089/rtl-sdr-crashes-with-bus-error-when-running-rtl-tcp-or-rtl-test ?Amin Shah Gilani -------------- next part -------------- An HTML attachment was scrubbed... URL: From amin at gilani.me Wed Feb 13 01:21:56 2019 From: amin at gilani.me (Amin Shah Gilani) Date: Wed, 13 Feb 2019 06:21:56 +0500 Subject: Bus error using rtl-sdr In-Reply-To: References: Message-ID: It seems I've discovered a bug. I was helpfully pointed to another email in the mailing list complaining about zerocopy buffers ( https://www.mail-archive.com/osmocom-sdr at lists.osmocom.org/msg01204.html) Removing the `zerocopy` code fixed the problem for me. For the entire diff and more information, please see this answer: https://stackoverflow.com/a/54661092/3970701 I can confirm that this error exists on my platform and can provide ssh access for testing purposes. ?Amin Shah Gilani On Wed, Feb 13, 2019 at 3:11 AM Amin Shah Gilani wrote: > Hi > > I'm experiencing a "bus error" everytime rtl-sdr tries to interact with my > SDR. Here's a sample: > > rtl_fm -f 1000000 > Found 1 device(s): > 0: Realtek, RTL2838UHIDIR, SN: 00000001 > > Using device 0: Generic RTL2832U OEM > Found Rafael Micro R820T tuner > Tuner gain set to automatic. > [R82XX] PLL not locked! > Tuned to 1252000 Hz. > Oversampling input by: 42x. > Oversampling output by: 1x. > Buffer size: 8.13ms > Exact sample rate is: 1008000.009613 Hz > Allocating 15 zero-copy buffers > Bus error > > > I'm running Kali on a Raspberry Pi, and I've used the repository version, > and compiled from source ? no change. The only thing that makes this error > go away in `rtl_test` is to pass it the -S flag (forcing synchronous) flow. > > Does anyone have any idea how to fix this? > > If you'd like the Karma and would like to help solve this problem publicly > for future users, Stack Overflow question continuously being updated is > here: > > https://stackoverflow.com/questions/54657089/rtl-sdr-crashes-with-bus-error-when-running-rtl-tcp-or-rtl-test > > ?Amin Shah Gilani > -------------- next part -------------- An HTML attachment was scrubbed... URL: