Search results

  1. M

    Potentiometers not giving full range: 4 - 1008 only

    Two possibilities: mechanical construction - some dead track at each end before the metal contacts? Or there are IR drops on the power and ground wires so that the faders don't see the full supply range. Star grounding is the usual cure for this.
  2. M

    How to change the output_i2s2.cpp file to make it left-justified I2S

    Maybe start here (the link is in the comments to output_i2s.cpp) https://forum.pjrc.com/threads/65229?p=263104&viewfull=1#post263104
  3. M

    100 +/- inputs and outputs (analog?)

    Analog multiplexer for the inputs, PWM expander for the bulbs (using white LEDs will greatly simplify driving these lights).
  4. M

    A little help with a schematic for the Audio Shield 4.x Rev. D?

    The pots have ground and supply switched too I think, caps normally to ground.
  5. M

    Teensy 2.0 hi-Z outputs?

    pinMode(pin, INPUT) is high-Z.
  6. M

    Attempting to remove high frequencies using I2S microphone INMP441 and the teensy 4.1 board

    Just give some Python examples for generating sos (second-order-sections aka biquad sections) with scipy.signal, very flexible, mirrors the functionality in Matlab... You probably don't want to lump this functionalty on the Teensy itself, especially with the heavy-lifting needed for FIR filter...
  7. M

    Attempting to remove high frequencies using I2S microphone INMP441 and the teensy 4.1 board

    Not necessarily, use a Cauer (elliptical) filter, rather than cascading 2nd order Butterworth stages. You can get much steeper filter skirts this way, although phase distortion is higher and there is pass-band ripple. This is 6th order Cauer with 1dB pass-band ripple and 60dB stop-band...
  8. M

    cube 15x15x15

    So the data signal and signal ground aren't run alongside each other? That could lead to large loop areas and lots of stray inductance on the digital signal.
  9. M

    An alternative to the obsolescent CS42448: the PCM3168

    C46/47/50/52 provide very low impedance (at HF) to the ADCs while they are sampling - usually needed to get to datasheet levels of SNR. The opamp by itself will have quite high output impedance at HF, allowing ADC input currents to inject noise into the signal they are trying to measure - at...
  10. M

    cube 15x15x15

    How are you routing signal ground?
  11. M

    Securely Storing Product Information (Serial, Product Details, etc)

    You can buy unique ID chips (often used for ethernet MAC addresses), and just log the ID at commissioning time in your database.- the chips are read-only and unique, often OneWire or I2C I think. Given a suitable driver that ought to be readable in /dev/<something-or-other> If you want to write...
  12. M

    Is it possible to make a poly synth with ladder filters?

    T4's can do 1200 instructions per microsecond on a good day - yes it will make a huge difference to throughput.
  13. M

    I2S Input Downsampling

    It must be clocked at 2.048MHz to 4.096MHz, meaning it can handle 44.1kSPS and 48kSPS, not a low rate though. So its decimation filter is limiting to 20kHz basically. You'd have to take those samples and further decimate.
  14. M

    RESOLVED - T4.1 using Bounce2, boolean operators not working as expected.

    Normally you'd code a state machine and use pressed() to trigger state changes - each state would test some subset of the buttons relevant to that state. Only if you need to know when a button is released would you need the extra complication of using isPressed() - you'd have to determine button...
  15. M

    I2S Input Downsampling

    Yes, a decimation filter. Just selecting every 6th sample or whatever will mean lots of aliasing all across the band of interest. If the relevant ADC can work at 8k or 11.025k that's also an option (the device will have its own internal decimation filter if its a sigma-delta chip, which I2S...
  16. M

    RESOLVED - T4.1 using Bounce2, boolean operators not working as expected.

    The pressed() method returns true once when the button has just changed to being pressed - you can't call it twice in succession as you'd clear the state by the second call. You could use isPressed() method, but then you have to debounce yourself. You are overthinking this, the correct...
  17. M

    Display options with minimal switching noise ?

    LEDs are far noisier as the current being switched is large and there are many segments, ePaper is one possibility - only active when updating, although slow to update. Maybe use a separate display module with serial graphics commands?
  18. M

    Understanding Low Pass Filter On Analog Input

    That style of dynamically adjusting filter may introduce distortion (as its not a linear time-invariant system). Sometimes that may matter, but not for the intended application, tracking movement.
  19. M

    Changing the volume pin

    Audio Adapter rev D/D2? No, its hard wired on the PCB. If you don't piggyback the adapter you could wire it however you like though.
  20. M

    Teensy 4.1 Pins

    A single position switch doesn't do anything (!) - do you mean single-throw? A diode-switch array can be used to scan multiple switches using fewer pins, ie a 4x4 array allows 16 switches to be sensed by 8 pins. IO expander chips also allow multiple inputs to be sensed using for instance the...
  21. M

    FFT not working properly

    But the data (#20) clearly has low frequency content, not just a DC offset...
  22. M

    FFT not working properly

    In post #15 for function loop() you've got braces in the wrong place (doesn't match indentation).
  23. M

    Encoder - detect single or dual inputs

    Not going to work if that encoder pin happens to be open circuit at the time of the test - as I said there is no precise way to distinguish the cases for standard encoders.
  24. M

    FFT not working properly

    The FFT is going to dominate compute time. Hamming isn't my choice of a window function. Hann window is widely used for basic use, if you want accurate peak values a flat-top window is required. Alas many systems have a low quality flat-top window with limited dynamic range, and don't let you...
  25. M

    FFT not working properly

    The low frequencies will be due to the DC offset - the peak value is often bin 1 for a naive FFT with a big DC offset. Removing DC offset is simple, subtract the mean from every sample.
  26. M

    Encoder - detect single or dual inputs

    There is no precise way since a single input produces a signal indistinguishable from a quadrature encoder oscillating back and forth. You could have a statistical test on the assumption such oscillation is too rare to worry about. Simply count the transitions on the input, and reset the count...
  27. M

    FFT not working properly

    One point to note, SAMPLES must be a power of two.
  28. M

    SPI frequency too low for real-time data acquisition

    That's for full bandwidth for each chip I guess - more microcontrollers these days have quadSPI for instance.
  29. M

    High speed quadrature encoder issue (Teensy 4.0)

    You need CHANGE interrupt, but you can just trigger on A for the interrupt if you don't mind 1/2 the resolution. Triggering only on rising edges is distinctly odd timing - draw the waveforms and you'll see... BTW if the encoders are on a long cable you'll need stronger pullup resistors than...
  30. M

    Triggered I2S

    Interrupt driven code to pull samples from the I2S hardware. Reading up on the SAI units in the i.MX RT1060 manual (link in the T4 product pages). Some of the setup for these can probably be adapted from the AudioInputI2S class.
  31. M

    Teensy 4 power supply

    Well it would help to identify this mystery chip so we're all on the same page...
  32. M

    Suggestions for recording data

    I'd suggest sampling the data interrupt driven and putting in a circular buffer - then the main code pulls data from the buffer to write out - this allows for slow SD card access etc. SD cards in particular can occasionally take a long time to respond, you need a buffer large enough for this...
  33. M

    Triggering problem

    Well the audio sample time is more than twice that...
  34. M

    Triggering problem

    So you do need to synchronize 12 Teensy's - what time resolution?
  35. M

    Triggering problem

    I guess an input class that samples a pin using DMA and sets the output stream to 0 or 1 audio values, then that could be handled like any other audio stream. But that would have different latency from any particular ADC or DAC... But I'm not sure what you are trying to do exactly, Can you...
  36. M

    Triggering problem

    It would have to be interrupt driven to do that.
  37. M

    Triggering problem

    Sounds like a custom audio class is needed then.
  38. M

    Teensy 3.2 End Of Life

    I suspect during the chip shortage they prioritized the chips that were required by major industries like car makers and white-goods, no big mystery really.
  39. M

    Triggering problem

    This sounds as tricky as USB audio synchronization. You have two independent instances of the audio chain on the two boards. BTW why are you wanting this to work to better than 3ms resolution - that's usually fine for the human ear.
  40. M

    Teensy 4.1 SD.open failing to create files randomly

    Code is also faulty - you call close on a null pointer....
  41. M

    Triggering problem

    You're not synchronizing to the audio system I think. Since blocks by default are about 3ms that's enough jitter to fully randomize the phase of a 1kHz signal. The audio chain updates on that 3ms period with the default 128 samples-per-block setup.
  42. M

    Audio transfer line from External device to Teensy 4.0 to Headphones

    Just be aware that the headphone jack is for headphones/earbuds only, do not use it as a line output, it will not work. G = ground, L = left, R = right for the line inputs and outputs BTW
  43. M

    How can we program for changing wav file playback speed with Teensy4.0 + Audio Adaptor Boards?

    Try the search term "rate conversion" for that. Reverse play is going to involve seeking in the wav file and reversing blocks in memory before feeding to the audio chain. Do you want to play at fixed speeds, or continuously variable? Speed-up or slow-down?
  44. M

    T4.1 Ethernet and the DP83825IRMQT footprint

    If there are vias the solder will wick into them and allow the chip to settle down, probably OK with solder covering the whole pad when that happens - surface tension does the work with SMT. WIthout vias bad things are indeed likely.
  45. M

    Need advice on PCB manufacturers

    cheapest and quickest are mutually incompatible I'm afraid. OSHPark are worth a look for convenience and price, their web portal parses the files and shows you what you'll get visually which is handy.
  46. M

    Teensy 4.0 5v Serial Tolerance?

    The only part of the chip that can handle 5V is the USB interface, the I/O pins are strictly 3.3V and its very easy to damage the chip if you exceed this, either through direct over-voltage damage or CMOS latchup caused by excessive protection diode current. Level shifting is the way to go, and...
  47. M

    Measuring RPM using a 3144 hall effect sensor gives odd +/- error

    You disable interrupts across the Serial output, I don't think that's a good idea - keep the critical section(s) as short as possible: cli(); uint8_t count = PulseCount; uint32_t ticks = PulseEndTime - PulseStartTime; sei(); if (count > 3) { /// do the calculation and printing here while...
  48. M

    Have I broke my teensy 4.1 board ?

    400C will char FR4 under a trace rapidly - I would never recommend running that hot for PCBs - proper temperature controlled iron is the best approach, and decently designed bits, not super thin pointy ones. Practice on scrap PCBs is a great idea - you can experiment with different...
  49. M

    Teensy 4.0, 'disabling' an analogRead pin

    Just lose it, you need the cap direct on the analog pin for best performance. The divider provides current limiting anyway.
Back
Top