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

  1. Replies
    790
    Views
    75,991

    the lowest mailbox (granted they are free to...

    the lowest mailbox (granted they are free to receive) receives first, the last mailbox (if all full) always gets overridden if overflow occurs. If a message is destinated for one mailbox only, and no...
  2. Replies
    790
    Views
    75,991

    not sure I havn't faced this issue before or...

    not sure I havn't faced this issue before or looked at it yet, ok, you dont need a base class if you use the template object directly to print the table, just make it public and use...
  3. Replies
    790
    Views
    75,991

    hmm that is indeed weird, yes if you want to try...

    hmm that is indeed weird, yes if you want to try modifying the table move it from private to public, maybe after you set all the IDs and filters you can print out the table list so you can cross...
  4. Replies
    790
    Views
    75,991

    so unneeded id's are bleeding through? and did...

    so unneeded id's are bleeding through? and did you make sure all other mailboxes are setup, or refusing messages with exception ids, if a couple of message boxes have the same id & filter, other...
  5. Replies
    790
    Views
    75,991

    enhancedfilter was not meant for custom user...

    enhancedfilter was not meant for custom user filters, only the automatic filtering as it's ID based masking based off ANDing the calculated mask, a custom mask on the other hand, ANDing the mask with...
  6. Replies
    20
    Views
    19,236

    no you need a transceiver, you can use 3.3v...

    no you need a transceiver, you can use 3.3v transceivers, or "some" 5v transceivers *that communicate* at 3.3v logic levels
  7. Replies
    28
    Views
    308

    See here for yield() which runs after every loop,...

    See here for yield() which runs after every loop, can be overridden if you supply a blank function so it doesn't do unnecessary background processing, or put a while loop within the loop and make...
  8. Replies
    790
    Views
    75,991

    FIFO is RX only, the mailboxes can be used for...

    FIFO is RX only, the mailboxes can be used for either transmit or receive. FIFO has ordered frames while mailboxes can receive in any order. If you are looking for consistancy, use FIFO. The FIFO...
  9. you can also cut the red wire on the USB cable...

    you can also cut the red wire on the USB cable instead of cutting the trace. this way you can use the USB as a data only cable without power. It is not a good idea to source power from 2 places as...
  10. Replies
    7
    Views
    159

    you'll have to hook it up to find out, primarily...

    you'll have to hook it up to find out, primarily you need to know:

    1) if it truely is a CAN bus on the AC
    2) you need to know the baudrate in order to talk to it
    3) you'll have to start...
  11. Replies
    790
    Views
    75,991

    most people will pick FIFO for simplicity and...

    most people will pick FIFO for simplicity and ordered receptions, the FIFO example with interrupts is a good base to start with. MB is fine if you don't cared about ordered frames on the bus, mostly...
  12. Thread: help buy

    by tonton81
    Replies
    7
    Views
    673

    vietnamese/chinese couch imports to Canada gets a...

    vietnamese/chinese couch imports to Canada gets a 295% (yes, you read that right) tarriff. I believe the broker fee at DHL (at least in Canada) is about 15$ CDN, the tariff is duties paid to customs...
  13. Replies
    22
    Views
    527

    can you print out the Serial.println(esr) value...

    can you print out the Serial.println(esr) value in the ISR right before it's cleared and post me the value you see?

    make sure LISTEN_ONLY is set in setBaudRate,

    1) value when node A is passive...
  14. Replies
    22
    Views
    527

    yes but with the code in the ISR it should remove...

    yes but with the code in the ISR it should remove LOM if the bus is active no?
  15. Replies
    22
    Views
    527

    Okay well the infinite retries when Node A is...

    Okay well the infinite retries when Node A is passive when teensy boots is probably because the interrupt never fires unless network activity actually fires the ISR (which the code handling we added...
  16. Replies
    22
    Views
    527

    Can you try this one? ...

    Can you try this one?



    //FLEXCANb_ESR1(_bus) |= FLEXCANb_ESR1(_bus);
    uint32_t esr = FLEXCANb_ESR1(_bus);

    if ( esr & FLEXCAN_ESR_ACK_ERR ) {
    FLEXCAN_EnterFreezeMode();
    ...
  17. Replies
    22
    Views
    527

    but it clears the TX mailboxes, are you sure it's...

    but it clears the TX mailboxes, are you sure it's not constantly sending in the loop ? or are they timed? when the loop sends a message then ACK_ERR happens and then the TX is stopped, but if the...
  18. Replies
    36
    Views
    3,179

    yes all the CS to one pin, make sure you have all...

    yes all the CS to one pin, make sure you have all 8 chips with different addresses
  19. Replies
    790
    Views
    75,991

    try 0xFF for filter?

    try 0xFF for filter?
  20. Replies
    22
    Views
    527

    Can you do me a favor and check this, search the...

    Can you do me a favor and check this, search the tpp for:

    FLEXCANb_ESR1(_bus) |= FLEXCANb_ESR1(_bus);
    it's at the end of the ISR

    I need you to comment it out and add this:


    ...
  21. Replies
    22
    Views
    527

    Seems this is known behaviour of flexcan: ...

    Seems this is known behaviour of flexcan:





    Endless sending is a feature haha.......... anyways let's work on it :)
  22. Replies
    22
    Views
    527

    there are also cases where there may be several...

    there are also cases where there may be several teensy nodes on a network that require isotp communication as well before they respond (i talk to an esp32 using isotp over a 3 node bus), introducing...
  23. Replies
    22
    Views
    527

    the software end doesn't do the retransmits, it's...

    the software end doesn't do the retransmits, it's the hardware on it's own, so we need to tackle that issue like you said by throttling or not sending on idle bus, but at the same time, not affect...
  24. Replies
    22
    Views
    527

    correct me if im wrong, but if teensy is...

    correct me if im wrong, but if teensy is transmitting even passive nodes on the bus will respond the ack even though theyre not streaming? I ask because BCAN bus on my civic when all modules switch...
  25. ok sorry you have to encapsulate the scope as...

    ok sorry you have to encapsulate the scope as well:



    { Threads::Scope scope(LockAnimation);


    so move the bracket to the start of that line
  26. hmm it should not.. im not home to check what i...

    hmm it should not.. im not home to check what i used to have
  27. Replies
    22
    Views
    527

    we can make a solution just need ideas. If we...

    we can make a solution just need ideas. If we detect a bus-off it doesn't necessarily mean the network is dead, we would need to check if the traffic stops and if so clear the queue while clearing...
  28. Replies
    22
    Views
    527

    I didn't send a snarky remark? You are welcome to...

    I didn't send a snarky remark? You are welcome to do a pull request if you have a solution the library is always evolving, and maintained as much as possible
  29. Replies
    790
    Views
    75,991

    the hardware itself does the resending on CRC...

    the hardware itself does the resending on CRC fails (like cross-CAN2.0/FD you said you use). Software has no control over resending, this is by hardware design, if it doesn't get an ACK either, it'll...
  30. Replies
    790
    Views
    75,991

    well yes if they are mis-communicating because of...

    well yes if they are mis-communicating because of different standards a CRC fail will issue a resend, that is hardware controlled though. You could abort the message but in your loop if you send...
  31. Replies
    22
    Views
    527

    it doesn't transmit unless it gets an ACK, so...

    it doesn't transmit unless it gets an ACK, so obviously something is ACKing it, you are responsible for not sending if bus is inactive. If you turn off a UART device do you think your runaway code...
  32. Replies
    790
    Views
    75,991

    the SA? last bytes? 00 would let anything in last...

    the SA? last bytes? 00 would let anything in last 8 bits pass, yes, while the upper bits if kept would be checked
  33. protect the resource, not unnecessary code, for...

    protect the resource, not unnecessary code, for performance reasons:




    void Animation() {

    while (1) {

    do {
  34. Threads::Scope scope(LockAnimation); that...

    Threads::Scope scope(LockAnimation);

    that suppose to be a scope, not a command. use { } brackets around the code.

    effectively, the way you did it, the scope exits immediately making the mutex...
  35. Replies
    790
    Views
    75,991

    Bruce, the masking is quite complex in FlexCAN,...

    Bruce, the masking is quite complex in FlexCAN, and it is way worse in FIFO mode as the bits are offset. Working on automated masking capability and testing it was quite a bit of work.

    What you...
  36. Replies
    790
    Views
    75,991

    what happens if you put events() in the loop?...

    what happens if you put events() in the loop? does the frames show up in callback? something wrong in your code if it wont receive frames
  37. Replies
    790
    Views
    75,991

    print the one from the setmbfilter function ...

    print the one from the setmbfilter function

    Serial.println(mask)
    Better yet, you can print it from setMBFilterProcessing section before the function exits
    Serial.println(mask)
    this way all the...
  38. Replies
    790
    Views
    75,991

    the mask is for setmbfilter is calculated...

    the mask is for setmbfilter is calculated properly
    your mask must be wrong, try to debug the setmbfilter to print out what the mask should actually look like so you know what to put for usermask,...
  39. Replies
    790
    Views
    75,991

    if only MB0 is receiving it means everything is...

    if only MB0 is receiving it means everything is being captured in MB0 and read fast enough by interrupt that no other frames reach the remaining mailboxes. try setting the filter the same as the ID...
  40. Replies
    790
    Views
    75,991

    enhancefilter is for setmbfilter

    enhancefilter is for setmbfilter
  41. Replies
    790
    Views
    75,991

    the User filter you may be doing it wrong. the...

    the User filter you may be doing it wrong. the last example used on repo used 0xFF to match the last 8 bits of listed CAN frames.

    what happens if you set it to 0? 0 is pass through and each bits...
  42. Replies
    790
    Views
    75,991

    did you check first on a simple sketch to see if...

    did you check first on a simple sketch to see if you can receive that frame with and without a filter?
  43. Replies
    790
    Views
    75,991

    why are you using setMBUserFilter? use the...

    why are you using setMBUserFilter? use the intended setMBFilter .

    Also setMaxMB should be set before setMBFilters
    Better yet you should be testing this with the simple demo before implementing it...
  44. if it locks up it means: 1) you are accessing...

    if it locks up it means:

    1) you are accessing the same resource in multiple threads/isr without a mutex (mutex is not for isr use!)
    2) you are using a mutex in an isr
    3) mutex deadlock (setting...
  45. Replies
    790
    Views
    75,991

    use the new isotp integration in FlexCAN_T4. It...

    use the new isotp integration in FlexCAN_T4. It can send/receive payloads between multiple teensies. Examples are on the repo, and it's currently running in my car project receiving isotp payloads...
  46. Replies
    790
    Views
    75,991

    setup CAN last then?

    setup CAN last then?
  47. Replies
    790
    Views
    75,991

    Ralsi, you can play with sample point and clock...

    Ralsi, you can play with sample point and clock (try 60MHz?)

    are you using interrupts? are you reading events() periodically to prevent missing frames? Tried increasing the constructor's RX buffer?
  48. Replies
    790
    Views
    75,991

    why would you initialize, disable, initialize,...

    why would you initialize, disable, initialize, disable, initialize, disable, then all enable? I don't see a use case for that nor will anyone except you use that?
  49. Replies
    86
    Views
    7,426

    that is why it's called undefined behavior :)

    that is why it's called undefined behavior :)
  50. Replies
    790
    Views
    75,991

    ONLY CAN3 CAN2.0 supports DMA (not FD), it...

    ONLY CAN3 CAN2.0 supports DMA (not FD), it doesn't use interrupts. You are still responsible for using read() periodically to prevent missing frames. Not very ideal if you ask me :)

    freeze mode...
Results 1 to 50 of 500
Page 1 of 10 1 2 3 4