Forum Rule: Always post complete source code & details to reproduce any issue!

Search:

Type: Posts; User: jonr

Page 1 of 10 1 2 3 4

Search: Search took 0.01 seconds.

  1. > What do I search on google to learn more about...

    > What do I search on google to learn more about this??

    Maybe you don't want to go quite this far, but a great way to learn about circuits is to type them into LTSpice and and try things and see...
  2. Thread: Teensy 16bit ADC

    by jonr
    Replies
    31
    Views
    488

    Agreed. If you expect to calibrate and then get...

    Agreed. If you expect to calibrate and then get 16 bit accurate readings a week later, then you need to test over a similar time period and variations in conditions. Don't take a msec of data and...
  3. Thread: Teensy 16bit ADC

    by jonr
    Replies
    31
    Views
    488

    That's similar to the 15.5 bits I got with a good...

    That's similar to the 15.5 bits I got with a good external ADC running from a battery.
  4. Thread: Teensy 16bit ADC

    by jonr
    Replies
    31
    Views
    488

    > If the signal has random uncorrelated white...

    > If the signal has random uncorrelated white noise

    Which based on my tests (good results to a point and then it gets no better), it isn't. But it was a different teensy setup. so I'm curious...
  5. Thread: Teensy 16bit ADC

    by jonr
    Replies
    31
    Views
    488

    > Can you give me an example of how this is done?...

    > Can you give me an example of how this is done?

    Second that - let's see a program and output yielding 16 bit results from a teensy with 256x oversampling.
  6. Thread: Teensy 16bit ADC

    by jonr
    Replies
    31
    Views
    488

    > if you average 256 times, you gain 4 bits ...

    > if you average 256 times, you gain 4 bits

    Only if the noise is high freq, white noise - and it often isn't either one. Go ahead, try it.
  7. > havenít used all of the decoupling caps I...

    > havenít used all of the decoupling caps

    I don't have definitive data, but I think they are necessary.

    Not sure that the crystal will work without a PCB.
  8. Thread: Teensy 16bit ADC

    by jonr
    Replies
    31
    Views
    488

    Unless you happen to synchronize perfectly, 1Hz...

    Unless you happen to synchronize perfectly, 1Hz noise doesn't average out if you average over anything close to 1 second.
  9. Thread: Teensy 16bit ADC

    by jonr
    Replies
    31
    Views
    488

    > can increase the effective number of bits in...

    > can increase the effective number of bits in some circumstances.

    Exactly - I once tried it with a teensy and averaging only helped somewhat - it stopped providing improvement after a point far...
  10. Thread: Teensy 16bit ADC

    by jonr
    Replies
    31
    Views
    488

    No teensys have have 16 bit ADC.

    No teensys have have 16 bit ADC.
  11. Thread: Teensy 16bit ADC

    by jonr
    Replies
    31
    Views
    488

    Amazon and Ebay have many that can be made to...

    Amazon and Ebay have many that can be made to work as a separate board wired to a teensy. But has anyone actually measured 16 bits of SNR from such a module?
  12. Replies
    4
    Views
    241

    I tried it and variations in "time-to-change"...

    I tried it and variations in "time-to-change" also detects shorts to another pin, even with no change to the length of the connected wire. Since both pins change timing, which input pin it is...
  13. Replies
    4
    Views
    241

    Thanks, that's a good idea to look for shorts. ...

    Thanks, that's a good idea to look for shorts.

    On a T4, this code can detect whether or not a pin has < 1 inch of wire connected to it.


    for (register int i = 0; i <= 33; ++i) {

    ...
  14. 100 ohm resistors (for a total of 800 ohms) will...

    100 ohm resistors (for a total of 800 ohms) will be more stable than 1K. Also make sure that the front and rear buss bars don't vary in voltage.
  15. Replies
    4
    Views
    241

    Software to debug teensy hardware

    I design/build custom circuits, some use teensy modules and some are custom designs based on the same MCU/bootloader. Not surprisingly, there can be yield issues and a few don't work. So I'm...
  16. I added a PSRAM chip today and your program...

    I added a PSRAM chip today and your program reports 8Mbyte. That leaves bad soldering, a bad chip, orientation, location, ??
  17. Replies
    90
    Views
    20,504

    Since flash_wait() is Paul's core code, I'll...

    Since flash_wait() is Paul's core code, I'll follow his lead and not change code to work around what appears to be a compiler issue. For now, note that you may need different optimization settings...
  18. If noise is a concern, make it fully differential...

    If noise is a concern, make it fully differential (preamplifier and ADC). Treat both lines exactly the same (actives, passives, routing, etc). Actually achieving > 16 bits is not so easy.

    The...
  19. Replies
    5
    Views
    171

    Perhaps someone could comment as to whether 100K...

    Perhaps someone could comment as to whether 100K in series plus the internal diodes would adequately protect the input.
  20. Replies
    2
    Views
    180

    Depends on how much current you expect to draw -...

    Depends on how much current you expect to draw - but matching the physical size and 100Mhz rating of the teensy ones is a reasonable choice.

    Physically larger sizes will provide more noise...
  21. Can you share some specifics wrt cpu and memory?...

    Can you share some specifics wrt cpu and memory?

    My understanding is that as you use less taps, you lose resolution in the low frequencies. Depends very much on what you want to do, but I use...
  22. I'm curious as to why 16 bit linear isn't enough...

    I'm curious as to why 16 bit linear isn't enough - it's all the range you can hear in most environments.

    If you do non-linear analog->digital, make sure the processing is stable and sufficiently...
  23. Replies
    8
    Views
    323

    Nice. I suggest sticking with the T4 - same...

    Nice. I suggest sticking with the T4 - same price and it's likely that with future features, speed is helpful.
  24. Replies
    13
    Views
    321

    Something like this: ADC::Sync_result sr; ...

    Something like this:


    ADC::Sync_result sr;

    adc->adc0->setAveraging(1); // set number of averages
    adc->adc0->setResolution(12); ...
  25. Replies
    13
    Views
    321

    Only needing 400 ksps, you have plenty of room to...

    Only needing 400 ksps, you have plenty of room to adjust settings for better precision. Do use low source impedance (say 1K) and both ADCs in parallel (for a 2X speedup).
  26. Replies
    13
    Views
    321

    > for the internal adc of the T4.0 I have 17...

    > for the internal adc of the T4.0 I have 17 micro sec

    It will go fast enough for you - you just need the right settings.
  27. As the OP shows, floating point allows clearer...

    As the OP shows, floating point allows clearer code - use it if you your application isn't near the cpu capacity limit.
  28. Thread: Teensy 4.1 JTAG

    by jonr
    Replies
    1
    Views
    217

    No, but this will give you most debug features. ...

    No, but this will give you most debug features.

    https://forum.pjrc.com/threads/61373-Using-GDB-with-Teensy-without-hardware-debugger-first-Beta?highlight=gdbstub
  29. Be careful when using 16 bits - your input sample...

    Be careful when using 16 bits - your input sample range is limited. For example, -1024 to 1023 (??) for the code in #21. Some comments or checks would be a good idea.
  30. Replies
    32
    Views
    909

    I looked at and compiled DD4WH's fast convolution...

    I looked at and compiled DD4WH's fast convolution code (but didn't listen). Seems like the way to go. Convolution provides for *any* linear time invariant effect - equalization, reverb, etc. Or...
  31. The "Exponential Moving Average filter"...

    The "Exponential Moving Average filter" implementation using integers is slick - on a T4, about 2x faster than the simple float version.
  32. Replies
    32
    Views
    909

    I'm still struggling to find a solution (and...

    I'm still struggling to find a solution (and understand - I've never used teensy audio).

    Ideal for me would be SPDIF input and output plus teensy4 software performing convolution (say 8192 taps,...
  33. +1 on this. Maybe there are occasional...

    +1 on this. Maybe there are occasional exceptions, but the general rule should be that code compiles without warnings.
  34. > that's 2 multiplies, whereas the the "average...

    > that's 2 multiplies, whereas the the "average += k * (sample-average)" approach is only one multiply

    In yet another case of it not being wise to outguess the compiler, the mathematically...
  35. If speed is an issue, do use a power of two. But...

    If speed is an issue, do use a power of two. But keep your code more readable and let the compiler worry about replacing division/multiply with a shift.
  36. Replies
    8
    Views
    387

    Sorry to sound so picky, but pin 1 of U3 has the...

    Sorry to sound so picky, but pin 1 of U3 has the same problem. Maybe move C1 down there.
  37. A wild guess - it's the speed of the teensy. I'd...

    A wild guess - it's the speed of the teensy. I'd try adding more delays, for example at the beginning and end of ShiftOut().
  38. Found a better Schottky diode. About the same...

    Found a better Schottky diode. About the same leakage as a BAT54 but still protects to 50+V with a 1K series resistor. NSR05F20NXT5G
  39. You need to make some use of returned data so the...

    You need to make some use of returned data so the compiler doesn't optimize it away. Then you will see that the use of assembly/bfi is faster.
  40. Looks like the amount of leakage current with...

    Looks like the amount of leakage current with schottky diodes will cause linearity errors that would be hard to calibrate out. More accurate to use a TVS followed by an over-voltage protected...
  41. Building on what you said, I get ~100V of...

    Building on what you said, I get ~100V of protection when using a SDM40E20LS, even with a 1K resistor (a better choice than 10K given ref manual recommendations for input resistance).

    Since the...
  42. I encourage you to review this and how it is much...

    I encourage you to review this and how it is much faster.


    #define IMXRT_GPIO6_DIRECT (*(volatile uint32_t *)0x42000000)

    // rearrange 16 GPIO6 pin inputs into 16 consecutive bits
    // move...
  43. Replies
    32
    Views
    909

    Yes, the impulse response of the speaker system...

    Yes, the impulse response of the speaker system is measured, this impulse is processed into a "correction impulse", then music is convolved with the correction impulse to get flat speaker response....
  44. Replies
    32
    Views
    909

    While 65k taps is a common number for audiophile...

    While 65k taps is a common number for audiophile convolution based equalization, perhaps someone could talk about the audible effects of going down to something the teensy4 could handle. Looking at...
  45. You can eliminate the effect of interrupts by...

    You can eliminate the effect of interrupts by surrounding the code with cli() and sei().
  46. Replies
    19
    Views
    371

    See here for parallel reads of a T4 GPIO without...

    See here for parallel reads of a T4 GPIO without the reference manual.

    https://forum.pjrc.com/threads/58377-Reading-multiple-GPIO-pins-on-the-Teensy-4-0-quot-atomically-quot
  47. > connect one ADC to a voltage reference and read...

    > connect one ADC to a voltage reference and read the signal on the other

    Yes, ideally with the voltage reference being near the signal source and both lines treated exactly the same (ie,...
  48. Replies
    32
    Views
    909

    Looks like it's an application that needs...

    Looks like it's an application that needs floating point SIMD instructions.
  49. Replies
    32
    Views
    909

    Thanks. Some background on it is here: ...

    Thanks. Some background on it is here: https://torger.se/anders/brutefir.html#bruteconv

    I use it for digital room correction (DRC) of speakers - which I highly recommend to anyone interested...
  50. Replies
    32
    Views
    909

    My desktop does a 65536 tap fir filter on 44 kHz...

    My desktop does a 65536 tap fir filter on 44 kHz stereo with 1.5% cpu (with BruteFIR). But I take it that a T4 couldn't do it, even at 100% cpu?
Results 1 to 50 of 468
Page 1 of 10 1 2 3 4