Not necessarily, your frame rate calculation is just valid for the image transmission, but the sensor array has a minimum exposure time in order to create a useful image, that would be the frame time...
Type: Posts; User: mlu
Not necessarily, your frame rate calculation is just valid for the image transmission, but the sensor array has a minimum exposure time in order to create a useful image, that would be the frame time...
Do I get the picture right, the camera is above the hammers, is this a standing piano so the camera sees the edge of the hammers, or is like a grand piano so the camera sees the top/back of the...
Here is a ring buffer variant to test also
/* Control a set of solenoids with MIDI
* Note on messages trigger solenoids, and they will be turned off after a certain amount of ms has passed
...
Its not my project, but I agree that this a could be a good way to handle something like 100 solenoids, a number to big for the Teensy pincounts. In this case there would be a solenoid array, or...
I have tested your original code on a Teensy 3.6 and a virtual midi keyboard on MacOS, outputs just connected to led's. With only these 5 possible solenoids its very fast, in order of ten...
With all delays equal and the time always monotonically increasing its a simple queue, I would use a circular buffer with the reference (pointer) to the head which is the next element to remove, and...
The sending loop in writeSeq callback has no control over the bit timings. So on the Teensy 4 the bitrate will be much higher than for the LC, possibly/probably causing issues for the N64 to read the...
Try the following:
float voltage = 0;
float voltage_Old = 0;
int midiNeu = 0 ;
int midiOLD = 0 ;
You do what you ask for, compare the voltage with the previous voltage, needs a varible to save this, and send midi when threshhold is crossed.
Did you change clock and data pins to you configuration?
That can be a great way to fry both the Teensy and the LED. The LED pulls the voltage down to 1.2V and excess current from the Teensy output pin.
Always use current limiting resistors!!!
Are you measuring the voltage over the LED? Any series resistor ?
Then try to add in some pixel stuff into the loop(), removed everything that looks like motors and doors and audio.
This needs the correct led data pin numbers as of previous post to do anything,...
Next issue , lines 16-18, the led data pins cannot be 32, 31 and 30 on an UNO, changing to 2, 3 and 4 gives a sketch that compiles for UNO but of course doesnt do anything since the loop() is empty
First issue: you lost the closing brace in the loop() function.
void loop() {
// put your main code here, to run repeatedly:
}
What would AUDIO_SAMPLE_RATE_EXACT be then, given that clocks and PPL's are drifting and trimmed, their exact values unknown ?
When doing this kind of PLL adjustment to sync two clocks that both nominally should run at 44100Hz, I think it would be a mistake to say that the AUDIO_SAMPLE_RATE_EXACT has changed, it is still...
The following code works, there is an ugly cast from (const char **) to (char **) in the addMenu, since I had trouble defining a non const array of arrays of const character strings.
const...
The AS5X47.h library, https://github.com/Adrien-Legrand/AS5X47/blob/master/src/AS5X47Spi/AS5X47Spi.cpp, does not seem to use SPI settings, that might create problems with the Teensy 4.0
Since you already have two Snooze related questions in the Technical Support & Questions I guess nobody is super interested in answering this third question on the same issues.
well midi serial is 32,5 kbaud, about 3200 bytes per second, and a midi message usually 3 bytes so about 1000 messages per second. Now this is more than most midi receivers can handle.
So how to...
Ahh and cache is supposed to improve performance, perhaps only PSARAM should be cached in this situation.
Could be so simple that 16 CC messages without any pause overflows the serial out buffer.
Yes, but the OP has a 400nS interrupt that runs at 1MHz, the probability of a TimerTick hitting that memory write during the microsecond that the Timer Tick fires is 150 nS out of every 1000nS (1MHz)...
Could it be that the timer interrupt is interrupted by another interrupt ?
Arduino Stream parseFloat could be what you need:
https://www.arduino.cc/reference/tr/language/functions/communication/stream/streamparsefloat/
The following code snippet (untested) should...
The rev C shields have DOUT, audio data from shield to Teensy on pin 13, and the SD card clock on pin 14, so when only playing music pin 13 can be used for blinking. On rev D boards the SD card clock...
The OP updated his SPI library to a more recent version, one that does not reference SDREG when compiling for Teensy 3.x or 4.x
Its in your sketch line 150 as the error says, SDREG is the AVR status register and does not exist on the Teensy 4.
The vs1053 code seems to be written for Arduino AVR processors and not adapted to...
This led blinking is probably pretty, but it is not easy to help when the code you run when testing is not the code you share in the forum :(
Also if you want to be 100% sure of having the pullup...
If dispCounts interrupts doCounts while the counts++ is happening, then the resetting of counts in counts = 0; might not happen.
Problem is that both interrupts both reads and writes counts.
...
Where do you get the input pulses on pin 22 from ? You write the you dont move the servo, something is sending out a pulsed signal ?
You should perhaps discard the first reading since you dont...
If the pins are in a single port you can do a read/modify/write update operation to the ouput data register to change only the bits/pins you are interested in a single write operation.
Its a complex process. Before the serial monitor can accept any data the USB hardware must do signalling handshakes, and then the operating system on your PC must realize a new USB device is...
Place the potVal[i] = EEPROM.read(bankAddr[i]); reads in the setup() function, and then create a 'save' function to store them back from a 'magical' user input.
Dont mix up the pot settings and...
You will also want to look into the debounce libraries, to make a single button press into what you want, a single button press.
The baudrate is not really important for Serial over USB, it all runs at full USB speed anyway. On some cards that uses serial to usb converters like Arduino UNO the baudrate affects the speed for...
This code might do what you want, I had no hooked up buttons so use 1 and 2 in serial monitor to simulate button presses.
int bankAddr[] = {10, 11, 12};
int buttonState1;
int...
So to be clear there are two buttons, one BankNumber button, scrolling 1 -> 2 -> 3 -> 1 -> 2 ... and one FirstSelectedPresetWithinBank button going through values 1 -> 4 -> 7 -> 1 ...
Since the...
Use one elapsedMillis or elapsedMicros for every activity that happens with regular intervals, and then check for events like USB inputs or file play status changes. Dont stop in a delay loop waiting...
Do you have a ground connection, there is none on your diagram ?
As it says, this is one way to generate the sequence of 64 bit pattern, and can be adapted for other patterns. The code only generates the bit patterns and displays them for inspection. It does not...
The following fairly simple code generates the shifted patter, SPI is replaced with prints
uint64_t registerBuffer;
uint64_t pattern = 0b11;
/* This will give two identical outputs as start...
With a sampling clock of 38.5 kHz then the period values have a time granularity of 25.97 uS.
Measuring a 110Hz signal, then gives an uncertainty of 0.3 Hz,
deltaf = 110 - 1/(1/110 + 1/38500) =...
You could add a FRAM SPI serial ram nonvolatile storage chip, claiming 100 trillion read/write cycle endurance
i am surprised that there has been no discussion of the FreqMeasureMulti library. The code is there and simple to test, so why not give it a try.
Teensy 3.2 and 3.6 have different mappings for PTC8. According to the schematics at https://www.pjrc.com/teensy/schematic.html
On 3.2 PTC8 is indeed Arduino pin 28
On 3.6 PTC8 is mapped to...
The boring suggestion, before building a PCB to control 8 stepper motors take the time and build a pcb for controlling a single stepper motor. Use this one to find out what mistakes you have made and...
Shot in the dark, discard any eventual incoming MIDI messages:
// MIDI Controllers should discard incoming MIDI messages.
while (usbMIDI.read()) {
}
Can you guarantee that there are no conditions, yield function activity, handling of USB interrupts, timers or other background activities, so that the main loop handling of (count==1000) condition...