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

Search:

Type: Posts; User: tonton81

Page 1 of 10 1 2 3 4

Search: Search took 0.03 seconds.

  1. Replies
    1,040
    Views
    162,684

    are you using pins 0 & 1 for CAN2? are you using...

    are you using pins 0 & 1 for CAN2?
    are you using level shifters? teensy is 3.3v
    is the Rs pin driven low?
  2. Thread: SPISlave_T4

    by tonton81
    Replies
    63
    Views
    5,231

    only thr t4.x masters needs specific dse bits...

    only thr t4.x masters needs specific dse bits set, other masters work fine
  3. Thread: SPISlave_T4

    by tonton81
    Replies
    63
    Views
    5,231

    the master 4.x need a patch for the DSE bits,...

    the master 4.x need a patch for the DSE bits, check out the commits for SPI_MSTransfer_T4, this only affects the master, just make sure your ground is the one next to the 5v pin (not near pin 0)
  4. Replies
    1,040
    Views
    162,684

    Hardware only sends transmission once but only if...

    Hardware only sends transmission once but only if it is successful. It will retry until a valid ACK occurs and then it can continue to next frame. Be sure a node is on the bus to ACK it and check the...
  5. Thread: SPISlave_T4

    by tonton81
    Replies
    63
    Views
    5,231

    i don't see POPR used in your last code, both of...

    i don't see POPR used in your last code, both of them must be used. if you dont care for POPR (receiving) then flush it at very least:


    (void)mySPI.popr();
  6. Thread: SPISlave_T4

    by tonton81
    Replies
    63
    Views
    5,231

    for the 4.x slave check if you're using the GND...

    for the 4.x slave check if you're using the GND beside the 5v pin, and not the one beside pin 0

    there is no buffer, this is a fixed register in the SPI hardware
    POPR receives byte from bus master...
  7. Replies
    1,040
    Views
    162,684

    Is there any data on the bus? If it's in a TX...

    Is there any data on the bus? If it's in a TX mailbox it should be writing out, what does mailboxstatus print out?
  8. Replies
    1,961
    Views
    268,731

    thats the master, have you tried the master slave...

    thats the master, have you tried the master slave examples as a start to make sure your wiring is okay? the examples do work so they will rule out if it's a software or hardware connection issue
  9. Replies
    1,040
    Views
    162,684

    do a mailboxStatus(), if it still stays there...

    do a mailboxStatus(), if it still stays there after you stop transmitting, verify your baudrate, terminations, transceiver connections. it will stay in the mailbox and software has no control over...
  10. Replies
    1,040
    Views
    162,684

    each hardware mailbox stores only one frame...

    each hardware mailbox stores only one frame during poll mode. if you use interrupts, a queue system automatically collects the mailboxes so they can receive another frame. From that queue, the...
  11. Replies
    24
    Views
    5,970

    still that error makes no sense if you have it...

    still that error makes no sense if you have it set to teensy T4.x. maybe its because it's a french IDE having incompatibilities with teensyduino? nothing in the library is avr related
  12. Replies
    1,040
    Views
    162,684

    is that the only method you need working? if so,...

    is that the only method you need working? if so, you can temporarily add it as a virtual method in FlexCAN_T4_Base class (virtual method(args) = 0) and it will work until i figure out a template...
  13. Replies
    1,040
    Views
    162,684

    You can use the base class as an alternative ...

    You can use the base class as an alternative




    FlexCAN_T4<CAN1, RX_SIZE_256, TX_SIZE_16> Can0;

    class TestClass {
    private:
    FlexCAN_T4_Base* bus = nullptr;
  14. Replies
    1,040
    Views
    162,684

    I wrote a post regarding using template objects,...

    I wrote a post regarding using template objects, it just replicates your function for X busses without doubling it in the sketch.
    ...
  15. Thread: SPISlave_T4

    by tonton81
    Replies
    63
    Views
    5,231

    same device? well i would imagine the interrupt...

    same device? well i would imagine the interrupt being held open with active locked, the loop wouldnt be able to send anything until that's done, i never tested it as a loopback but thats where you...
  16. Replies
    24
    Views
    5,970

    yes, latest always on github for any library

    yes, latest always on github for any library
  17. Replies
    24
    Views
    5,970

    never heard of that error before, make sure you...

    never heard of that error before, make sure you have teensy selected as the board
  18. Thread: SPISlave_T4

    by tonton81
    Replies
    63
    Views
    5,231

    should be the arduino/libraries folder, not the...

    should be the arduino/libraries folder, not the main project location
  19. Replies
    15
    Views
    618

    if thats the 4.1, could you try the GND on the...

    if thats the 4.1, could you try the GND on the other side of the board, not the one next to pin 0
  20. Replies
    15
    Views
    618

    try 2.2k resistors instead of 4.7k for 3.3v i2c

    try 2.2k resistors instead of 4.7k for 3.3v i2c
  21. Replies
    1,040
    Views
    162,684

    I can't see all your code but just remove...

    I can't see all your code but just remove events() from the loop() if you have it so the callback will fire directly rather from the events() queue system, this will disable the RX queue system and...
  22. Replies
    1,040
    Views
    162,684

    most libraries depended on the original...

    most libraries depended on the original flexcan.h, however the one you are using is custom and accesses the hardware directly without depending on flexcan.h. Once you remap the addresses and figure...
  23. we had -20 winters here and t4.0 ran fine, it was...

    we had -20 winters here and t4.0 ran fine, it was running 24/7
  24. Replies
    1,040
    Views
    162,684

    the registers should be fine to port the older...

    the registers should be fine to port the older library to t4, however if you look at flexcan_t4's begin() you'll see the initialization routines needed, and you'll need to remap the address of can0...
  25. Replies
    208
    Views
    46,551

    both are the same, they call same function, so...

    both are the same, they call same function, so it's user preference really. You can continue writing to the buffer it will overwrite older values when full, no need to empty it and wait for it to...
  26. every person has a preference so this is what I...

    every person has a preference so this is what I mostly use:



    static uint32_t t = millis();
    if ( millis() - t > 1000 ) {
    // DoSomething();
    t = millis();
    }
  27. Replies
    1
    Views
    96

    i2c does need pullups even for 3.3v, use 2.2k

    i2c does need pullups even for 3.3v, use 2.2k
  28. Just out of curiosity for SPI0 try to run this...

    Just out of curiosity for SPI0 try to run this after SPI.begin() using default SPI pins on the T4.1 master:



    #if defined(__IMXRT1062__)
    IOMUXC_SW_PAD_CTL_PAD_GPIO_B0_01 = IOMUXC_PAD_DSE(3)...
  29. Replies
    35
    Views
    4,545

    According to the author of the port: I am...

    According to the author of the port:



    I am wondering if the modified core as well as updated toolchain have a side affect to this...

    By the way USBHost.h was not found, which library you...
  30. Replies
    35
    Views
    4,545

    that's an assert error from free-rtos end on the...

    that's an assert error from free-rtos end on the memory map itself, that could be a problem with the freertos port

    have you tried fresh rtos with blinking light?
    and
    have you tried all your code...
  31. Replies
    35
    Views
    4,545

    perhaps a demo example of usbhost on t3.6 with...

    perhaps a demo example of usbhost on t3.6 with rtos and how it crashes, it could just be a code issue, maybe UB or sepamore issue. RTOS is very finicky sometimes, I have an ESP32 using quad ble...
  32. Replies
    1,040
    Views
    162,684

    there are also multiple timing parameters for FD...

    there are also multiple timing parameters for FD in the Advanced setbaudrate config menu, it displays all the timings for the same bitrate so you can pick one from the list, by default it uses the...
  33. Replies
    1,040
    Views
    162,684

    have you tried other baudrates? tried changing...

    have you tried other baudrates? tried changing the clock to 60?

    collink had same if not similar issue with 500000/2000000 specifically, while 1000000/2000000 was fine
  34. Replies
    1,040
    Views
    162,684

    unfortunately you're limited by the bus speed,...

    unfortunately you're limited by the bus speed, abort cancels a transmission and may or may not guarentee the frame be sent out or not still, plus that would lead to more latency and missing frame to...
  35. Replies
    1,040
    Views
    162,684

    Uploaded patch for return value 0 if queue was...

    Uploaded patch for return value 0 if queue was full.
    Tested it as well:


    for ( int i = 0; i < 30; i++) {
    CAN_message_t msg;
    msg.id = 0x555;
    msg.seq = 1;
    ...
  36. Replies
    1,040
    Views
    162,684

    the sender only has a transmit queue of 16,...

    the sender only has a transmit queue of 16, you'll need to increase that if you plan to burst

    i went to check the write function unfortunately it doesn't check for overflows, as they'll return -1...
  37. https://github.com/tonton81/SPI_MSTransfer_T4 ...

    https://github.com/tonton81/SPI_MSTransfer_T4

    It works on all Teensy LC, 3.x, and 4.x
  38. I made a daisy-chainable SPI slave library, you...

    I made a daisy-chainable SPI slave library, you can use it either separate or same CS, and you can send whatever arrays you want from master to slave or slave to master

    you could do it yourself...
  39. Replies
    7
    Views
    206

    yeah, its just for curiosity, we had an issue...

    yeah, its just for curiosity, we had an issue with SPI talking to an SPI slave T4 and this ressolved it, if it can fix other stuff since you have a scope it can be a good reference to look back on
  40. Replies
    7
    Views
    206

    out of curiosity, can you try this? put it AFTER...

    out of curiosity, can you try this?
    put it AFTER SPI.begin()


    #if defined(__IMXRT1062__)
    IOMUXC_SW_PAD_CTL_PAD_GPIO_B0_01 = IOMUXC_PAD_DSE(3) | IOMUXC_PAD_SPEED(3) | IOMUXC_PAD_PKE; /*...
  41. Replies
    35
    Views
    4,545

    a scoped mutex would be sufficient there

    a scoped mutex would be sufficient there
  42. Replies
    35
    Views
    4,545

    did you try threads.delay() ? i think we not...

    did you try threads.delay() ? i think we not suppose to use delay() in threads
  43. Replies
    35
    Views
    4,545

    Use TeensyThreads, even though RTOS on ESP32 uses...

    Use TeensyThreads, even though RTOS on ESP32 uses 2 cores mostly it uses tasks on core 1 for arduino, TeensyThreads is very good at switching tasks(threads), although there are no sepamores you still...
  44. Replies
    1,040
    Views
    162,684

    solder joints look weak, did you adjust your...

    solder joints look weak, did you adjust your code?
    the fifo example with interrupts is a good start as that is guarenteed to work, provided you choose the right bus in the constructor and baudrate...
  45. Replies
    8
    Views
    607

    As paul said you need a proper circuit with logic...

    As paul said you need a proper circuit with logic mosfets and series resistor to protect the pins. You shouldn't be driving loads only applying a signal where the mosfet or relay takes care of the...
  46. Replies
    8
    Views
    607

    i am using an esp32 with mosfets being commanded...

    i am using an esp32 with mosfets being commanded by teensy over CAN. So teensy can control the 10 gpios currently connected to the esp32. i also posted a sketch for it on github. mosfet boards you...
  47. Replies
    1,040
    Views
    162,684

    must be setMB configured before doing any...

    must be setMB configured before doing any filterwork, by default with fifo disabled the 4 first ones are STD while next 4 are EXT then 8 TX.
  48. Replies
    1,040
    Views
    162,684

    yes with the transceivers it will work as it's...

    yes with the transceivers it will work as it's intended.

    9600 isn't a standard CAN bitrate though. Try 125000 on low end, recommended 500000
  49. Replies
    4
    Views
    179

    How can your PC serial monitor see traffic if:...

    How can your PC serial monitor see traffic if:
    A) you have no callback
    B) you're not polling
    C) you are not using interrupts.

    Sending may be working but you will never receive anything. Take a...
  50. Replies
    1,040
    Views
    162,684

    it doesn't work that way, it works based on the...

    it doesn't work that way, it works based on the payload which can come in from anywhere. if you do go that route you'll most likely use filtering, but its a background queue that reassembles the...
Results 1 to 50 of 500
Page 1 of 10 1 2 3 4