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

Search:

Type: Posts; User: luni

Page 1 of 10 1 2 3 4

Search: Search took 0.01 seconds.

  1. Replies
    60
    Views
    13,483

    If you refer to the EncSim binaries: here they...

    If you refer to the EncSim binaries: here they are: https://github.com/luni64/EncSim/tree/master/examples/SerialControl/precompiled_binaries

    Regarding your question about the max count rate: ...
  2. Thread: TeensyTimerTool

    by luni
    Replies
    299
    Views
    39,656

    Difficult to debug without code. Can you post an...

    Difficult to debug without code. Can you post an example showing the issue?
  3. Thread: TeensyTimerTool

    by luni
    Replies
    299
    Views
    39,656

    DMA based Pulse Generator for T4.x boards

    I added an alpha version of a DMA based pulse generator to the TimerTool (it lives in the PulseGenerator branch). Currently, it only works on the pins which can be driven by the TMR / QUAD timers....
  4. Replies
    9
    Views
    572

    I also would prefer USB-C. Especially since good...

    I also would prefer USB-C. Especially since good USB cables for the 480MBit T4.x boards tend to be quite stiff.

    While waiting I use this:

    2647026471
    https://github.com/luni64/USB-C---MicroB...
  5. Thread: TeensyTimerTool

    by luni
    Replies
    299
    Views
    39,656

    TeensyTimerTool v0.4.1

    There is a new release (v0.4.1) of the TimerTool: https://github.com/luni64/TeensyTimerTool/releases

    Main new features:

    Destructors should work now -> you can define your timer locally....
  6. Replies
    9
    Views
    359

    The TimerTool IS using hardware timer/interrupts...

    The TimerTool IS using hardware timer/interrupts and 'tweaks the registers' (only the TCK timers are software based). If you want to roll your own, this https://github.com/manitou48/teensy4 is a very...
  7. Replies
    9
    Views
    359

    10MHz is not really feasible. The IMXRT processor...

    10MHz is not really feasible. The IMXRT processor needs a lot of time to sync the peripheral bus and the 'main' bus in an interrupt. Using the TCK timers (purely software, no interrupts) you can get...
  8. Replies
    9
    Views
    359

    The TimerTool timers accept floats as duration: ...

    The TimerTool timers accept floats as duration:



    PeriodicTimer t1(TCK); // or any other timer module

    t1.begin(ISR_x, 0.5); // 500ns

    // Or, if you prefer std::chrono literals: ...
  9. Those functions are (currently) not implemented...

    Those functions are (currently) not implemented for all timers (the PITs should work). Anyway, you should get an corresponding error message. To activate Error handling just add


    void setup()
    {...
  10. I was thinking of something simple like...

    I was thinking of something simple like (untested):



    #include "Arduino.h"
    #include "FreqMeasure.h"
    #include "TeensyTimerTool.h"
    using namespace TeensyTimerTool;

    constexpr uint8_t outPin =...
  11. Does the generated 96Hz signal need to be...

    Does the generated 96Hz signal need to be phaselocked?
    If not, couldn't you simply measure the input frequency and generate the double one with a periodic timer?
  12. Replies
    17
    Views
    685

    Thanks Frank, wasn't aware of that. Here a link...

    Thanks Frank, wasn't aware of that. Here a link if someone is interested in details: https://developer.arm.com/documentation/dui0040/d/ch05s04s03
  13. Replies
    9
    Views
    583

    Here you are:...

    Here you are: https://github.com/luni64/VisualTeensy/releases/tag/v1.4.0

    You can switch now between the standard newlib and newlib-nano in expert settings mode:

    26209
  14. Replies
    17
    Views
    685

    Yes, if all numbers are smaller than 11 the...

    Yes, if all numbers are smaller than 11 the second code is more efficient. For i > 11 the first one wins since the conditional expressions (those ending LS) are not executed. Anyway, my experience...
  15. Replies
    17
    Views
    685

    Yes, it is the same compiler and if you give it...

    Yes, it is the same compiler and if you give it the correct options it will generate the same code. Here https://godbolt.org/z/WT5jz7T1W with options for a T3.2 optimization level O2

    And this is...
  16. Replies
    17
    Views
    685

    I don't know how to calculate this magic number...

    I don't know how to calculate this magic number but the compiler does. It compiles both of your functions to more or less the same code including your magic number. These days it is difficult to...
  17. Replies
    42
    Views
    1,785

    I don't know much about Python, so an honest...

    I don't know much about Python, so an honest question: are you sure that this is not a python thing? E.g. in #1 I see this:



    data += packet


    I don't know how python handles such things...
  18. This will then also pull the resistors on the B...

    This will then also pull the resistors on the B side low not high right?
  19. Maybe I'm missing something but on your schematic...

    Maybe I'm missing something but on your schematic DIR doesn't seem to be connected. The /OE on pin 19 is only connected to the resistors and some other ICs. You write that the resistors are pull ups...
  20. Replies
    9
    Views
    583

    Thanks for the info. I think I'll add an option...

    Thanks for the info. I think I'll add an option for an easy switch between new-lib and nano-lib in VisualTeensy and see if I observe some disadvantages in the next months.
    Besides the impressive...
  21. Replies
    42
    Views
    1,785

    Here a measurement of the transferrate vs...

    Here a measurement of the transferrate vs Blocksize from 1000 Bytes up to 1E6 Bytes per transfer block for a total transfer size of some 10MB (10x10^6 Bytes). No transmit error detected.

    26125
  22. Replies
    42
    Views
    1,785

    I think I've got success working around (at...

    I think I've got success working around (at least) parts of the issue in Win10. It turned out that the data dropping only occurs if the teensy is sending freely into the Win10 host. As documented in...
  23. Replies
    42
    Views
    1,785

    I saw your reports about the printed stuff. It...

    I saw your reports about the printed stuff. It looks like some buffer overrun or something similar on the PC side. So this is certainly a bug. I'm just wondering if this (call it buffer overrun) is...
  24. Replies
    42
    Views
    1,785

    Hm, both Python and all the other shown tests use...

    Hm, both Python and all the other shown tests use the underlying Windows CDC driver (usbser.sys). So, it might definitely be something related to this driver. I ordered a STM32F746 evaluation board...
  25. Replies
    42
    Views
    1,785

    Interestingly, I did very similar tests in summer...

    Interestingly, I did very similar tests in summer (sending from Teensy to Win10 PC) and ended up with exactly the same result as described by ardvark. I was using the standard C# serial classes. I...
  26. Replies
    9
    Views
    583

    Using nano-lib instead of new-lib

    From time to time weird issues and workarounds pop up when using the STL with Teensies. Latest examples:


    68342-std-deque-Won-t-Compile-for-Teensy-3-x
    68366-std-string-causes-link-error
    ...
  27. Replies
    14
    Views
    881

    There is a weird linker issue which sometimes...

    There is a weird linker issue which sometimes doesn't link in _write (which is defined in print.cpp). You can work around this by placing a dummy Serial.println("") into startup. There are some posts...
  28. Replies
    27
    Views
    1,975

    E.g. foreach (var board in...

    E.g.


    foreach (var board in watcher.ConnectedTeensies.Where(t => t.Ports.Any())) //loop through all connected boards which expose at least one COM port
    { ...
  29. As Paul already mentioned, the price for...

    As Paul already mentioned, the price for abstracting an interface is that you need to stick to the smallest common denominator. RTTI would kind of help but is way too expensive for Microcontrollers....
  30. Edit: ups crosspost Here an example how to...

    Edit: ups crosspost



    Here an example how to do this:



    #include "Arduino.h"
    #include "FS.h"
  31. Replies
    258
    Views
    42,168

    Ok, I'll update the beta with the fix later...

    Ok, I'll update the beta with the fix later today. Have fun with VisualTeensy
  32. Replies
    258
    Views
    42,168

    Did you add the QNEthernet library to your lib...

    Did you add the QNEthernet library to your lib folder or to the shared library folder?

    Edit:
    You probably did, I can reproduce that when including the lib from the shared libraries repository
    ...
  33. Replies
    86
    Views
    6,023

    See here...

    See here https://forum.pjrc.com/threads/53604-Compiling-Teensy-Sketches-with-VisualCode-(Win10)?p=289285&viewfull=1#post289285
  34. Replies
    258
    Views
    42,168

    Problems compiling QNEthernet were reported here:...

    Problems compiling QNEthernet were reported here: https://forum.pjrc.com/threads/68066-New-lwIP-based-Ethernet-library-for-Teensy-4-1?p=289276&viewfull=1#post289276

    The reason for the issue is...
  35. Replies
    86
    Views
    6,023

    This library contains its own copy of the system...

    This library contains its own copy of the system file errno.h. For some reason the the core includes the library file instead of the correct system one. Probably some lookup order issue in the...
  36. Replies
    804
    Views
    96,523

    You find the info and link to the sources here:...

    You find the info and link to the sources here: https://github.com/luni64/TeensyTimerTool/wiki/Avoid-PWM-timer-clashes
  37. Just as a side note: Does changing line 242 in...

    Just as a side note:
    Does changing line 242 in time.cpp to


    getExternalTime getTimePtr = []{return (time_t) Teensy3Clock.get();}; // pointer to external sync function, default syncs to the...
  38. Replies
    27
    Views
    1,975

    Sorry, thought I mentioned it :-) Its in the...

    Sorry, thought I mentioned it :-)
    Its in the development branch of the Github repo. I.e. go to https://github.com/luni64/TeensySharp switch the branch from master to development and download it.
  39. Replies
    119
    Views
    34,384

    You might want to try this...

    You might want to try this https://github.com/luni64/TeensyStep4 (very experimental at the moment but should work somehow)

    The API changed significantly. Main difference is, that I disposed the...
  40. Replies
    27
    Views
    1,975

    Meanwhile I had a look at the library. Since it...

    Meanwhile I had a look at the library. Since it is not used very often I have to admit that it is not very well maintained. The main problem is, that it can not detect Serial Teensies with the new...
  41. Replies
    27
    Views
    1,975

    1.3Mb is quite large, but lets see... I'll be...

    1.3Mb is quite large, but lets see...
    I'll be traveling tomorrow but I can have a look on Thursday
  42. Replies
    27
    Views
    1,975

    Thanks for the input Kurt, but the 0x6000000...

    Thanks for the input Kurt, but the 0x6000000 issue was the first I stumbled over when I extended the code for the T4 :-) So that should work. Anyway, should be easy to fix as soon as the hex file is...
  43. Replies
    27
    Views
    1,975

    Can you post the hex file which shows the problem?

    Can you post the hex file which shows the problem?
  44. Replies
    16
    Views
    1,174

    Reserve returns false if it can't reserve. So...

    Reserve returns false if it can't reserve. So just check the return value...



    No, reserve uses malloc which can not throw....
  45. He, he, that's cool indeed. Thanks for checking. ...

    He, he, that's cool indeed. Thanks for checking.
    So, still the same conclusion right? If you want to check for out of memory condition use new(std::nothrow).
  46. I wouldn't call it a bug. Actually, I expected...

    I wouldn't call it a bug. Actually, I expected the crash since new is supposed to throw a bad_alloc exception which clashes with the fact that the sketch is compiled with -fno-exceptions (which is...
  47. Allocating memory with 'new', new(std::nothrow), testing -fcheck-new

    Triggered by this https://forum.pjrc.com/threads/68201-Is-using-a-quot-String-quot-still-a-bad-idea?p=288694&viewfull=1#post288694 I was doing a few experiments with detecting out of memory...
  48. Replies
    16
    Views
    1,174

    Yes this can be confusing. Maybe it is possible...

    Yes this can be confusing. Maybe it is possible to change the default behavior somehow? Need to goolgle this on a rainy Sunday afternoon...
  49. Replies
    16
    Views
    1,174

    I'm confused ?!? What do you expect that this...

    I'm confused ?!? What do you expect that this code should do? You are allocating memory in loop without ever releasing it and not checking if the allocation was successful. Since the Teensy doesn't...
  50. Replies
    11
    Views
    2,652

    . No deep deep thought behind that. I'm just used...

    . No deep deep thought behind that. I'm just used to pass structs by address into functions. Passing by reference would work the same of course. (and, probably the real reason: on a german keypboard...
Results 1 to 50 of 500
Page 1 of 10 1 2 3 4