Combining bit reverse and time reverse of a sequence in asm

Technical questions regarding the XTC tools and programming with XMOS.
Post Reply
User avatar
aclassifier
Respected Member
Posts: 483
Joined: Wed Apr 25, 2012 8:52 pm
Contact:

Combining bit reverse and time reverse of a sequence in asm

Post by aclassifier »

I am using dsp_fft_bit_reverse before dsp_fft_forward.

In order to do cross-correlation as [1], as one alternative, I would need to also time reverse one of the sequences before doing the dsp_fft_forward. I guess this is faster than the alternative, to do the complex conjugate after the fft.

I am using lib_dsp(6.2.1) and X2, which seems to do dsp_fft_bit_reverse in asm in dsp_fft_bit_reverse.S.

Is there anybody out there who'd like to rewrite or even would have that code doing a built-in time reverse? This is for a hobby project. I don't know xCore asm at all.

Øyvind

[1] How do I implement cross-correlation to prove two audio files are similar?


--
Øyvind Teig
Trondheim (Norway)
https://www.teigfam.net/oyvind/home/
User avatar
andrew
Experienced Member
Posts: 114
Joined: Fri Dec 11, 2009 10:22 am

Post by andrew »

How long do you expect the blocks to be?
would this be a running similarity? i.e. every N ms you up date the similarity of the most recent M ms of signal
User avatar
aclassifier
Respected Member
Posts: 483
Joined: Wed Apr 25, 2012 8:52 pm
Contact:

Post by aclassifier »

It's basically as in [1]:

each of my series covers 64 ms (16 kHz, 1024 samples per batch, 15.625 Hz/bin to max 4 kHz). My project is at [2]

Yes, it would be a running similarity, where I would compare against several alarm patters. However, the FFTs of the alarm patterns would be the references that I would need to make once, that's where I need to time reverse that alarm sound first, before the FFT etc.

But I thought, what if that could be done with the bit reversing? For the XC version of the bit reverse it's rather easy, but the ASM is worse for me. An then, maybe somebody else might thought this interesting, too?

[1] Detecting a known alarm signal in an audio stream
[2] My Beep-BRRR notes
--
Øyvind Teig
Trondheim (Norway)
https://www.teigfam.net/oyvind/home/
Post Reply