namke
Full Member
 
electronics and sound, what's not to like?!
Posts: 188
|
Post by namke on Dec 3, 2020 17:03:17 GMT
(and if it is, how can I fix it?) So today I decided to try and port the wonkystuff 'Core1' firmware to Grains (It actually turns out that there are some fundamental differences which will need some thinking about, but that's beside the point) I was wondering why the output was sounding horrible, so I fired up my oscilloscope and found that the output is clipped horribly. Since my Braedboard module is next to the Grains, and the Grains output pin is easily accessible on the PCB, I quickly put together a simple reconstruction filter (10k resistor + 2 1nF capacitors in parallel)  …and compared the results:  The Grains output is noticeably clipped/overdriven. This is more obvious when looking at a sawtooth output:  I have just built the reconstruction filter from the Core1 board, and the output is even smoother (which is nice!)  So, to my question - does anyone elses Grains behave like this? I hope that it is just mine that is faulty, and that I can repair it (of course). For reference, I've added the sine-wave Grains code to my github here — also useful if anyone just wants a sinewave generator ( slowscape ?!): minimism's GitHub
|
|
Roth
New Member
Posts: 32
|
Post by Roth on Dec 3, 2020 20:03:56 GMT
Interesting how the sawtooth has been turned into more of pulse wave. I always thought a signal that was too hot would simply clip at the peak, but in this cases it altered the wave shape even at low voltage. Strange
|
|
namke
Full Member
 
electronics and sound, what's not to like?!
Posts: 188
|
Post by namke on Dec 3, 2020 20:16:38 GMT
Interesting how the sawtooth has been turned into more of pulse wave. I always thought a signal that was too hot would simply clip at the peak, but in this cases it altered the wave shape even at low voltage. Strange Yeah, to me it looks like the op-amp reconstruction filter has too much gain and, because the signal is biased to half of the supply voltage, its clipping top and bottom. But that’s just what it looks like to me. I’m interested to see if they’re all like that or if it’s just mine 
|
|
|
Post by cpruby on Dec 4, 2020 4:41:42 GMT
I gave it a go. I loaded up your code into my Grains. I don't have an oscilloscope, so I just recorded it in Ableton and zoomed into the waveform.  The waveform is a low frequency tone. As I go up in frequency the waveform becomes more squared.  (x-axes are different scales in each picture)
|
|
|
Post by slowscape on Dec 4, 2020 4:50:53 GMT
I NEEDS ALL THE SINEWAVES!!!1
I'm listening to your sinewave now, it's not a sinewave. Sounds like what I expect your scope'd wave to sound like, a less harsh square wave resembling an engine idle.
If we don't have any solid answer by tomorrow I'll get my scope out
|
|
namke
Full Member
 
electronics and sound, what's not to like?!
Posts: 188
|
Post by namke on Dec 4, 2020 9:07:22 GMT
Thanks cpruby and slowscape — seems like it’s not just me then  I shall spend a little time today tracing out the board to see if I can make mine sound better (even if it’s like that by design, I’d prefer a cleaner signal). Onward!
|
|