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

Search:

Type: Posts; User: ryanrs

Search: Search took 0.00 seconds.

  1. Replies
    15
    Views
    224

    Mac OS 10.13.6 on an old mac pro. Java...

    Mac OS 10.13.6 on an old mac pro.

    Java exception on first run. Teensyduino.app starts and automatically opens the last sketch I was working on. I let it sit idle for ~30 secs, then the exception...
  2. Replies
    15
    Views
    730

    Great! I'll test out both fixes in beta 9.

    Great! I'll test out both fixes in beta 9.
  3. Replies
    58
    Views
    1,765

    Here's test code for memcpy....

    Here's test code for memcpy. It's simple and 100% reproducible.

    Thanks for looking at these bugs.
  4. Replies
    58
    Views
    1,765

    For memcpy, I have not dug through the ARM...

    For memcpy, I have not dug through the ARM assembly. But if it's like other memcpy implementations, there is a code path for when the src and dst are not relatively aligned (src % 4 != dst % 4). For...
  5. Replies
    58
    Views
    1,765

    There are two bugs discussed in my support thread...

    There are two bugs discussed in my support thread.

    One is a memcpy bug from 2014 or earlier, that Frank B mentioned had been fixed, then un-fixed in the intervening years. Basically memcpy is...
  6. Replies
    58
    Views
    1,765

    So what's the process to get bug fixes into the...

    So what's the process to get bug fixes into the teensy core library? I've spend a fair amount of time debugging a couple problems I've run into, but it kinda feels like I'm posting into the wind over...
  7. Replies
    15
    Views
    730

    OK, I believe I know what's going on. At -O2, the...

    OK, I believe I know what's going on. At -O2, the compiler is re-ordering assignments to bdt_t.addr and bdt_t.desc. If we're unlucky, the USB engine grabs the bdt_t between writes and gets the old...
  8. Replies
    15
    Views
    730

    Ah ha! usb_dev.c // This code has a known...

    Ah ha!

    usb_dev.c

    // This code has a known bug with compiled with -O2 optimization on gcc 5.4.1
    // https://forum.pjrc.com/threads/53574-Teensyduino-1-43-Beta-2?p=186177&viewfull=1#post186177...
  9. Replies
    15
    Views
    730

    OK, I am back with a fresh Linux dev environment...

    OK, I am back with a fresh Linux dev environment to exclude the possibility of Mac USB weirdness. Here's the current setup:

    Raspberry Pi 4 B booting off a SATA SSD via USB 3 adapter
    Raspberry Pi...
  10. Replies
    15
    Views
    730

    That sounds like an excellent fix.

    That sounds like an excellent fix.
  11. USB hubs have many strange and infuriating...

    USB hubs have many strange and infuriating behaviors. Never trust one.
  12. I've had a usb hub "blacklist" a teensy for...

    I've had a usb hub "blacklist" a teensy for whatever reason. Required the hub to be power cycled before it'd let the teensy connect again. Definitely try rebooting the computer and power cycling any...
  13. Replies
    15
    Views
    730

    Here's a quick test case for the memcpy...

    Here's a quick test case for the memcpy 0x20000000 bug ShadowLight8 mentioned. Sure enough, memcpy fails.


    #include <Arduino.h>

    uint8_t big_buf[40 * 1024];

    #define PIN_LED 13

    // Enable...
  14. Replies
    15
    Views
    730

    Oh yeah, unaligned read across that boundary, I...

    Oh yeah, unaligned read across that boundary, I can see how that could trigger a fault.

    You can probably tell the linker to park an unused int32 at 0x20000000 to prevent any objects from...
  15. Replies
    15
    Views
    730

    I gave it a quick try on my raspberry pi pi-hole...

    I gave it a quick try on my raspberry pi pi-hole server. Not the greatest environment, but it's what I have handy.

    Linux raspberrypi 4.19.118-v7l+

    I didn't install Arduino or Teensyduino, just...
  16. Replies
    15
    Views
    730

    Thanks for the excellent tip, ShadowLight8! ...

    Thanks for the excellent tip, ShadowLight8!

    For my test case, very little memory is used. The array of hashes is in flash. I don't think anything crosses that boundary.

    Here's the symbol list,...
  17. Replies
    15
    Views
    730

    Haunted USB Serial on Teensy 3.2

    The Bug

    During rx buffer starvation, usb serial will corrupt ~0.01% of packets received from the host.

    (skip ahead to "The Fix" if you want a fairly wild tldr)

    Tools

    Bare Teensy 3.2...
  18. My main complaint right now is that the first...

    My main complaint right now is that the first prototype worked so well that it was put into use 2 days after I built it. So now I'm waiting on a digikey order so I can make another one and continue...
  19. They're just plain old red LEDs in a 25x11...

    They're just plain old red LEDs in a 25x11 matrix. I use 2x 595s + mosfets as row drivers, and 2x CAT4016 current sinks to drive the columns.

    1.0 / (5us * 255 brightness levels * 11 rows) = 71.3...
  20. And the transmit code: const uint16_t* p =...

    And the transmit code:


    const uint16_t* p = framebuffer.phases[y][ph].data.shorts;
    KINETISK_SPI0.PUSHR = p[0] | SPI_PUSHR_CTAS(1);
    KINETISK_SPI0.PUSHR = p[1] | SPI_PUSHR_CTAS(1);...
  21. Answering my own question: // We don't...

    Answering my own question:


    // We don't care about CS, so set it to unused pin 24 (bottom side smd pad)
    SPIFIFO.begin(24, SPI_CLOCK_24MHz);

    // assign SCK to alternate pin 14
    ...
  22. What do I need to change in SPIFIFO.h to use...

    What do I need to change in SPIFIFO.h to use Teensy 3.2 alternate SCK on pin 14? I tried looking through SPI.cpp, but I'm having trouble understanding how the pin mux(?) is setup.

    I'm just looking...
  23. Oh wow, that's even better! I thought you were...

    Oh wow, that's even better! I thought you were probing SCK, not MOSI. So it's more like 20% CPU usage in the interrupt.
  24. Hi Paul. The bottom trace looks like 64 clocks @...

    Hi Paul. The bottom trace looks like 64 clocks @ 16 MHz, is that right?

    What cpu speed did you use for the test? I've heard the 3.2 is pretty stable at 96 MHz and 24 MHz SPI would be great (slave...
  25. Thanks so much, Frank and Paul. ~50% cpu will be...

    Thanks so much, Frank and Paul. ~50% cpu will be great!
  26. Fastest way to send 6 bytes over SPI on Teensy 3.2

    What's the fastest way to send 6 bytes over SPI? I see DmaSpi, SPIFIFO, and some other libs.

    I am using a Teensy 3.2. My application is transmit only, always 6 bytes, and no other devices/libs...
Results 1 to 26 of 27