How to use M4 processor?

Discussion in 'UDOO NEO' started by mibu945, Jan 23, 2016.

  1. mibu945

    mibu945 New Member

    Joined:
    Jan 23, 2016
    Messages:
    1
    Likes Received:
    0
    I want to study heterogeneous systems.
    I must run C/C++ programs on M4, replacing to write arduino programs.
    How to do?


    Thanks
     
  2. waltervl

    waltervl UDOOer

    Joined:
    Dec 12, 2015
    Messages:
    2,314
    Likes Received:
    580
  3. jas-mx

    jas-mx Active Member

    Joined:
    Dec 31, 2013
    Messages:
    407
    Likes Received:
    118
    I would suggest :

    1. Spend some time understanding the cortex m3/m4 boot sequence (ie vector tables etc) if you are new to the subject.
    2. Review chapters 2,13,52,61 im6sx reference manual as they indicate differences/features for supporting A9 + M4.
    3. Understand how uboot is used to load & start an m4 program
    4. You can now develop using FreeRTOS on the imx6x, more information can found in the here. Download the RTOS tar and it contain docs + samples. Some of the samples require modification to work on the NEO but that's part of the learning curve. I have built some of them of so they will work.
     
    Last edited: Jan 24, 2016
    jrullan likes this.
  4. tcmichals

    tcmichals Member

    Joined:
    Feb 25, 2015
    Messages:
    54
    Likes Received:
    27
    FYI; to use rpmsg; you must patch the kernel; I was thinking of putting the patches at rpmsg-neo.
     
    graugans likes this.
  5. graugans

    graugans Administrator Staff Member

    Joined:
    Sep 17, 2015
    Messages:
    328
    Likes Received:
    141
    Can you please share your patches?
     
  6. aprchal

    aprchal New Member

    Joined:
    Jan 15, 2017
    Messages:
    1
    Likes Received:
    0
    Hi,

    sorry for reopening an old thread, but I'm struggling with rpmsg on udoobuntu (udoo neo). My ultimate goal is to have udoobuntu (A9) + freertos (M4), both communicating using rpmsg. Can somebody point out all the necessary changes that have to be done on udoobuntu side? So far I have crosscompiled a few kernel modules (virtio, virtio_ring, virtio_rpmsg_bus, rpmsg-neo, imx_rpmsg_tty, imx_rpmsg_pingpong) - the last two taken from http://git.freescale.com/git/cgit.cgi/imx/linux-imx.git/tree/drivers/rpmsg?h=imx_3.14.52_1.1.0_ga. However, after loading any of the rpmsg-neo or imx_rpmsg_* modules I have no rpmsg device in /dev. So I suppose that I am still missing something - maybe dtb or kernel modification?

    Thanks.
     
  7. tcmichals

    tcmichals Member

    Joined:
    Feb 25, 2015
    Messages:
    54
    Likes Received:
    27
    graugans and Andrea Rovai like this.
  8. Borbarad

    Borbarad New Member

    Joined:
    Mar 1, 2017
    Messages:
    4
    Likes Received:
    1
    @aprchal
    I'm using the kernel mentioned by @tcmichals. The problem is, that the dtb files didn't have entries for rpmsg. Even mor frustrating was, that dmesg | grep rpmsg produced this:
    [ 0.147736] imx rpmsg driver is registered.
    'imx6sx.dtsi' should contain a disabled entry.
    I added
    &rpmsg{
    status = "okay";
    };

    Now I dmesg | grep rpmsg returns an additional entry:
    [ 0.147631] virtio_rpmsg_bus virtio0: rpmsg host is online
    [ 0.147736] imx rpmsg driver is registered.

    Now the examples are working. I hope this helps.
     
    graugans likes this.

Share This Page