Enabling and Verifying Flexcan support

Discussion in 'UDOO NEO' started by jas-mx, Mar 3, 2016.

  1. Frank Traenkle

    Frank Traenkle New Member

    Joined:
    Apr 30, 2016
    Messages:
    3
    Likes Received:
    2
    Andrea Rovai and modjo like this.
  2. graugans

    graugans Administrator Staff Member

    Joined:
    Sep 17, 2015
    Messages:
    328
    Likes Received:
    141
    Andrea Rovai and modjo like this.
  3. oxoocoffee

    oxoocoffee Member

    Joined:
    Sep 13, 2016
    Messages:
    57
    Likes Received:
    6
    I was wondering if simply connecting Tx (Pin40) from one board to same pin on another (same with Pin41) would be enough to simply test before I will get transreivers? Do I still have to put resistor across?
     
  4. jas-mx

    jas-mx Active Member

    Joined:
    Dec 31, 2013
    Messages:
    407
    Likes Received:
    118
    As already mentioned its not possible (or that simple). The first post in the thread already covers the procedure for verifying without a transceiver.
     
  5. oxoocoffee

    oxoocoffee Member

    Joined:
    Sep 13, 2016
    Messages:
    57
    Likes Received:
    6
    Hello.

    I did read quite a lot about CAN by now but framing and from software perspective but need little help from electrical :)

    I got couple of these http://www.waveshare.com/wiki/SN65HVD230_CAN_Board#Support
    Loopback works fine. So I have couple of questions and do not want to damage my boards.

    Looking at dmesg I see these lines
    2090000.can supply xceiver not found, using dummy regulator. Is this issue? How does full proper
    dmesg | grep can looks like on yours?

    Update:

    I was able to figure this out and got it working :). Still wondering about above question related to xceiver not found.
     
    Last edited: Oct 22, 2016
  6. Randy Krakora

    Randy Krakora New Member

    Joined:
    Feb 2, 2016
    Messages:
    5
    Likes Received:
    0
    I've tried these, but it doesn't work for me. Seems to be not using the correct .dtb file on boot.

    My board uses this one:

    reading dts-overlay/imx6sx-udoo-neo-full-hdmi-m4.dtb

    This is my latest uEnv.txt:

    video_output=hdmi
    #m4_enabled=false
    #m4last=/path/to/arduino/sketch.fw
    fdt_file=imx6sx-udoo-neo-full-hdmi-can.dtb
    use_custom_dtb=true

    I've tried this:

    fdt_file=dts-overlay/imx6sx-udoo-neo-full-hdmi-can.dtb

    But it always still uses the same dtb file:

    reading dts-overlay/imx6sx-udoo-neo-full-hdmi-m4.dtb

    How can I make uboot read the proper dtb file? I don't find any examples of uEnv.txt and uboot, etc. so I don't know if what I am doing is even correct.

    Thanks,
    Randy Krakora
     
  7. jas-mx

    jas-mx Active Member

    Joined:
    Dec 31, 2013
    Messages:
    407
    Likes Received:
    118
    uboot overrides your fdt_file value when it detects the board type so the value is ignored. I'm not sure what your trying to achieve, however you can just copy your changed dtb to correct dtb in the overlay directory, that's the point of the overlay directory ie:

    Code:
    cp imx6sx-udoo-neo-full-hdmi-can.dtb  imx6sx-udoo-neo-full-hdmi.dtb
    
     
    Last edited: Feb 24, 2017
  8. Randy Krakora

    Randy Krakora New Member

    Joined:
    Feb 2, 2016
    Messages:
    5
    Likes Received:
    0
    Thanks for taking the time to reply, but it didn't answer my question, I was wanting to know how uEnv.txt worked, it appears to have some replacement environment variables in it to override uboot? But when I try to do that, it doesn't work. I know I could simply rename my file to imx6sx-udoo-neo-full-hdmi-m4.dtb and uboot would load it and things would work, but I just cannot do that in good conscience. Especially when the filenames are very relevant. Why should I rename my file to a name that isn't descriptive to me? It defeats the purpose of having filenames.

    And if uEnv.txt is useless, why is it used? Why not just have us change the uboot env. variable at boot for loading different .dtb files?

    And I wondered why my board was using the imx6sx-udoo-neo-full-hdmi-m4.dtb instead of the reading imx6sx-udoo-neo-full-hdmi.dtb file?

    Hopefully someone can point me to some docs or help describe how this works ( not only for me, but for other community members that may have questions about this now or in the future ).

    Thanks,
    Randy Krakora
     
  9. jas-mx

    jas-mx Active Member

    Joined:
    Dec 31, 2013
    Messages:
    407
    Likes Received:
    118
    Simple answer review the uboot source to find out why its happen and change/fix it to your preference.
     
  10. Randy Krakora

    Randy Krakora New Member

    Joined:
    Feb 2, 2016
    Messages:
    5
    Likes Received:
    0
    Thanks again, but not what I was looking for, I'm fine with reviewing the source, but in my opinion, if we have to review the source to figure out how uEnv.txt works, then why is uEnv.txt even part of the system? Makes no sense. Make the dtb/fdt filename a uboot variable we change and be done with it.

    "Review the source" could be the answer to just about any question I've seen in this forum. :)

    -RK
     
  11. jas-mx

    jas-mx Active Member

    Joined:
    Dec 31, 2013
    Messages:
    407
    Likes Received:
    118
    One for the udoo team to answer as it their design @Andrea Rovai.

    Like it or not and given the size of the community that's probably true.
     
  12. Roborigger

    Roborigger UDOOer

    Joined:
    Feb 21, 2022
    Messages:
    4
    Likes Received:
    0
    Hi,
    I am using ubuntu 18.04.3 LTS and I can't get the flexcan to work
    Cheers
     

Share This Page