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
    921
    Views
    143,402

    check out how isotp.h is done, it is a...

    check out how isotp.h is done, it is a separate/independant plugin for FlexCAN_T4 to demonstrate how 3rd party libraries can use FlexCAN_T4.

    Isotp code is also templated, however you can still...
  2. Replies
    921
    Views
    143,402

    take a look at the *MBFilterProcessing internal...

    take a look at the *MBFilterProcessing internal function, if you want to test your own masks being passed directly rather than the autocalculated call you can try that (for testing you can move that...
  3. Replies
    921
    Views
    143,402

    Those functions were added for J1939 protocol...

    Those functions were added for J1939 protocol where first value is a group of ids and the 2nd value is the last bits to mask off, a user requested that, it's different than the filtering you want.
    ...
  4. CAN3 supports CAN2.0 legacy OR CANFD, so yes you...

    CAN3 supports CAN2.0 legacy OR CANFD, so yes you can use CAN2.0 on all 3 with identical code

    the CAN pins are PINK on the card, don't confuse them for the serial ports, you can't install the...
  5. Replies
    921
    Views
    143,402

    you need to setMaxMB for up to 64 mailboxes, it's...

    you need to setMaxMB for up to 64 mailboxes, it's possible the mailboxstatus may have a bug in reporting it if it doesnt return same value as setRFFN, but setRFFN cannot exceed the amount of...
  6. Replies
    921
    Views
    143,402

    change the RFFN value, there is a function for...

    change the RFFN value, there is a function for that, then enableFIFO, keep in mind 8 additional filters consume 2 mailboxes, so if you set max mailboxes to 16 and enable FIFO with 16 filters, you'll...
  7. Replies
    921
    Views
    143,402

    the 8 filters are there, doesn't mean theyre used...

    the 8 filters are there, doesn't mean theyre used or not. by default they accept all traffic, it's just to show that FIFO can set up to 8
  8. Replies
    921
    Views
    143,402

    for different bitrates in FD mode, there is an...

    for different bitrates in FD mode, there is an advanced setbaudrate function which allows different timings for the same bitrates, try using that to try a different timing than the default. you can...
  9. Replies
    921
    Views
    143,402

    not all 128 are implemented, anything above the...

    not all 128 are implemented, anything above the 32 limit in fifo uses global filter for remaining X and only certain bits are checked, all those filters rely on a single mask, so i didn't bother...
  10. Replies
    921
    Views
    143,402

    honestly, single shot mode in "flexcan" hardware,...

    honestly, single shot mode in "flexcan" hardware, this is it's behaviour. i spent alot of time on that debugging and really the only way to stop it is by manually aborting, which, you'd have to...
  11. Replies
    921
    Views
    143,402

    yeah if skpang works its a physical...

    yeah if skpang works its a physical connection/transceiver issue
    on the triple can board schematic it shows CTX to TX amd CRX to RX so thats fine, and CANH to CANH and CANL to CANL, if those are...
  12. Replies
    921
    Views
    143,402

    if the TX mailboxes are all full, it is in bus...

    if the TX mailboxes are all full, it is in bus off state, there is either a wiring issue to the transceiver or the device it's attached to, or the baudrate is mismatched, or a termination issue,...
  13. Replies
    2
    Views
    270

    the MISO/MOSI/SCK can be ran in parallel provided...

    the MISO/MOSI/SCK can be ran in parallel provided the devices tri-state their MISO pin on deassertion of the CS pin. However, the other pins should be different: CS, RST, DRDY, RST etc
  14. Replies
    921
    Views
    143,402

    workability? well if it compiles it should work...

    workability? well if it compiles it should work because without the linkage of both files it will be impossible to compile
  15. Thread: SPISlave_T4

    by tonton81
    Replies
    29
    Views
    3,221

    not without testing of course, it's not on my...

    not without testing of course, it's not on my bench right now

    the pointer is still volatile but with offsets, but i am saying you are using the hardcoded SPI address which is what the code takes...
  16. Replies
    921
    Views
    143,402

    it runs fine in the Arduino IDE, template (.tpp)...

    it runs fine in the Arduino IDE, template (.tpp) files are supported by it, no need to rename. Even if you do rename you still need to edit the new name in the .h file to reflect that.
  17. Thread: SPISlave_T4

    by tonton81
    Replies
    29
    Views
    3,221

    for future support of other SPIx interfaces, that...

    for future support of other SPIx interfaces, that won't be possible as you specified static addressing, the code was designed to take variable bus addresses into consideration since the offsets are...
  18. Replies
    921
    Views
    143,402

    yes, should be: for (i = 0; i

    yes,


    should be:



    for (i = 0; i < msg.len -1; i++){
    msg.buf[i] = msg.buf[i+1];
    }
  19. Replies
    11
    Views
    2,742

    Here is a demo of FD:...

    Here is a demo of FD:
    https://forum.pjrc.com/threads/67261-Teensy-4-1-and-CanBus?p=280101&viewfull=1#post280101
  20. Replies
    921
    Views
    143,402

    also make sure the CANRX and CANTX is not...

    also make sure the CANRX and CANTX is not reversed?
  21. Replies
    921
    Views
    143,402

    I don't have a micromod but @skpang says it works...

    I don't have a micromod but @skpang says it works
    https://forum.pjrc.com/threads/66771-MicroMod-Beta-Testing?p=282968&viewfull=1#post282968

    That was during beta, but if i check the official board...
  22. It can read/write to hundreds of devices...

    It can read/write to hundreds of devices simultaneously even if one goes down, what happens when you pull the power on a serial version when others talk to it? if it's wired in series the remaining...
  23. be careful with some china bricks, they can say...

    be careful with some china bricks, they can say 5v but actually be 6 or 7... the max actual voltage must be 6v
  24. it could either be a bad termination or bad...

    it could either be a bad termination or bad transceiver at this point
  25. is CTX to CTX and CRX to CRX correct? I can't...

    is CTX to CTX and CRX to CRX correct? I can't tell from the image, unlike UART, they shouldn't be crossed, only direct
  26. FlexCAN_T4 LCAN;...

    FlexCAN_T4<CAN3, RX_SIZE_256, TX_SIZE_128> LCAN;


    That is the peripheral BUS specifier in the constructor (CAN1,CAN2,CAN3). It has no relation to Can0/Can1/LCAN. Those are just your custom name...
  27. pins 0 and 1 is CAN2 pins 22 and 23 is CAN1...

    pins 0 and 1 is CAN2
    pins 22 and 23 is CAN1
    pins 30 and 31 is CAN3

    You should be using CAN1 on constructor

    also i don't think your transceivers are wired to 3.3v, they're left unconnected in...
  28. safer to protect the teensy tx pin should you...

    safer to protect the teensy tx pin should you misprogram the mega and shoot 5v down the line. You could always go with a Teensy 3.5 as it is 5v tolerant and will talk fine to mega directly wired with...
  29. Replies
    921
    Views
    143,402

    Teensy 3.x has 16 mailboxes, with FIFO that...

    Teensy 3.x has 16 mailboxes, with FIFO that leaves 8 free.
    Teensy 4.x has *up to* 64 mailboxes, with FIFO that leaves *up to* 56 mailboxes remaining

    by default 16 is loaded, if you need more (or...
  30. Replies
    921
    Views
    143,402

    they can be setup in any order and distribution...

    they can be setup in any order and distribution must be ran last
    I don't know your layout but FIFO occupies by default the first 8 mailboxes, which leaves you with MB8-15, and consider that the...
  31. Replies
    921
    Views
    143,402

    distribute should be run after filters are setup,...

    distribute should be run after filters are setup, events() isn't needed if you want fifo/mbs to receive. did you enableFIFOInterrupt? it's different than enableMBinterrupt, if not fifo is in polling...
  32. Replies
    921
    Views
    143,402

    if both fire, did you run distribution() ? a...

    if both fire, did you run distribution() ? a match is copied if so to other mailboxes with matching filter, because normally only ONE mb/fifo fire, and if you have individual callbacks that use that...
  33. Replies
    2
    Views
    480

    is that board a retail product? should be some...

    is that board a retail product? should be some reference material or demo for it
  34. yes, all devices (teensies, pics, or sensors)...

    yes, all devices (teensies, pics, or sensors) need a transceiver if they don't already have one. but yeah all run in parallel transceiver to transceiver

    if a sensor isn't CAN capable, you could...
  35. The FIFO with interrupt example has send and...

    The FIFO with interrupt example has send and receive capability. The code is very minimal and it can send and receive 8 bytes payload from all teensies attached
  36. Replies
    921
    Views
    143,402

    msg.flags.extended = 1;

    msg.flags.extended = 1;
  37. yes it is done in hardware, priority is lower...

    yes it is done in hardware, priority is lower CANIDs but in any case you wouldn't notice them taking turns it happens too fast for a human to perceive it. In a car for example, my bus has about 60...
  38. yes to everything except CRX/CTX... For CAN it's...

    yes to everything except CRX/CTX... For CAN it's TX to TX and RX to RX, same for all, all in parallel
    Also CANH to CANH, CANL to CANL, all parallel

    Best part is if you use CANFD to transfer large...
  39. 3 wires (CANH,CANL,GND) from each teensy...

    3 wires (CANH,CANL,GND) from each teensy transceiver

    Vehicles use this network because of it's reliability and guarenteed data transmission accross the network, especially in noisy environments....
  40. at least with CAN you have a star network, where...

    at least with CAN you have a star network, where they all talk to each other at same time, even if one or more go offline, and you can definately go way beyond 3 meters easily
  41. Replies
    1
    Views
    242

    1) Yes 2) You cannot use a different bus' IO...

    1) Yes
    2) You cannot use a different bus' IO path for another bus path
    3) can1.setClock(CLK_60MHz)
  42. Replies
    921
    Views
    143,402

    check if your library is not outdated in your...

    check if your library is not outdated in your documents folder, you can slow down the frames I guess using millis() but if your device can't handle the constant flow of FD to CAN you will just loose...
  43. Replies
    42
    Views
    2,272

    did you try changing the clock speed as that has...

    did you try changing the clock speed as that has timings different for each baudrate
  44. Replies
    171
    Views
    103,112

    if it doesn't get an ack it may go into bus off...

    if it doesn't get an ack it may go into bus off state and using an oscilloscope won't help you as it needs valid 128 bits frame to reset the error counters in order for it to return from bus off and...
  45. Replies
    42
    Views
    2,272

    what bitrate are you using?

    what bitrate are you using?
  46. Replies
    6
    Views
    634

    a definition of a struct crashes ? That can't be...

    a definition of a struct crashes ? That can't be right
  47. Replies
    42
    Views
    2,272

    what does the "interface board" look like? There...

    what does the "interface board" look like? There must be 2 active nodes on the bus for it to work properly. Is everything wired properly?
  48. Replies
    13
    Views
    2,765

    you need to edit the source, only MODE 0 is...

    you need to edit the source, only MODE 0 is supported (hardcoded) at this time. You need to edit the CHPA and CPOL bits in the registers
  49. Replies
    921
    Views
    143,402

    yes it does matter as it saves the message making...

    yes it does matter as it saves the message making the mailbox available to receive again a new frame.

    In interrupt mode (without events() being used), the message is fired directly to callback...
  50. Replies
    921
    Views
    143,402

    it's a template queue so it's on the stack since...

    it's a template queue so it's on the stack since it's created at compile time not runtime, 16 would queue 16 message frames.
    If you are not using events() and directly firing interrupts, the RX...
Results 1 to 50 of 500
Page 1 of 10 1 2 3 4