pantherb / setBfree

DSP tonewheel organ
http://setbfree.org
GNU General Public License v2.0
194 stars 35 forks source link

ARM - Crash - computeOffsets: Assertion `maxhn + w->hornSpacing[i] < ((unsigned int) (1 << 10))' failed. #47

Closed brunetton closed 6 years ago

brunetton commented 6 years ago

Hi, First of all, I want to thank you VERY much for this wonderful software. I'm currently trying to embed setBfree to a Raspberry-PI and use it as an Hammond emulator on stage. As Raspbian version of setBfree is quite old (0.7.5), and new versions seems to "sounds better" (I am wrong ?) I wanted to compile a new version on the Pi(3).

Steps to reproduce:

aptitude install libasound2-dev lv2-dev libglu1-mesa-dev ttf-bitstream-vera libjack-jackd2-dev libftgl-dev
git clone git@github.com:pantherb/setBfree.git
cd setBfree
make OPTIMIZATIONS=-O2
./src/setBfree

The result is :

init.. Audio : Oscillators : Scanner : Overdrive : Reverb : Whirl : setBfree: ../b_whirl/whirl.c:539: 
computeOffsets: Assertion `maxhn + w->hornSpacing[i] < ((unsigned int) (1 << 10))' failed.
Aborted

Did I missed something ? The problem seems to be in the Leslie simulation module. It's annoying, this is quite important for the sound !

Do you have any ideas ? Thanks !

x42 commented 6 years ago

It's been a while since I've tried the jack-app on ARM. It may well be that special casing done for the LV2 plugin triggers this assertion. Sorry.

It's probably just some default values. I'll investigate, but I won't get my hands on a Rpi until next week. Please stay tuned.

x42 commented 6 years ago

What samplerate are you using? Does it also cause this assertion when you use 48000 or 44100?

brunetton commented 6 years ago

Hi, thanks for your time ! And sorry for the delay, I didn't had time to work on that project for a while. I'm using a 192kHz / 1024 frames/period Jack server (IQaudio Pi-DAC-PRO card).

And ... it works well from 48kHz up to 96kHz, you were right :champagne: Latency is a big deal in that project that aims to be used on stage in live concert conditions. I'll test it at 96kHz 512 f/p (that gives me a latency of 10ms -> very good).

Thanks very much !

x42 commented 6 years ago

Don't try to optimize (lower) latency by increasing the sample-rate. Especially with cheap cards such as the Pi-DAC, you'll usually get much worse quality compared to using 48k, besides chances are that your analog equipment cannot handle frequencies > 20kHz anyway and just distorts instead. Lower the buffersize if you must.