September 4, 2021 at 5:04 pm #14121
So, I decided to open this thread to consolidate work on DSPs here. Regardless if you are using Texas Instruments solution that is similar to SigmaStudio, using DIRAC, using miniDSP’s software alternative to SigmaStudio, etc.
DSPs and active crossovers have their own challenges. I even considered putting this in the crossover section because of the DSP relation to active crossovers. But there isn’t a neat place to tuck this. @TVOR-Ceasar – if you want, you can add a new topic in that section for DSPs, as it is similar to crossovers, amplifiers (as some DSPs now have amps with them, such as the JAB series among others), pre-amplifiers due to the signal processing, etc.
@ElliottDesigns – wanted to tag you since you mentioned about this.
Now, recently, I found the problem I was having with some of my designs for the JAB5. When trying to add the part for external potentiometers for each speaker after the active crossover, it stops playing sound. I am still trying to figure out why, as I have decided to do three independent gain knobs for the 3-way, then the master volume.
Does anyone have more experience with sigmastudio? Otherwise, I’ll post the solution once I figure it out.
Edit: turns out it was working, but unlike the master volume which defaulted to full volume, the gain switches defaulted to off. I didn’t plug the potentiometers in because of being lazy, but plugged them in to try. And they work. so now back to figuring out how to import the frequency response (or what I am doing wrong) for the autoEQ. Then is making FIR filters. Then just playing around with different ways to adjust phase, to adjust timing, etc. That way when I build my boxes, I can tune them quickly.
ModeratorDecember 5, 2021 at 11:23 pm
You can also get it at Home Depot. Check your local store online. Not sure what rating it is, but it’s there.
MemberDecember 6, 2021 at 1:20 am
@tvor-ceasar – yeah, my local HD has to special order for the 3.5″ denim, and it is a sizeable order of like $700-800. Then there are the 5.5″ at Lowes and HD, both of which, for me, have to special order.
Or can they order the 2″ version? Because 2″ is about as big as I can go. I’ve worked out the math and to do 5.5 cu. ft. box, it is around 10.25 cu. ft. after using 2″ insulation to line everything. I made a comment to a guy on here which had the (Edited driver) SI HS-24 driver in a 14 cu. ft. box which was huge. Turns out, I’m planning on doing something not that much smaller for a 12″. When I realized that, it made me think about some things. Then I decided to move forward with 2″ insulation lined sub compartment anyways. YOLO
MemberApril 6, 2022 at 9:25 am
This includes the standard firmware without hierarchies so people can trace what is actually happening. Now, the part I disagree with most on the default is using a L/R mixer, which then makes the signal mono. But, I’ll talk more later if there is interest.
MemberMay 23, 2022 at 12:21 pm
Here is my current documentation and the schematics for the 3-way and 2-way. @elliottdesigns , I still need to add your youtube videos to the FIR filter discussion. Turns out 15 PEQ and 480 taps for phase correction is what it can do.
@123toid , wanted some feedback on the guide I wrote up yesterday. Same with you elliott, @tvor-ceasar , and anyone else that cares to look it over.
MemberMay 23, 2022 at 1:26 pm
I only just saw it now, I put a couple of comments under the original guide you wrote. I’ll see if I can think of anything else 👍
MemberMay 23, 2022 at 1:42 pm
Flipping awesome guide! If I remember rightly, there’s a way to integrate loudness into these boards? Perhaps an offshoot in the schematic with a switch to bypass or not could include this? I think it could be super useful. Although, maybe that should be done as a separate document (or maybe I could do a video on it), as standard implementation is based on old Fletcher Munson curves, whereas it was found out more recently that we hardly need any super high frequency compensation, it’s mostly all about the bass and sub-bass regions. I’d need to figure it out though, it would have to be done with average volume triggers and some kind of prescaler that the user inputs based on the playback volume of a -12dB pink noise signal in their room (a reference volume offset). Nevertheless, I digress yet again… A short comment on how it’s probably best to use a linkwitz Riley crossover over the others since it’s linear in volume level (sums to flat). It also seems like delay is configured in samples, I doubt many people know how to convert s or ms into a number of samples. Not really common knowledge, so maybe a table on how to convert based on sample rate used. I’m not even sure an infrasonic filter is useful on these chips, accuracy of filters starts to decline even below 200Hz on these adau1701s, simply doesn’t seem to be enough processing power for it. I presume it making the filters less accurate is its way of dealing with that. That’s been my experience with the miniDSP non-HD anyways, and that has the same chip. For rePhase, recommendation for setting to 44.1khz rate for best use of the limited samples. As well as limiting optimisation to a -40dB noise floor, and only using the fully parametric phase and filters linearisation tabs so taps aren’t wasted on gain changes, just fixing the minimum phase of filters already applied. I think that’s all it for now. Really professional document, and a job well done!
MemberMay 23, 2022 at 3:23 pm
Thank you for the excellent feedback. I went for a casual read with lots of images. I was going to wait until I played with it for my projects, but those were taking too long and I wanted to get it out. Plus it snowed yesterday, so I used my time constructively and created a document.
For the sample and ms conversion, I forgot to mention which elements on the schematic can change what the input is by clicking on it. If you click on samples, it switches to ms. So I will need to put that in.
And explaining the benefits of LR filters does need done and I can link over to Linkwitz’s page where he discusses filters for the citation.
As to the infrasonic filter/excursion filter, the important part isn’t whether or not it accurately causes the fall, it is about whether it can prevent it from reaching X-Max in normal listening and prevent extraneous distortion. Even if you have to set it higher than the target frequency, the main goal is to get it headed down to prevent those events from occurring. But I do need to explain that better. I can also mention if a person prefers, they can save the instructions and remove those, then add an L-pad or make their own analog filter with components, thereby assuring the filtering of those frequencies from the signal chain and adding back more instructions to dedicate to the FIR filter.
The suggestion to go to -40 I’ll check out. At that point, it may cause some songs that have quiet intros to stay muted as those sounds build. But I won’t know until I test it. There’s a couple songs I can think to test it out with. One is the rolling thunder in The Thunder Rolls by Garth Brooks. There’s also a couple songs I can’t remember that have that in their intro during the first 30 seconds or so. Just have to check to make sure it won’t trigger during that and other than that, good suggestion.
For the sample rate, I should have a breakout section on that to explain where, in each of the programs, that is at and how to match them. That way there is no way someone will be confused by that and also so people can go to 44.1kHz easily to get the extra instructions.
Once again, thank you for the kind words and the notes on the document.
MemberMay 23, 2022 at 4:19 pm
The -40 was just for the noise floor of the optimisation filter in rePhase, it takes everything that would have been used and reapplies it above -40. Helps spread the number of taps further
MemberMay 23, 2022 at 4:22 pm
Also, it’s not about the extra instructions. It’s the fact that at a lower sampling rate, each sample represents a longer amount of time. So a small amount of samples can more easily represent lower frequencies inside of rePhase, I quickly went over that in my Linear Phase EQ Pt2: rePhase tutorial.
MemberMay 23, 2022 at 4:29 pm
For sigmastudio, though, it all comes down to instructions per cycle. You have fixed amounts of instructions that you can feed, mostly dictated by the size of memory, but also limited to the IPC/IPS of the ADAU1701 chip itself. At a lower sampling rate, it actually uses fewer instructions available for the chip in sigmastudio. And every saving of instructions there means more coefficients may be possible.
I also glossed over the fact that implementation of IIR filters can shift time alignment done through the sine-sweep method of impulse response. That is also why I recommend the time alignment between drivers before PEQs are applied. I left links to an article on the topic in a footnote, but that is a little easter egg if you care to read them.
But for the -40, good to know that was for rephase, not the signal detect / mute function.
ModeratorMay 23, 2022 at 8:38 pm
Aw man, you’re going to have to give me some time to get into this-office move is next week and I’m still packing up in addition to keeping the field crew(s) going and info flowing through the office, plus internal IT. Not to mention home life and 2nd job.
MemberMay 24, 2022 at 5:47 am
Don’t worry, take your time. If I have a new version for the guide, I’ll post it in the interim. Not asking for you to put yourself thin, of course.
MemberMay 25, 2022 at 2:54 pm
@elliottdesigns – So, here is a comparison of memory requirements for extended depth bi-quads as compared to FIR filters with single precision with 10,000 to the sub, then 5,000 each to the mids and tweeter. Just thought you would be interested in understanding the difference in required instructions size and difference in memory requirements. It shows why PEQs are still used, because you can offload the massive lift to PEQ filters, then fix up the linear phase after the fact with FIR. But you want the majority of the heavy lifting to be done before a FIR filter to try to make its work easier.
MemberMay 26, 2022 at 12:50 pm
Yep! That’s what I was suggesting in my previous comments! Do PEQ stuff for the minimum phase EQ and crossovers. Fix crossover and minimum phase PEQ to linear, using phase only FIRs to fix the phase. Not ideal since PEQ can be inaccurate in low frequencies depending on how they’re implemented, but definitely a great compromise to make.
MemberMay 30, 2022 at 10:03 am
So here is the next iteration of the Sharc schematic (this time designed in the Block Schematic area which has many more selections for modules), along with the compiling with the new compiler in CrossCore Embedded Studio 2.11, which is a much newer version of the compiler implementation that gave an extra 100 taps for the FIR filter.
Next I need to implement compressors for the RMS compressor and the peak compressor/limiter.
I also need to research more how to do adjustable gain depending on dB level to get it where it adjusts to more closely match perceptual hearing for volume. That is where things get interesting.
MemberMay 31, 2022 at 1:15 pm
<div>So, here are a couple examples of AGC designs that can be implemented in SigmaStudio.</div><div>
One issue with AGC (automatic gain control) is that after you have compressed and/or added gain, you also add gain to the noise floor, meaning that you would also need to add a noise filter in addition to the AGC in order to then remove or cancel out the noise that is more audible after implementation. But, if you add an AGC to your project, you shouldn’t need an RMS limiter nor the peak compressor as the AGC should be set so you don’t go passed a certain point on power to your drivers.
MemberJune 2, 2022 at 8:04 am
@elliottdesigns – so what do you think of this design:
edit: I also decided to use the fourth out to route into the second analog in. I then use this signal merged with the signal for the trigger of the noise gate. I also use this signal, then subtract from it the signal just passed the volume soft limiter. That, in theory, should pick up the noise in the chain aside from that which was already gated. So deleting the second input signal from the output signal should allow for identifying the noise from the DAC, etc. I then take the noise sample, invert the phase, then add that to the signal to then act as negating the noise beyond that point. Adding the inverse should, in theory, negate the noise level. Is it needed, probably not, but if doing a merger for the external source to trigger the noise gate, might as well see if that further cancels out the noise. In theory, subtracting would do roughly the same as adding the inverse.
I had to modify the limiter model due to what modules are available with Sharc. I also used a soft clip instead of a hard clip in the limiter circuit, which in theory should give better performance for audio.
That is the signal detect block.
- This reply was modified 3 weeks, 6 days ago by ajc9988.
- This reply was modified 3 weeks, 6 days ago by ajc9988.
- This reply was modified 3 weeks, 6 days ago by ajc9988.
MemberJune 5, 2022 at 6:10 am
Looks good to me, but a lot of this signal analysis goes over my head. I saw you were doing some stuff to do with dBFS, so figured I’d talk a bit about what I learned about loudness. So I’m adding that post on the forum now. Figured I should do it at some point or another.
But yeah, you’re stuff seems great!
MemberJune 16, 2022 at 7:11 am
Dear friends, in accordance with your advices I finally bought a Chinese card based on the ADSP 21489 SHARC processor. All OK, no problem at the moment even with sigmastudio. The only big problem I have is that of the factory-set 96K sampling rate while it would be convenient for me to have it set at 48K. I’ve been looking for a solution on the internet for several weeks, but nothing. Obviously, as an enthusiast, I don’t have the knowledge to correctly use CrossCore embedd and flash the card. Can anyone here help me?
- This reply was modified 1 week, 6 days ago by GiAnt.
MemberJune 19, 2022 at 5:03 am
First, crosscore embedded studio is for deeper programming for custom works. You would need it to implement, for example, Dirac.
Depending on the model, you can flash it with sigmastudio using the link/compile/download. It will erase use with any aftermarket software like that which came with my device, but if that is not a worry, then it should be fine.
I’ve been holding off flashing my custom firmware to date, but I will do it after I wake up some more today.
Where to change the sample rate is found at the top of sigmastudio. But, when it asks you to update the algorithms, do it, because they are tuned to the sample rate.
MemberJune 20, 2022 at 11:58 pm
In sigmastudio you can change the sample rate of the project not that of the card that will continue to work with the sample rate set by default. in fact, it is absolutely necessary not to set a sample rate in sigmastudio different from the one set in the processor.
- This reply was modified 1 week, 2 days ago by GiAnt.
MemberJune 21, 2022 at 5:34 am
What do you mean by this? When you set it in sigmastudio, then click link-compile, you then have to export the schematic. That then is used with cygwin to make the file that is incorporated into your application in CCES.
The processor isn’t necessarily the issue, the question is whether the board only is capable of specific sample rates due to the use of specific parts that only allow for it to accurately use a specific sample rate. Many times, the crystal oscillator on the board is the same, but it is the setting of the divisor that then sets the sample rate that the crystal oscillator is keeping time for.
So I understand you may have the understanding that it will always be set at the specific rate, but I believe that is false. You are setting the sample rate in sigmastudio to later be incorporated into the LDR file generated in CCES.
Where did you get that you cannot change it in sigmastudio, if I may ask? Can you point me to the source?
MemberJune 19, 2022 at 9:12 am
OK, I didn’t like my answer, so here is more information:
You, like I, probably do not have the schematic file for the pinout and how the components for the device is connected. As such, if you try to create a file in CCES, you could have issues. This is why they provide that for the evaluation board in this post:
The User Guide for Sigmastudio for SHARC:
The Release Note, Reference Guide, Users Guide and Product Spec can all be found in the “C:\Analog Devices\SoftwareModules\SigmaStudioForSHARC-SH-Rel2.2.0\Docs” folder.
I contacted the seller to contact the manufacturer to either procure an LDR file for the device in order to then program it to load the schematic at boot. Probably something I should have thought about earlier.
- This reply was modified 1 week, 3 days ago by ajc9988.
MemberJune 21, 2022 at 12:01 am
Dear AJc I also sent a message to the seller who unfortunately replied that he could not help me
MemberJune 19, 2022 at 10:17 am
more on the discussion of LDR. Also, I may be mistaken, as you can export it from sigmastudio to use in CCES to make that file. Also, the device has certain settings password locked in sigmastudio, so it should have the hardware settings that matter locked (good thing, less likely to mess things up). These are assumptions. I am not responsible for harm to the device. I’m responsible for my own hardware.
MemberJune 21, 2022 at 12:16 am
Dear ajc9988, I am deeply grateful for what you are doing and I think that if you manage to change the sample rate of the card and make the method public it will be your great merit that will be recognized by many, many people. This information should be made available to the seller, but unfortunately with Chinese goods as you know this is impossible. After all, even with branded products such as minidsp, audison, powersoft and others, the cards are almost always set to 96k and for the end-user there is no possibility to change this setting
MemberJune 21, 2022 at 5:54 am
Once again, where did you get that this is not possible? Can you cite a source? Because from what I understand of the use of crystal oscillators and divisors, this isn’t necessarily true. The processor itself can process whatever data, so long as time is kept. You can hard wire a product to solely use one time, or set divisors possible, and even use multiple crystals to allow for the switching of different sample rates in a product. There is even an asynchronous sample rate converter in CCES for the ADSP-21489.
Many of these products ignore the science of audio. People think they can hear a difference with higher sample rates. Maybe they can. But older studies showed people could not hear the difference above a certain sample rate: 44.1kHz. But the new high def mastering goes up to 96kHz, 192kHz, 384kHz, or multiples of 44.1kHz. My point is, they push for the 96kHz for marketing to people that believe the more information the better. But, from a computational standpoint, you now have double the samples in the same period, and you now must apply the instructions to that many samples, thereby halving or more than halving the number of instructions that can be used for processing.
Most likely what people are hearing in remastered content in the higher kHz sample rates is the fact they remastered the entire track with better modern techniques, so that if the audio technician is good, you are going to have a better mastered track than the original. As such, they are hearing other aspects of his or her work and believing it is the sample rate that gave the additional sound fidelity, when in all likelihood, it was better equipment, better speakers with less distortion allowing for clearer playback which then allowed for cleaning up the track better, etc.
And sure, for some, they may even be able to tell the difference in sample rates. It is like some with TVs being more sensitive to PWM flicker and the rate at which the display refreshes. A majority of people will only recognize it seems smoother, but there are some, including specifically professional e-sports players, that are sensitive enough that they can tell the difference of the frequency refresh rate of a display where a normal person might not be able to. But ears and eyes are also different.
So my point is, I’d like to know where you came up with the notion that these processors only run 96kHz instructions. If you can tell me about the crystal oscillator setting the master time to only the specific sample rate without being able to set a different divisor in software to then arrive at the sample rate, and that the crystal oscillator value means that the divisor needed to arrive at 48kHz is not available for the software being programmed, I’m all ears. Especially as I did not pull the value of the oscillating crystal yet to backtrack the component to look up the datasheet to check that. But, because that has not yet been shown, I will continue on the assumption it can be set otherwise.
MemberJune 24, 2022 at 12:21 am
No, my words have been misunderstood. The processors can obviously be set at multiple sample rates and regarding the same 21489 are marketed some devices with a factory set value of 48K. I just wanted to say that for the common end-user of this kind of product, usually not a computer or sound engineer but a simple enthusiastic hobbyist, it is a titanic job to modify these settings alone as there is to learn (assuming they are available) too much and too specialized information. For that, I asked for help on this forum as on others hoping to have answers and now you are the only one who has answered and who is trying his hand at the enterprise. Unfortunately, I can only follow a method if clearly detailed step by step. Unfortunately, I don’t have the skills to do anything else
MemberJune 24, 2022 at 10:32 am
As soon as I have the process down, I’ll probably post the PDF here and in the analog devices forums. That way it can open up adoption.
MemberJune 20, 2022 at 11:09 am
Update: I am following the guide that was posted at ADI. I will then post if it is successful at creating the LDR file. Currently downloading Cygwin. I’ll create an updated PDF with pictures if I am successful.
MemberJune 21, 2022 at 12:06 am
Dear, can I know what kind of card you have? Mine is this
MemberJune 21, 2022 at 6:05 am
That is the exact one I have, with the PCM4202 and PCM1798 ADC and DAC. I have connected the SPI after having soldered the headers onto the core board. I then am using the USBi to change the values.
This allowed for the temporary download to the device, but not the permanent change to the software, which is a problem for persistent change of what it is running. No one wants to have to apply the download each time you turn the device on and off. So to address that, you have to generate an LDR file, then after that set the boot of it.
I’m currently running into memory errors in my compiling of the schematic I made, so I will attempt to reduce the schematic size hoping that is the issue and not something else. I am not a coder, but can recognize patterns at a great rate (how I learn). I have made the changes recommended in the document, so I have to finish making the application for incorporation of the LDR, then I will look at doing the other parts to be incorporated into the LDR. Then after that comes the flash.
Unfortunately, I have no idea who the manufacturer was on these.
Did you get the software to at least use the program that comes with it? The USB midi program and the IIR filtering showed in the ad?
MemberJune 24, 2022 at 12:35 am
Dear ajc, no, I don’t have this software. I checked in the folder that was sent to me by the seller and found nothing like it. So you say that every time one turns off the card the information downloaded with sigmastudio is lost and at the next reboot you have to reload it again? But this is crazy. Does this also happen with the other cards that are sold on aliexpress such as the one you recommended with adau1467 processor? If so these products are unusable and then I understand why they have so little diffusion …
MemberJune 24, 2022 at 10:29 am
So, I will have to buy an ICE-1000 in order to then solder on the JTAG points and develop/debug the software I made in CCES. After that, it is my hopes that I can then program the device with the finished program through sigmastudio (without needing the ICE-1000 to program). If I am able to do that, then I will release that program once I finish developing it. Until then, yes, it wipes the program downloaded through sigmastudio on reset until the program loader is flashed on the hardware and the boot is set to start what was developed in sigmastudio.
Meanwhile, the ADAU-1467 has nearly as many instructions as the ADSP-21489, but does not even require CCES. All programming is done simply with sigmastudio. This is better for people without any knowledge on programming and debugging. As soon as I finish developing for myself, I can share that, but that will depend on my schedule. So I cannot promise when I will be done.
So, the adau-1467 is more user friendly and does not require all this work. SHARC requires the extra work, but is more free in that way. Most want the 1467 designs because it is like that 1701 but more powerful.
Meanwhile, these products that we have are to use the DSP for a home theater system, using allotments for IIR filters for each output, etc. The software requires you to open the usb midi program, then open the english version of the program, link with USB, then change settings inside that program. When done correctly, those settings do persist. But that is not sigmastudio download.
So, if not wanting to wait on me, the adau1467 is the one to get.
MemberJune 24, 2022 at 8:02 am
for ADAU1701 is not required generate an LDR file so I assume also for ADAU1467″
“This code is currently in volatile memory and it will be gone as soon as the DSP is powered off. We therefor need to store it permanently in EPROM in order to enable the DSP to load it at boot-up. Switch back to the Hardware Configuration tab, Config section. Right-click the ADAU1701 block and select Write Latest Compilation to E2PROM. Press OK in the next dialog and watch the progress bar while the code is stored in EPROM. You should now be able to power cycle the DSP and it should boot-up loading the latest project you written to memory.”
MemberJune 22, 2022 at 9:44 am
BTW, if you do not have it, here is the PC USB control software for that platform.
MemberJune 21, 2022 at 11:09 am
Also, for those not willing to learn some programming, etc., these are better fits. One of them is for having multiple in a single speaker if doing a three way (issues of two different master oscillating crystals, will never truly sync, but you can get close with doing the delays for the drivers), whereas the other is for 8 input, 8 output, spdif in and out, etc.
Those can be fully programmed with sigmastudio without CCES. The ADAU1467 gets close to the processing power of the ADSP-21489, but it simplifies what you need greatly. Cost is about the same (if needing 2 of the first one for up to a 4-way or the second one which has all the inputs similar to the board we are working on).
Verify first with the vendor, for the first link, whether the boards have the 1463 or the 1467. Also verify what ADC and DAC is being sent with the board. For the second link, it is plug and play using 3.5mm aux. two channel plugs.
But those would likely be simpler for many to work with, while providing what they need. In fact, two of the first link would, in theory, have more taps available than the adsp-21489. Once again, synchronization issues may arise, but should be minimal. There are numerous ways to handle two in a single system.
I am still working on an error in CCES when building the application project. I’ll report when I have more info.
MemberJune 22, 2022 at 9:46 am
So solved the compile error. The issue was the linker settings in CCES. After that, compiled fine. But to communicate and debug the program, I need an ICE-1000 JTAG module. So have to wait to test more.