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

Search:

Type: Posts; User: Nominal Animal

Page 1 of 5 1 2 3 4

Search: Search took 0.00 seconds.

  1. You're welcome! And sorry, I didn't realize...

    You're welcome!

    And sorry, I didn't realize you only needed to know the resistor sizes. Me fail English...

    Another option is to contact BuyDisplay/EastRising at...
  2. You'll want the 4-wire serial mode (easier SPI...

    You'll want the 4-wire serial mode (easier SPI mode, with Chip Select (CS), Data (MOSI/DO), Clock (CLK), and the fourth pin is a generic I/O pin that determines Command/Data mode), right?

    For...
  3. Are you talking about this one...

    Are you talking about this one, or some other module?
    EastRising/BuyDisplay has a LOT of different modules, so it is very important to be precise about which product you're talking about.
  4. The original FAT filesystem only supports file...

    The original FAT filesystem only supports file names with at most 8 characters, followed by a dot, followed by at most 3 characters.

    The way Windows added support for longer file names is via...
  5. Replies
    34
    Views
    1,355

    Thanks, vjmuzik! I know exactly why that...

    Thanks, vjmuzik! I know exactly why that happens. Indeed, it is very similar to what happens on Firefox; just with a much more noticeable delay.

    I think I'll have to do a test page with sixty or...
  6. Replies
    34
    Views
    1,355

    Yup, no worries; I can definitely understand why...

    Yup, no worries; I can definitely understand why the IT folks said that. (I used to be one. I don't use Chrome either, and have a completely fake/dedicated email address to use with Google stuff –...
  7. Replies
    34
    Views
    1,355

    Thanks a lot, Mark! I think replacing the bullet...

    Thanks a lot, Mark! I think replacing the bullet character with a small image would help with that cursor issue. You don't happen to use Chrome, do you? (Although that version of Edge already uses...
  8. Replies
    34
    Views
    1,355

    I have played with various ways to implement the...

    I have played with various ways to implement the interactive pinout card on a self-contained web page, but most approaches feel too clunky for me; that's why the long delay. However, I finally found...
  9. Replies
    40
    Views
    1,413

    I'm just glad to be of help. I've got another...

    I'm just glad to be of help. I've got another project going on – Teensy 4.0 and 4.1 interactive pinouts in a browser – so I'll concentrate on that for now. If you'd like me to try and find the bug...
  10. Replies
    40
    Views
    1,413

    As far as I can tell, we hit the kernel bug when...

    As far as I can tell, we hit the kernel bug when Teensy resets, and there is still data begin sent to the Teensy. If we could ensure the reset packet is the last one we try to send, immediately...
  11. Replies
    40
    Views
    1,413

    It's the same kernel use-after-free bug. When...

    It's the same kernel use-after-free bug. When the Teensy resets, some of the URB sent from the host to the Teensy need to be canceled. (acm_kill_urbs() in the oops, in this case.)
    Like I linked to...
  12. Replies
    40
    Views
    1,413

    To me, it looks like an actual Linux kernel bug,...

    To me, it looks like an actual Linux kernel bug, that occurs when an USB URB is canceled (because the device reset or vanishes).

    There is a relatively recent possibly related bug report on the...
  13. If you are referring to the 32-button limit per...

    If you are referring to the 32-button limit per USB Joystick, I recommend making your Teensy an USB Keyboard + Joystick pair, with the extra buttons producing standard keypresses.

    This thread has...
  14. Replies
    4
    Views
    340

    The effects in instruction timing (for Cortex-M4,...

    The effects in instruction timing (for Cortex-M4, PDF) you are seeing is a result of pipelining instructions within the Cortex-M4 core itself; i.e., at the lowest hardware level in the...
  15. (I haven't found any, and can't even find...

    (I haven't found any, and can't even find instruction timings for ARMv7 or FPv5 used on the i.MX RT1062 on Teensy 4.0 and 4.1.
    As far as I know, one would have to microbenchmark the various...
  16. Floats (Binary32) have 23 bits of precision, but...

    Floats (Binary32) have 23 bits of precision, but a 254-bit range.
    32-bit integers have 32 bits of precision and a 32-bit range, of course.
    If the absolute maximum signal range is known, then 32-bit...
  17. For that particular case, yes. On 32-bit...

    For that particular case, yes.

    On 32-bit microcontroller, it makes sense to use the 32-bit filter implementation only.
    On 8-bit microcontrollers, it makes sense to use the 16-bit filter if it...
  18. In C (as opposed to C++), one can use the...

    In C (as opposed to C++), one can use the following pattern. First, filter16.h:


    #if !defined(FILTER_NAME)
    #error Define FILTER_NAME as the name of the filter.
    #elif...
  19. Note: It looks like the state has to be an...

    Note: It looks like the state has to be an exact-width type (so uintN_t and not uint_fastN_t), as any extra bits will mess up the modulo arithmetic.

    The 16-bit state is intended for input samples...
  20. Do ignore my post #7: when I wrote that, I was...

    Do ignore my post #7: when I wrote that, I was obviously confusing a sliding window filter with the exponential moving average. (I'd edit it to correct it, but the grace period is over.)


    I...
  21. Here's a simple Python3 test bench anyone can...

    Here's a simple Python3 test bench anyone can experiment with:


    from random import Random
    from math import sin, pi

    class Source:
    __slots__ = ('prng', 'phase')

    def __init__(self,...
  22. Perhaps that was your intention, but fact is, the...

    Perhaps that was your intention, but fact is, the C++ implementation includes the rounding operation.

    Code to implement the above is different: you need to calculate average in fixed point as...
  23. Eh, what? I was describing a mathematical...

    Eh, what? I was describing a mathematical formula, not suggesting code.

    There is an important distinction here, by the way.

    The often used mathematical form

            state = (1 -...
  24. Exponential decay filtering,         average =...

    Exponential decay filtering,
            average = C·sample + (1-C)·average
    (where C is a real coefficient smaller than 1) is different to exponential moving average.

    Their main difference is that...
  25. No, OP's code is not right. A correct...

    No, OP's code is not right. A correct implementation would be


    constexpr int_fast16_t fractional_bits = 2;
    int_fast16_t heading = 0;

    int_fast16_t average_heading(int_fast16_t sample)
    {
    ...
  26. It is a common programming pattern for "animator"...

    It is a common programming pattern for "animator" functions to take a number as a parameter, describing the progress along the animation.

    However, looking at the code, neither drawRunAnim() nor...
  27. Replies
    34
    Views
    1,355

    Those are literally the same images;...

    Those are literally the same images; teensy41-sides.html links to the ones hosted here.


    True. I was thinking of the case when considering a pin on one side, and having to connect it from the...
  28. Replies
    34
    Views
    1,355

    OK! The first test is at...

    OK! The first test is at https://nominal-animal.net/teensy41/teensy41-pins.html, and the turning test at https://nominal-animal.net/teensy41/teensy41-sides.html.

    To repeat, the idea is that while...
  29. Replies
    34
    Views
    1,355

    Here's what I meant: 21007 saved as...

    Here's what I meant: 21007 saved as teensy-sides.html .
    (I realized I could make the SVG canvas a standard size, and reference the pin locations to that, then scale and rotate the JPEG images to...
  30. Replies
    34
    Views
    1,355

    I mean, if I add a button that changes the side...

    I mean, if I add a button that changes the side of the board shown –– and yes, pin positions will change, and effectively left and right side labels etc. swap places –– the image jumps, because the...
  31. Replies
    34
    Views
    1,355

    I know, defragster; the issue is that it is...

    I know, defragster; the issue is that it is slightly different size to the back one, so swapping them in place creates a jarring "jump" effect.
    I'd like big enough pictures I could rotate and scale...
  32. If draw_state is some unsigned integer type, then...

    If draw_state is some unsigned integer type, then (draw_state >> 3) == (draw_state / 8), and ((draw_state & 7) == (draw_state % 8)) (modulo, i.e. remainder if divided by 8).


    draw_state │...
  33. Replies
    34
    Views
    1,355

    Does anyone have higher-resolution front and back...

    Does anyone have higher-resolution front and back images of Teensy 4.1? I don't have one (yet), so I can't take my own pics either.
    I'd like to crop/rotate/scale them so that they match, and make...
  34. Replies
    34
    Views
    1,355

    I was too lazy to add more than the GND and SPI1...

    I was too lazy to add more than the GND and SPI1 pins, but at least you can see how this would work.
    I rotated https://forum.pjrc.com/teensy41_2.jpg, cropped it, and saved as a 199×704 pixel JPEG...
  35. Replies
    34
    Views
    1,355

    You know, I'd be happy to try and whip up an...

    You know, I'd be happy to try and whip up an example interactive page (client-side/browser only, will work fine even if saved as a local file) to show the different options, with tooltips/rollovers...
  36. Unfortunately, like I already mentioned most of...

    Unfortunately, like I already mentioned most of the motor controller drivers (including DRV8825) and even CNC/3D printer boards like SmoothieBoard use a common ground for motors and logic.

    The...
  37. There is no issue, as long as you explicitly...

    There is no issue, as long as you explicitly specify which byte order you use in the transfers.

    On some host hardware architectures, accessing an unaligned float may not work, and byte order...
  38. Ground potential difference (and thus a ground...

    Ground potential difference (and thus a ground loop) is a likely culprit.

    A simple fix is to get yourself a cheap ADuM3160-based USB isolator between Teensy and the host computer. It will limit...
  39. Replies
    13
    Views
    1,201

    I mean 3 distinct APIs. Whether you want it all...

    I mean 3 distinct APIs. Whether you want it all in one library, or split the crypto hash to a separate one, I do not know.

    With a tested ISAAC-based PRNG, I'd be happy with a single one.

    The...
  40. (I am not ashamed to admit that I use K to remind...

    (I am not ashamed to admit that I use K to remind me which side is the cathode, and A to remind me which side is the anode, in a diode or a LED.)

    (I haven't found a good one for polarity yet. The...
  41. Replies
    13
    Views
    1,201

    For non-cryptographic work, I recommend using one...

    For non-cryptographic work, I recommend using one of the Xorshift variants; many of them are as random as Mersenne Twister, but much faster. In fact, my preferred one, using only the 32 high bits of...
  42. My ping-pong...

    My ping-pong test shows that Teensy 4.0 has issues at high-bandwidth 1024-byte messages, but it does not tell us where the problem is.

    When you suggested testing transfers in just one direction...
  43. No worries! Anyway, here is the Teensyduino...

    No worries! Anyway, here is the Teensyduino sketch for Teensy 4.0 with USB Serial:


    // SPDX-License-Identifier: CC0-1.0

    #define SEED 1
    #define SIZE 512

    static uint64_t state;
    static...
  44. Ah, right; with 512 byte packets, even this old...

    Ah, right; with 512 byte packets, even this old HP Pavilion 11 x360 can do 270 Mbits/s (34 Mbytes/s) locally. I bet an i5/i7 or a relatively recent AMD can do >480Mbits/s locally with 512 byte...
  45. @KurtE, @defragster -- If you happen to have a...

    @KurtE, @defragster -- If you happen to have a fast-ish Linux machine (virtual machine is perfectly okay), you might wish to test the following program pair. I finished these first; I'll implement...
  46. Replies
    3
    Views
    246

    I agree with Frank B. It turns out it is...

    I agree with Frank B.

    It turns out it is usually easier to construct the value using integer types, and convert it to double when needed for computation. One would use something like the...
  47. Me too, that's why I do tests using raw termios...

    Me too, that's why I do tests using raw termios on Linux.


    Excellent idea; doing one-way tests will tell us a lot more about exactly what is happening.

    Unfortunately, I just noticed I have a...
  48. No, there are odd issues even with C code that...

    No, there are odd issues even with C code that can easily handle the full USB bandwidth (using termios in Linux), but keels over with Teensy 4.0.

    It looks like a "lockup" of some sort when either...
  49. Replies
    12
    Views
    732

    I've used an awk scriptlet to do this. While you...

    I've used an awk scriptlet to do this. While you can use the C preprocessor (avr-cpp in Arduino, arm-none-eabi-cpp in Teensyduino) to do all preprocessing, it is easier to write a simple awk script...
  50. Replies
    2
    Views
    570

    Do you need to generate the sample clock also, or...

    Do you need to generate the sample clock also, or just the -0.3V/+0.3V sync pulses/pulse pairs?

    If we look at just the sync pulse (pair) itself, starting at 0V (idle):

    The output drops to...
Results 1 to 50 of 224
Page 1 of 5 1 2 3 4