Heterodyne bat detector: shadow copies of calls at *half* the tuned frequency! - Page 1
Forum section: electronics / rf-microwave

author: jewelie
author_rank: Regular Contributor
timestamp: June 15, 2023, 08:37:11 pm
content: HiI've got a bit of a technical query in relation to heterodyne bat detectors. Although this isn't really RF, I hope this would still be considered appropriate here due to the heterodyne bit and the relevant expertise here?When using my completed Franzis Make Your Own Bat Detector kit (schematic and more info athttps://www.elektronik-labor.de/Lernpakete/Fledermaus.html) I sometimes detect a shadow/echo of bat echolocation sounds athalfthe actual bat echolocation call frequency.I've seen a reference to such issues in a wonderful and informative PDF "Notes for separating species on the NBMP Field Survey" (https://cdn.bats.org.uk/uploads/pdf/Notes-for-separating-species-on-Field-Survey.pdf)It mentions issues withharmonics; however, as I'm seeing a copy of the signal athalfthe bat call frequency rather thaninteger multiples, I don't imagine there's a way it can be a simple harmonic of the bat echolocation sound?That leaves what it callsSonic Echos, which I assume is the problem I have-"Sonic Echo: Some heterodyne detectors have a ‘sonic echo’ which means that, when they are tuned around 25kHz and pipistrelles are echolocating loudly close to the detector, pipistrelle sounds can also be heard at this frequency. This sound can potentially be confused with noctule/Leisler’s bat/serotine. The faster call repetition rate of pipistrelles can be used to distinguish this sound from big bat calls, but always tune up to around 50 kHz to check for the presence of pipistrelles when sounds are heard at 25 kHz."But I've hunted around and I can't otherwise find a reference to this concept of "Sonic Echo"?It's not clear to me from the description if this means audio/sound feedback (speaker to ultrasonic sensor - in which case adding an earphone socket would likely sort it) or if it's an issue internal to the electronics (such as an internal feedback or interference issue, or maybe due to harmonics of the square wave oscillator used in the heterodyning process causing additional echos of the echolocation sound over the frequency domain)?Can anyone shed some light on this?- JuliePS If needs be I will ask the Bat Conservation Trust about this term, as it's in their PDF, but as they're just a small charity I didn't want to bother them until I had exhausted other routes.PPS I've also built one from "scratch" using a cheap ($1) AliExpress PWM square wave signal generator module instead of the 555-based oscillator, in order to have a frequency display, and that works surprisingly well! Needs some *seriously* power decoupling from the rest of it to prevent the display on the module leading to audio hum - I'm using a 22ohm resistor in series with the 9V in power and 470uF across it after (the module has it's own LDO 5V Vreg.)

author: RFDx
author_rank: Regular Contributor
timestamp: June 16, 2023, 12:32:41 am
content: The receiver is a simple double sideband (DSB) direct conversion receiver that lacks any selectivity at it's input or in the audio baseband. This means the receiver is not going to respond only to the intended signal but also to the image frequency. Additionally it is sensitive to ultrasound signals in the vicinity of odd harmonics of the local oscillator as well. The "antenna" (ultrasound mic) is quite broadband (20...100kHz) with the highest sensitivity at 40kHz.

author: RoGeorge
author_rank: Super Contributor
timestamp: June 16, 2023, 05:13:19 pm
content: Quote from: jewelie on June 15, 2023, 08:37:11 pmIt's not clear what that means. Where are you looking, and half of what, the original bat frequency, or the shifted down received frequency.Can you post a sample record, or a picture with the spectrogram of what you receive, or at least give some numeric examples, please? Also, is the received spectrum correct, or reversed (mirrored)?

author: Andy Watson
author_rank: Super Contributor
timestamp: June 16, 2023, 09:38:43 pm
content: Your local oscillator (the 555) is generating square waves. This will naturally produce harmonics - usually the third, fifth, seventh etc. If it is not truly square, and asymmetry is aproblemfeature of the 555, it will also produce even harmonics. I.e. if it is set to 25kHz, the second harmonic will be at 50kHz. You need a better local oscillator!

author: jewelie
author_rank: Regular Contributor
timestamp: June 17, 2023, 02:29:29 pm
content: Quote from: RoGeorge on June 16, 2023, 05:13:19 pmSorry about that! Here's a more detailed explanation and details, if needs be I can make some recordings and try to get a spectogram out of it for you later?Pipistrelle Bats make echo location sounds with most power at the lowest frequency of the call, generally around 50KHz ish. Each call is about 5.5 to 6ms long. It's a very short but never the less just-about-discernable wet slap sound! This is a recording I made a few weeks ago. You can hear me tuning to it at some points, but no recording of the "sonic echo".So, whilst listening to the frequency shifted output I fine tune the local oscilator of the bat detector, which is just mixing the local oscillator with the sound from the bat call and then playing the result through a speaker, until the bulk of the pitch of the sound I hear is as low as possible. That tells me the primary fundamental frequency of the bat calls (that I otherwise can't hear myself without this tool!)In this case, let's say after this tuning, the local oscillator is at exactly 50KHz. For other reasons I can be pretty confident it's a Pipistrelle and so the sounds I am hearing really relate to calls actually at around 50KHz.... but if I then tune the local oscillator tohalfthat, at 25KHz, I can also still hear the same sounds (it's possible it's backwards in the frequency domain, I don't remember, so best not to assume orientation!)Obviously if I was getting such an echo at 100KHz, a harmonic of either the fundamental frequency of the call or from the local oscillator (which is a square wave ish from the 555) I'd assume it was just a harmonic issue. What's confusing me is the copy of these "decoded" sounds appearing athalfof the frequency of the local oscillator / bat calls!The PDF I linked to in the original post refers to issues caused by both harmonics (which I mostly get but I can't see how this can be the cause of my issues) or "sonic echos". But to me it's not clear if this is an inherent problem with the heterodyning circuitry, method, interference, literal feedback of sound between the speaker and mic, etc.)I've hacked the detector to add an earphone socket that cuts out the speaker, just in case there's some real literal feedback going on which is confusing things, but have yet to try it to see if that eliminates the issue or not.Have I made things any clearer? Do say so if not.

author: jewelie
author_rank: Regular Contributor
timestamp: June 17, 2023, 02:32:45 pm
content: Quote from: Andy Watson on June 16, 2023, 09:38:43 pmThe issue is that the bat call sounds are definitely at 50KHz, and I'm hearing an image of them at 25KHz too. That's the wrong way around for harmonics?

author: jewelie
author_rank: Regular Contributor
timestamp: June 17, 2023, 02:44:05 pm
content: Quote from: RFDx on June 16, 2023, 12:32:41 amA-ha. Yes, this sounds likely! Thank you. You're brilliant!QuoteUnfortunately, I don't quite understand what's going on but really want to. It's the not understanding that bothers me here, not fixing the issue - I did do AM and FM stuff at Uni many many decades ago and have spent many hours over the years listening to SW including USB/LSB stuff, so I'm not a complete novice, but I can't quite get what's happening for the extra image to appear at that lower frequency than the frequency of the call. Any chance you could help me to understand or point me towards any resources or key words that might help me to learn more?- Julie

author: Andy Watson
author_rank: Super Contributor
timestamp: June 17, 2023, 02:54:23 pm
content: Quote from: jewelie on June 17, 2023, 02:32:45 pmQuoteYou are tunig your local oscillator to 25kHz. It is putting out 25kHz and 50kHz (and 75k, and 100 etc.) You are hearing the pipistrelles being demodulated by the 50kHz second harmonic of the LO.

author: RoGeorge
author_rank: Super Contributor
timestamp: June 17, 2023, 04:10:53 pm
content: Unfortunatly something strange happens to my connection in the last 2 days, and could not write on the forum. I hope this message will go. If you follow the links from here:https://www.eevblog.com/forum/projects/want-to-hear-the-bat-flying-in-my-front-yard/msg3622429/#msg3622429there are samples with the expected bat call for various species. Your YT record seems OK, but I'm no bat expert. Didn't got the sound from the posted video to make any spectrogram of it (no need for extra records or spectrograms, the sound from YT is enough, I guess).AFAIK the spectrum of bats call is very broad, not just around 50kHz, more like 50kHz-100kHz. So if you see unexpected spectrum it might be some spectrum fold back.If you try to hear not only the bat call but also the sound-echo comming back from the surroundings, I'm afraid that won't be that easy. The sound from bats is very loud, like a bark if it were to be audible, while the echo is really tiny, only the bat can hear it without effort. In fact, I suspect each bat is "tuned" to its own call only, because they don't jam each other, but this is just my speculation.

author: jewelie
author_rank: Regular Contributor
timestamp: June 17, 2023, 05:25:09 pm
content: Doh! Thanks Andy. Now it's clicked and I feel very silly!In that case I might experiment with adding low pass filter on the oscillator output just to see what difference it makes.EDIT: Low pass filter made things worse. Looking at the waveform of the local oscillator, I think that's because it's a pretty clean square wave, so minimal 2nd order harmonics. Attempting to play with filters only resulted in warping it into nearer a sawtooth (capacitor charge, capacitor discharge type) waveform, as received at the input to the chip doing the mixing, which meant worse 2nd order harmonics, which was counter intuitive.

author: Marsupilami
author_rank: Frequent Contributor
timestamp: June 17, 2023, 06:45:40 pm
content: I'm sorry for not being able to contribute, but I must ask why is this not called a batector?

author: LM21
author_rank: Regular Contributor
timestamp: June 18, 2023, 09:27:07 pm
content: Years ago, The Elektor magazine had a bat detector

author: Qmavam
author_rank: Regular Contributor
timestamp: June 25, 2023, 02:10:12 pm
content: Replace your squarewave generator with a low distortion sine wave generator.The XR2206 is old but as I recall would develop a low distortion sine wave.I don't know the distortion of this, but it's prebuilt and cheap enough.https://tinyurl.com/ms23ujnjorhttps://www.amazon.com/Weewooday-Generator-Function-Frequency-Adjustable/dp/B08SMB6DRM/ref=sr_1_1_sspa?hvadid=580879786755&hvdev=c&hvlocphy=9011614&hvnetw=g&hvqmt=e&hvrand=12290872229088759391&hvtargid=kwd-539821946124&hydadcr=13122_13399468&keywords=xr2206%2Bfunction%2Bsignal%2Bgenerator&qid=1687701827&sr=8-1-spons&sp_csd=d2lkZ2V0TmFtZT1zcF9hdGY&th=1

author: jewelie
author_rank: Regular Contributor
timestamp: June 25, 2023, 04:18:54 pm
content: It would work better, but the point of my adaptation with the frequency generator was to also have a frequency display. I guess I could use a frequency counter, or a sine wave frequency generator with a display, but then that's getting awfully complicated for a budget bat detector

author: TimFox
author_rank: Super Contributor
timestamp: June 25, 2023, 07:49:12 pm
content: To search for information on this general topic, look for "spurious responses" in receivers.I had seen the plural of spurious response as "spuriae", but my European-born Latin-familiar professor emphatically rejected that spelling.To obtain a "more perfect" square wave, you can take the 555 output and run it through a single flip-flop divide-by-two circuit.

author: 10maurycy10
author_rank: Newbie
timestamp: November 29, 2023, 04:23:41 am
content: This could be being caused by harmonics of the local oscillator getting mixed with incomming signals, resulting in them showing up even if the LO is at half of the incoming signal .