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
    670
    Views
    61,306

    https://github.com/tonton81/FlexCAN_T4/issues/9

    https://github.com/tonton81/FlexCAN_T4/issues/9
  2. Replies
    670
    Views
    61,306

    Thats alot to explain, but what it comes all down...

    Thats alot to explain, but what it comes all down to is just giving it an ID to match to and the hardware will filter that from the rest of the frames. Each instance of can1/2/3 is a completely...
  3. Replies
    670
    Views
    61,306

    I don't see a need to filter excessively each id....

    I don't see a need to filter excessively each id. FIFO has 128 filters however only the first 32 are independant, the rest work off a global filter that doesn't sense to use. There are also 64...
  4. if it has it then no, you can verify the...

    if it has it then no, you can verify the resistance of the line with a multimeter on CANH and CANL, it should show about 60 ohms if both sides have 120 ohm resistors
  5. should be a 120 ohm resistor on CANH accross CANL...

    should be a 120 ohm resistor on CANH accross CANL at both furthest ends of the bus. if you have only 2 devices then put 120 ohm resistor at the sensor side and one at teensy side:

    CANH <--> 120...
  6. you checked your line terminations? i assume the...

    you checked your line terminations? i assume the sensor doesnt have one?

    i can connect a car sensor directly to t4 and it works at 125kbps as well, doesn't mean the higher speeds will work :)
  7. you need to use setClock(CLK_60MHz); also make...

    you need to use setClock(CLK_60MHz);

    also make sure your line terminations on CAN are correct or it may not work at all speeds
  8. 1000 does work, maybe the clock timings are...

    1000 does work, maybe the clock timings are different for your application (device your connected to), try changing the clock? can.setClock(clock speed) then run setBaudRate again, default is 24, you...
  9. Replies
    2
    Views
    122

    no, and it's faster than external eeproms

    no, and it's faster than external eeproms
  10. Replies
    11
    Views
    507

    I dont have a scope just mentioning it :) it...

    I dont have a scope just mentioning it :)

    it probably should look better without the mutex, because the way you had it it would wait for a release before toggling. I don't see you do this in...
  11. Replies
    11
    Views
    507

    if you put a delay in a mutex block and share...

    if you put a delay in a mutex block and share that block accross other threads, of course the mutex would block and not run in parallel, and that output would be expected
  12. Replies
    6
    Views
    163

    timers and interrupts need a volatile variable if...

    timers and interrupts need a volatile variable if the variable is shared with the loop(). This tells the compiler that the variable can change at any time from many sources so it has to always be...
  13. you can confirm if it blocks if using threads,...

    you can confirm if it blocks if using threads, check for speed difference
  14. Replies
    9
    Views
    314

    they all equal 1, therefore only OUTPUT statement...

    they all equal 1, therefore only OUTPUT statement gets selected
  15. youll have to modify the source

    youll have to modify the source
  16. Replies
    11
    Views
    507

    you could try: https://github.com/geky/coru ...

    you could try:
    https://github.com/geky/coru

    Speeduino users use it in their code, works accross several MCUs
  17. Replies
    11
    Views
    507

    teensythreads has mutexes

    teensythreads has mutexes
  18. Replies
    11
    Views
    248

    you are casting a const string, do you think you...

    you are casting a const string, do you think you should be modifying that?

    the first one is just initializing the char array, this is expected behaviour for both..
  19. Replies
    1
    Views
    112

    that depends on the library how flexible it is to...

    that depends on the library how flexible it is to CAN libraries. I don't use CANopen myself but if there's CANopen libraries that compile on teensy with previous flexcan libraries then I'm sure we...
  20. Replies
    670
    Views
    61,306

    you need to use the "FIFO with interrupts"...

    you need to use the "FIFO with interrupts" example and use the same loop() with delay you added earlier, then you'll see the responses every 5 seconds you transmit, according to the xlsx, you'll get...
  21. Replies
    670
    Views
    61,306

    this? #include CAN_message_t...

    this?



    #include <IFCT.h>

    CAN_message_t msg;

    void setup() {
    Can0.setBaudRate(125000);
  22. Replies
    670
    Views
    61,306

    try using the FIFO with interrupts example so you...

    try using the FIFO with interrupts example so you can see what the responses are, then try to send the message with byte0 as 1 and byte 1 as 0 and repeat send in loop with delay(5), see what it...
  23. Replies
    670
    Views
    61,306

    1 then 0 workes because on the chart, Online in...

    1 then 0 workes because on the chart, Online in green is for CAN, because you were sending 1 then 1, you actually disabled canbus so the normal voltage would be output, Offline meant no canbus...
  24. Replies
    670
    Views
    61,306

    did you read last line of the xlsx? :) ...

    did you read last line of the xlsx? :)




    The rectifier can operate in two states:
    Off-line is when there is no CAN communication (i.e. standalone operation). This occurs on...
  25. Replies
    670
    Views
    61,306

    well you need the manual for it then, i tried...

    well you need the manual for it then, i tried googling and came up with this:
    https://github.com/craigpeacock/Huawei_R4850G2_CAN/blob/main/Protocol.xlsx

    the IDs dont match what your sending or...
  26. Replies
    670
    Views
    61,306

    thats a different id and doesnt correlate to your...

    thats a different id and doesnt correlate to your sends, is the device sending you that? what is the device?
  27. Replies
    670
    Views
    61,306

    have you checked with a can bus analyzer to see...

    have you checked with a can bus analyzer to see if data is going out? or try another can-equipped bus just to see if you can read the bus (using FIFO example). If you can't read the bus don't expect...
  28. Replies
    670
    Views
    61,306

    No thats the way it sends, something wrong in...

    No thats the way it sends, something wrong in your setup. if IFCT and FlexCAN_T4 both don't work it'd definately not the code :)
  29. Replies
    670
    Views
    61,306

    MCP2551 is a 5V transceiver, you need to make...

    MCP2551 is a 5V transceiver, you need to make sure the communication is done at 3.3V or you risk damaging the pin on teensy. Or look for a 3.3V transceiver
  30. Replies
    670
    Views
    61,306

    if you dont read them they will stay full....

    if you dont read them they will stay full. reception and transmission have different mailboxes and dont depend on each other. You should try printing mailboxStatus() every couple seconds then, if it...
  31. Replies
    670
    Views
    61,306

    Is your CAN line properly terminated? what...

    Is your CAN line properly terminated? what happens if you put can1.events() in the loop()?
  32. Replies
    670
    Views
    61,306

    ahh okay sorry Teensy 3.x doesn't use setClock,...

    ahh okay sorry Teensy 3.x doesn't use setClock, 4.x only.

    you need to put that msg.flags.extended with your message you wanna send. put it under your msg.id = 0x108180fe;
  33. Replies
    670
    Views
    61,306

    msg.flags.extended = 1; this must be set...

    msg.flags.extended = 1;

    this must be set BEFORE writing, or else your extended ID will truncate to a standard ID and it will not be the one you wanted for your device

    also try adding in setup:...
  34. Replies
    670
    Views
    61,306

    it looks like you are flooding the bus with...

    it looks like you are flooding the bus with writes, are you sure the device can process the data that fast? usually on cars we need to space the transmissions to a device at like 10ms, but your loop...
  35. Replies
    21
    Views
    683

    is it possible the voltage at the usb is...

    is it possible the voltage at the usb is unstable? are you powering from VIN? There used to be old Alpha power supplies that would fry computer parts.. 😆
  36. Replies
    21
    Views
    683

    do you have high definition pictures of both...

    do you have high definition pictures of both sides of the PCB of both boards?
  37. if you want a schematic of usb-c skpang has...

    if you want a schematic of usb-c skpang has breakout boards for T4.x canbus, they use usb-c and/or 12v car input
  38. charging devices have power profiles for usb-c, a...

    charging devices have power profiles for usb-c, a protocol must be communicated to allow switching to higher voltages if supported by the adaptor. power is defaulted to 5v on connection and unless...
  39. it doesnt matter as you are still limited to the...

    it doesnt matter as you are still limited to the 500mA current max
  40. Tri-state is not a CS issue unless you have both...

    Tri-state is not a CS issue unless you have both CS' asserted. The issue is at MISO, some chips don't tri-state that line and it fights with the other slave that is ran in parallel. tri-state buffers...
  41. Replies
    670
    Views
    61,306

    volatile without events(), doesn't matter with...

    volatile without events(), doesn't matter with events()
  42. Replies
    670
    Views
    61,306

    if you don't use events(), message reception is...

    if you don't use events(), message reception is fired directly to callbacks. I too use CAN button counting for OEM keyfob to control windows and sunroof, obviously you need to count them not in the...
  43. Replies
    18
    Views
    550

    i use a RaspPi 8xmcp23s17 breakout board on...

    i use a RaspPi 8xmcp23s17 breakout board on Teensy4, I only needed to run 6 wires between teensy and the breakoutboard to get 128gpio support at 10mhz
  44. Replies
    670
    Views
    61,306

    mailbox holds one frame only, FIFO holds 6

    mailbox holds one frame only, FIFO holds 6
  45. Replies
    670
    Views
    61,306

    also if a mailbox gets a similar frame in other...

    also if a mailbox gets a similar frame in other than it's own in filter mode, an overrun would occur and the frame would be overwritten. example without filters is, if all the mailboxes fill up...
  46. Replies
    2
    Views
    163

    so you want the CAN on 29 and 30 or 3 & 4? to set...

    so you want the CAN on 29 and 30 or 3 & 4? to set pins as input you must set them as input

    pinMode(pin, INPUT)
  47. Replies
    670
    Views
    61,306

    mailboxes are like a drop box queue, each one can...

    mailboxes are like a drop box queue, each one can hold one receive (or transmit) message, the others wait in line to grab the next one. FIFO (rx only) is 6 messages deep, in reception order....
  48. Replies
    670
    Views
    61,306

    oh good you got it working

    oh good you got it working
  49. Ouch, Strings....... Did you try to comment out...

    Ouch, Strings....... Did you try to comment out all Serial2* calls and see if it freezes? that will rule out serial....
  50. Replies
    670
    Views
    61,306

    voltage seems about right, are the pins maybe...

    voltage seems about right, are the pins maybe reversed?
Results 1 to 50 of 500
Page 1 of 10 1 2 3 4