I think your question is too vague for anyone to really help you.
If you let us know what device you want to connect to the T4, there might already be a library out there that can help you.
Type: Posts; User: wcalvert
I think your question is too vague for anyone to really help you.
If you let us know what device you want to connect to the T4, there might already be a library out there that can help you.
Regarding the failure to upload to T4, I just wanted to share the following.
It is not a bug report and I'm not expecting anyone to do anything about it. It should be treated as anecdotal only.
...
You can share the same I2C bus as long as the devices have different addresses.
Mouse example code here: https://www.pjrc.com/teensy/td_mouse.html
If you don't have the datasheets for the I2C...
My guess is you're reading/writing out of bounds on one of the several arrays that you've got. One recommendation is to #define the array length so you can be sure any code which accesses the array...
When using the analog pins with the Audio library, the Audio library code pretty much takes full control of the analog hardware, so calling analogReference() probably does not do anything. Your code...
DAC8565 support in the Audio library would be cool. I suspect the reason the original author didn't go that route is latency. Each block in your audio chain will add about 3 milliseconds to the...
O&C runs its own special firmware that doesn't use the Audio library, so it has no USB to Audio abilities .. unless there is a firmware fork that I don't know about.
Anyway, let's pretend there is...
Please don't modify safety critical stuff on your car.
Right, it's not the case. The '&' means "address of". So for the following line of code:
AudioPlaySdWav *players[NUM_PLAYERS] = {&playWav1, &playWav2, &playWav3, &playWav4, &playWav5};
In...
Hmm, so is the crossfading started by a user pressing a button or something? What should happen if the user presses the button too rapidly for the crossfading to complete on whatever is currently...
I'm sorry, I think I should have read your code more closely. I was misunderstanding how you were intending to use your class instances. I think your approach is fine for multiple instances.
Every time you call phase(), the phase accumulator gets reset. See here, line 53: https://github.com/PaulStoffregen/Audio/blob/master/synth_sine.h
My best guess without testing your code is: your...
Basically you would need to have different class definitions, how else would your class be able to work with other patchCords, mixers, and filters? If you use pointers for members, you can reuse the...
If you only need one instance of AudioFilteredMixer per project, that approach will work fine. If you need multiple instances, you'll probably want to switch over to using pointers for your members.
IMHO you need to first identify exactly what your goals are, and I can see two possibilities: 1: you are trying to make a wrapper class to encapsulate existing functionality of the mixer and filter...
You can do something like this if you want the logic to be a little more compact and easier to maintain.
#define NUM_PLAYERS 5
PlaySdWav *players[NUM_PLAYERS] = { &playWav1, &playWav2, &playWav3,...
It might compile and work correctly, but it's going to make a very poor piano due to lack of multiple voices and/or oscillators, no envelope generator, filter, etc.
Almost none of the Audio library will compile for the LC. It would be wiser to choose a 3.x or 4.0 if you actually want to synthesize sounds. You'll need to connect analog output from a DAC or codec...
22kHz sample rate means the maximum frequency that can be reconstructed is 11kHz. Google for Nyquist sampling theorem or Nyquist rate for more info.
If you'd like to have multiple simultaneous wavs playing, you'll need multiple playSdWav objects. Then each time the button is pressed, you'll loop through all of your playSdWav objects, and use the...
You can use TDM to get many channels of input and output. Here is Paul's original blog post about it:...
Each audio object by default uses the processor's internal RAM. The audio objects have to be specially hand-coded to take advantage of external SRAM. The large external SRAM would allow for longer...
From the notes in the GUI tool:
"Memory for the delayed signal is take from the memory pool allocated by AudioMemory(). Each block allows about 2.9 milliseconds of delay, so AudioMemory should be...
Your synth has one voice, and you are checking if the envelope is active before letting another note play with this bit of code:
if (envelope1.isActive() == false)
If you remove the condition...
Here is another thread on the front page which answers a lot of what you're asking: https://forum.pjrc.com/threads/59212-Audio-Router-Module
Well, I don't know what you mean by latency problem, but I think you might have a logic problem in your code.
...
mixer1.gain(2, (float)knob3/1024.);
...
float sustain = (float(knob3)/1024.);...
It's more memory efficient to receive the first input block as writable so you can reuse it as the output block. That way you don't need to allocate an additional output block.
The first time through the loop iteration, the output block hasn't been allocated yet. It checks for the allocation of the output block with the (!out) condition, allocates the output block using...
Welllll... kinda. It might look something like this (pseudocode):
gain = .2;
out1 = allocate()
out2 = allocate()
for(int i=0; i<4; i++) {
in = receiveWritable(i)
for(int j=0;...
It's a logical error, not a compile time error.
Think of it like this: when you call receiveWritable, you are taking possession of a piece of memory that is 128 samples long and 16 bits wide. Once...
Audio is processed in blocks of 128 samples, so with a sample rate of 44.1kHz that means your code will be called once per 2.9 milliseconds. Your code needs to have only one occurrence of...
Do you mean, it works in Windows but not Linux? Seems like linux config would be the problem in that case, no?
Also, if you are getting better frame rates in linux than windows, something is...
Well, best to understand the example that I linked to. But you could do something like this (pseudocode basically, will not compile):
#include <Audio.h>
#include <Wire.h>
#include <SPI.h>...
Well, reading your idea (different playback speeds) again, that sounds kinda similar to the granular effect, see here for example on it:...
At the current time, there is no way to just malloc() onto external RAM. The delay effect, for example, has a long duration version that is hard coded to use external RAM as the buffer. You can see...
If you are using the Arduino IDE, you don't need to #include the file, it will automagically compile it if it's in the same folder. See here for the sketch:...
That's a good catch too, I didn't realize he had a conflicting Arduino vs Teensy situation happening.
You can:
#define BUILTIN_SDCARD 254
Or:
#include "Sd2Card.h"
I suppose the examples are somewhat out of sync with the development that has occurred. Also, just in case it's not clear,...
The thing to keep in mind is that a well written library will expose the exact same API (open, read, write, close, etc) no matter what interface (SPI, SDIO, built-in SD card or external) is being...
Beaten by defragster
That sounds very similar to what a user here was doing to create a chorus effect, his code is here: https://github.com/quarterturn/teensy3-ensemble-chorus
He was using a fixed frequency LFO that...
https://github.com/PaulStoffregen/cores/blob/master/teensy3/usb_desc.h
Starting on line 742. I don't have hardware sitting next to me to verify, but I speculate that you can use the name.c example...
The audio GUI currently does not have separate object definitions for the different I2S interfaces. So you would manually edit the generated code to do that, which is not a big deal.
As long as...
You might want to post exactly what the issue is, because it's almost certainly not too much for the T4. You would be surprised how powerful it is.
But, anyway, you could connect I2S out from one...
Yep, I am well aware and have posted in it a few times. I'm not sure if development stalled, and the latest board files didn't make it to github. Hoping it's not dead though.
Oh, for sure. Ideally I would love a SOM style module with a ton of castellated pads but I know that's not going to happen. :)
19224
But, when going dual core, it can't be overstated how...
Came across this board called Meadow F7 and thought it was kind of cool. 16MB DRAM and 32MB flash on board, plus an ESP32 (which I could do without) in a Feather-like form factor. Imagine an 1170...
One quick hack you can do to increase the performance is start with the Adafruit library, and change all the digitalWrite calls inside the write() function to digitalWriteFast. This cuts the SPI...
Hi - sorry for reviving this old thread. Would you elaborate on "a few more things to do in the initialization sequence due to odd looking color gradients"? I've been working with these IPS displays...
Hmm, that's encouraging actually. I had a thread with a very similar configuration and problem, but I moved onto other things before figuring it out.