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.02 seconds.

  1. I finally managed to upload the new version to...

    I finally managed to upload the new version to nuget https://www.nuget.org/packages/lunOptics.libTeensySharp/
  2. Replies
    33
    Views
    2,146

    Here you are...

    Here you are https://www.nuget.org/packages/lunOptics.libTeensySharp/ Since the API is rather different from the old version I decided to rename the library to lunOptics.libTeensySharp. So, you need...
  3. Replies
    33
    Views
    2,146

    Yes, I definitely need to update that nuget...

    Yes, I definitely need to update that nuget package....
  4. Replies
    33
    Views
    2,146

    The code you showed does look normal, but of...

    The code you showed does look normal, but of course it is only a tiny snippet. To double check I just tried the WinForms example and it runs without an issue. Can you upload your project somewhere...
  5. Replies
    16
    Views
    580

    Can you zoom into the falling edge? Since the...

    Can you zoom into the falling edge? Since the signal is going down very slow, I'd be surprised if you don't see multiple transitions if you look closely. This would generate the same counting issues...
  6. The T3.6 runs at 150MHz not kHz and TeensyStep is...

    The T3.6 runs at 150MHz not kHz and TeensyStep is good for about 300kHz step rate. So, I doubt that the limitation comes from the Teensy side. If you have a scope you could try to measure the pulse...
  7. Replies
    16
    Views
    580

    This is absolutely not the way how to do it. I'm...

    This is absolutely not the way how to do it. I'm surprised that this even works. You should use a real level shifter, something like a 74LVC125 or similar. (I need to leave now, so no time to explain...
  8. He, he, the good old 'forgot to plug the power...

    He, he, the good old 'forgot to plug the power cord in' :-))



    Hm, what does 85.000 mean? 85 RPM? 85,000 steps per second? Fullsteps? Microsteps? How many steps per rev? ...

    I didn't read the...
  9. And what happens if you use the first example...

    And what happens if you use the first example sketch you posted? If you set the target positions to 60000 it should move for about 1 second in each direction. You should be able to see that on the...
  10. Which explains why the direction doesn't change....

    Which explains why the direction doesn't change. Can you do a simple sketch just toggling pin15 every second and check with your meter if that appears on SW2? (don't forget to set the pinmode to...
  11. Here you are:...

    Here you are: https://github.com/TeensyUser/doc/wiki/How-To---stdio-%28printf---scanf---stdout%29 Feel free to edit / add / delete as you like
  12. I had a closer look at the drawing of that...

    I had a closer look at the drawing of that breakout board. Of course this is only wild guesswork, but from the parts on the board it looks like the DIR and PUL outputs are switched by some transistor...
  13. It is quite difficult to help you remotely on...

    It is quite difficult to help you remotely on this. Might be a very good idea to find a local guy with some electronics background to help you wiring it.

    Anyway, lets give it a try: Looks like...
  14. The code in your first example should definitely...

    The code in your first example should definitely work. I assume some electrical issue. E.g. The datasheet of the motors you linked requires 5-24V signals. The 3.3V output might be too small to...
  15. Nice, do you mind if I copy that to the user wiki...

    Nice, do you mind if I copy that to the user wiki? You can also edit and add to it there (no login required)
  16. Replies
    16
    Views
    580

    @shawn: see e.g. here:...

    @shawn: see e.g. here: https://forum.pjrc.com/threads/66741-attachInterrupt-with-CHANGE-mode-in-Teensy-4-0-problem?p=274793&viewfull=1#post274793. Also, the sensor seems to have an open collector...
  17. Replies
    16
    Views
    580

    I'd first check the hardware with a simple sketch...

    I'd first check the hardware with a simple sketch like shown below. Whenever it registers a falling edge at the sensor input it simply toggles the cameraTrigger.


    #include "Arduino.h"
    ...
  18. Replies
    65
    Views
    14,210

    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: ...
  19. Thread: TeensyTimerTool

    by luni
    Replies
    299
    Views
    41,262

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

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

    by luni
    Replies
    299
    Views
    41,262

    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....
  21. Replies
    9
    Views
    634

    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...
  22. Thread: TeensyTimerTool

    by luni
    Replies
    299
    Views
    41,262

    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....
  23. Replies
    9
    Views
    440

    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...
  24. Replies
    9
    Views
    440

    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...
  25. Replies
    9
    Views
    440

    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: ...
  26. 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()
    {...
  27. 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 =...
  28. 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?
  29. Replies
    17
    Views
    768

    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
  30. Replies
    9
    Views
    626

    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
  31. Replies
    17
    Views
    768

    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...
  32. Replies
    17
    Views
    768

    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...
  33. Replies
    17
    Views
    768

    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...
  34. Replies
    42
    Views
    1,926

    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...
  35. 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?
  36. 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...
  37. Replies
    9
    Views
    626

    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...
  38. Replies
    42
    Views
    1,926

    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
  39. Replies
    42
    Views
    1,926

    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...
  40. Replies
    42
    Views
    1,926

    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...
  41. Replies
    42
    Views
    1,926

    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...
  42. Replies
    42
    Views
    1,926

    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...
  43. Replies
    9
    Views
    626

    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
    ...
  44. Replies
    14
    Views
    924

    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...
  45. Replies
    33
    Views
    2,146

    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
    { ...
  46. 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....
  47. Edit: ups crosspost Here an example how to...

    Edit: ups crosspost



    Here an example how to do this:



    #include "Arduino.h"
    #include "FS.h"
  48. Replies
    258
    Views
    43,557

    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
  49. Replies
    258
    Views
    43,557

    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
    ...
  50. Replies
    86
    Views
    6,254

    See here...

    See here https://forum.pjrc.com/threads/53604-Compiling-Teensy-Sketches-with-VisualCode-(Win10)?p=289285&viewfull=1#post289285
Results 1 to 50 of 500
Page 1 of 10 1 2 3 4