This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux SDK

Other Parts Discussed in Thread: TPS65217, ISO1050

I have a Bone and evm SK I followed this here http://processors.wiki.ti.com/index.php/AMSDK_Linux_User%27s_Guide

I dont see all the def_configs listed in this doc? did I grab the wrong SDK?

 in my tree I downloaded the Bone SDK all I saw was the tisdk_am335x-evm_defconfig

 

I did a make linux

Do I need to set any jumpers and which board should I try this image on the Bone or EVM ? I looked at Bone quick start and it apppears it boots over ethernet do I need a cross over cable or a switch. It seems like since I am newbie I probally should use prebuilt Bone images to get started

 

Please give me a push start for Bone I would eventually like the kernel that support the CAN capes I have a white Bone

Thanks

 

 

  • Here shows the build and the SDK I unzipped please confirm if this will only work on the EVM and how and what i need to boot this

     

    ===================================
    Installing the Linux Kernel
    ===================================
    install -d /home/lazarman/ti-sdk-am335x-evm-05.07.00.00/targetNFS/boot
    install /home/lazarman/ti-sdk-am335x-evm-05.07.00.00/board-support/linux-3.2.0-psp04.06.00.10/arch/arm/boot/uImage /home/lazarman/ti-sdk-am335x-evm-05.07.00.00/targetNFS/boot
    install /home/lazarman/ti-sdk-am335x-evm-05.07.00.00/board-support/linux-3.2.0-psp04.06.00.10/vmlinux /home/lazarman/ti-sdk-am335x-evm-05.07.00.00/targetNFS/boot
    install /home/lazarman/ti-sdk-am335x-evm-05.07.00.00/board-support/linux-3.2.0-psp04.06.00.10/System.map /home/lazarman/ti-sdk-am335x-evm-05.07.00.00/targetNFS/boot
    make -C /home/lazarman/ti-sdk-am335x-evm-05.07.00.00/board-support/linux-3.2.0-psp04.06.00.10 ARCH=arm CROSS_COMPILE=/home/lazarman/ti-sdk-am335x-evm-05.07.00.00/linux-devkit/bin/arm-arago-linux-gnueabi- INSTALL_MOD_PATH=/home/lazarman/ti-sdk-am335x-evm-05.07.00.00/targetNFS modules_install
    make[1]: Entering directory `/home/lazarman/ti-sdk-am335x-evm-05.07.00.00/board-support/linux-3.2.0-psp04.06.00.10'
      INSTALL crypto/tcrypt.ko
      INSTALL drivers/hid/hid-logitech-dj.ko
      INSTALL drivers/scsi/scsi_wait_scan.ko
      INSTALL drivers/usb/gadget/g_ether.ko
      INSTALL drivers/usb/gadget/g_file_storage.ko
      INSTALL drivers/usb/gadget/g_mass_storage.ko
      DEPMOD  3.2.0
    make[1]: Leaving directory `/home/lazarman/ti-sdk-am335x-evm-05.07.00.00/board-support/linux-3.2.0-psp04.06.00.10'
    lazarman@ubuntu:~/ti-sdk-am335x-evm-05.07.00.00$

  • Hi Mark,

    From your logs I can see that you are using the correct SDK.

    The AM335x SDK supports both the EVM and the BeagleBone. The defconfig to be used with both is "am335x_evm_defconfig" - it works with the BeagleBone. If you take a look inside the board config file, which is located in <linux_folder>/arch/arm/mach-omap2/board-am335xevm.c, you will understand how the same source code supports both the EVM and the BeagleBone.

    Booting over the ethernet on the BeagleBone is possible, but I suggest you first confirm that everything is working just fine with the prebuilt images. They are located inside <sdk_folder>/board-support/prebuilt-images/.

    You will need a switch or a router and an Ethernet cable, as shown in this guide: http://processors.wiki.ti.com/index.php/Sitara_Linux_Software_Developer%E2%80%99s_Guide#Start_your_Linux_Development

    Best regards,
    Miroslav

  • Last night I booted the Bone off SD  

    Is  the intall script provided using prebuilt binaries ie pulling  from some sdk dir or using the results what I built using make linux?

    I need help on where to point the script to the binaries I buIlt using the in SDK make linux command

    2) Will this kernel I built support CAN cape on Bone

  • Hi Mark,

    I assume you are referring to the create-sdcard.sh script. This script uses the binaries inside the prebuilt-images/ folder. Please note that you don't need to run the script every time you want to update your MLO/u-boot.img/uImage files. Just use a card reader to open the /boot partition of the SD card and copy the binaries there.

    Regarding your second question:

    The CANBus cape uses the following pins from the BeagleBone header:

    The BeagleBone CANBus Cape uses 7 signals including:

    • DGND
    • VDD_3V3EXP
    • RESET
    • I2C_SDA
    • I2C_SCL
    • UART1_TXD
    • UART1_RXD

    More information about this cape's pinout can be found here: http://beagleboardtoys.info/index.php?title=BeagleBone_CANBus

    Here is a picture showing the BeagleBone headers pinout: http://blog.protoneer.co.nz/wp-content/uploads/2013/05/beaglebone_pinout.jpg

    As far as I can see from the board file config, only the I2C2 pins are initialized. This can be confirmed by booting the board and mounting the debugfs:

    mount -t debugfs none /sys/kernel/debug/

    Then go to /sys/kernel/debug/omap_mux/ folder and check the pinmuxing for the different pins. Please note that I2C2_SDA and I2C2_SCL signals are pinmuxed on processor pads UART1_CTSN and UART1_RTSN respectively.

    root@am335x-evm:/sys/kernel/debug/omap_mux# cat uart1_ctsn
    name: uart1_ctsn.i2c2_sda (0x44e10978/0x978 = 0x0073), b NA, t NA
    mode: OMAP_MUX_MODE3 | AM33XX_PIN_INPUT_PULLUP | AM33XX_SLEWCTRL_SLOW
    signals: uart1_ctsn | NA | NA | i2c2_sda | spi1_cs0 | NA | NA | gpio0_12
    root@am335x-evm:/sys/kernel/debug/omap_mux# cat uart1_rtsn
    name: uart1_rtsn.i2c2_scl (0x44e1097c/0x97c = 0x0073), b NA, t NA
    mode: OMAP_MUX_MODE3 | AM33XX_PIN_INPUT_PULLUP | AM33XX_SLEWCTRL_SLOW
    signals: uart1_rtsn | NA | NA | i2c2_scl | spi1_cs1 | NA | NA | gpio0_13

    Then check the pinmuxing of the UART1_RXD and UART1_TXD pads:

    root@am335x-evm:/sys/kernel/debug/omap_mux# cat uart1_rxd
    name: uart1_rxd.gpio0_14 (0x44e10980/0x980 = 0x0037), b NA, t NA
    mode: OMAP_MUX_MODE7 | AM33XX_PIN_INPUT_PULLUP
    signals: uart1_rxd | mmc1_sdwp | NA | i2c1_sda | NA | pr1_uart0_rxd_mux1 | NA | gpio0_14
    root@am335x-evm:/sys/kernel/debug/omap_mux# cat uart1_txd
    name: uart1_txd.gpio0_15 (0x44e10984/0x984 = 0x0037), b NA, t NA
    mode: OMAP_MUX_MODE7 | AM33XX_PIN_INPUT_PULLUP
    signals: uart1_txd | mmc2_sdwp | NA | i2c1_scl | NA | pr1_uart0_txd_mux1 | NA | gpio0_15

    Since they hadn't been initialized in the board config file, the pads have defaulted to gpio signals.

    Judging by that, the CANBus cape shouldn't work "out of the box". You will need to add a pinmux configuration in the board file, that initializes the UART1_RXD and UART1_TXD signals in the beaglebone_dev_cfg[] structure. You can use the uart1_wl12xx_pin_mux[] pinmux config structure as reference.

    Best regards,
    Miroslav

  • Hi Miroslav

    I think I can make these changes and rebuild the kernel OK

    I posted in this forum in a new thread that I cant build the modules correctly.

    With your suggested change I am guessing i will still need the correct linux config or will the default one work?

    I would like to avoid any dynamic kernel modules at first if possible. when I followed the dcan guide in menuconfig it forced me to make all my selected options modules as it said there was a dependency. Using this modified Linux config I can build the kernel but the modules build  fail complaining about touchscreen code

    I will make the mods to board file this is perfect place to start for me and await the answers about modules

    Thank you I have much hope with your expert guidance!

  • Some of the you have answered but any ideas about building modules errors http://e2e.ti.com/support/arm/sitara_arm/f/791/p/270576/945400.aspx#945400

  • Hi Miroslav

    The board-am335xevm.c has these 2 pinmuxes defined I am confused

    Can you through a dog the bone and give me the exact code (-: I am very green

    static struct pinmux_config d_can_gp_pin_mux[] = {
        {"uart0_ctsn.d_can1_tx", OMAP_MUX_MODE2 | AM33XX_PULL_ENBL},
        {"uart0_rtsn.d_can1_rx", OMAP_MUX_MODE2 | AM33XX_PIN_INPUT_PULLUP},
        {NULL, 0},
    };

    static struct pinmux_config d_can_ia_pin_mux[] = {
        {"uart0_rxd.d_can0_tx", OMAP_MUX_MODE2 | AM33XX_PULL_ENBL},
        {"uart0_txd.d_can0_rx", OMAP_MUX_MODE2 | AM33XX_PIN_INPUT_PULLUP},
        {NULL, 0},
    };

  • Also I see these

    static struct pinmux_config d_can_gp_pin_mux[] = {
        {"uart0_ctsn.d_can1_tx", OMAP_MUX_MODE2 | AM33XX_PULL_ENBL},
        {"uart0_rtsn.d_can1_rx", OMAP_MUX_MODE2 | AM33XX_PIN_INPUT_PULLUP},
        {NULL, 0},
    };

    static struct pinmux_config d_can_ia_pin_mux[] = {
        {"uart0_rxd.d_can0_tx", OMAP_MUX_MODE2 | AM33XX_PULL_ENBL},
        {"uart0_txd.d_can0_rx", OMAP_MUX_MODE2 | AM33XX_PIN_INPUT_PULLUP},
        {NULL, 0},
    };

  • Its very cryptic to see how that config works for both evm and bone  but looking at it the default config  it appears it has the options set I need for CAN????

    Looking deeper it looks to me setup_pin_mux(); needs to be called  after the correct pin mux is defined

  • Heres my best shot I dont see nwhere our how evm_dev_cfg beaglebone_dev_cfg is used But

    Pl\ease Let me know if this is correct

    static struct pinmux_config uart1_digikeycan_pin_mux[] = {
        {"uart1_rxd.uart1_rxd", OMAP_MUX_MODE0 | AM33XX_PIN_INPUT_PULLUP},
        {"uart1_txd.uart1_txd", OMAP_MUX_MODE0 | AM33XX_PULL_ENBL},
        {NULL, 0},
    };

    /* Beaglebone Rev A3 and after */
    static struct evm_dev_cfg beaglebone_dev_cfg[] = {
        {am335x_rtc_init, DEV_ON_BASEBOARD, PROFILE_NONE},
        {clkout2_enable, DEV_ON_BASEBOARD, PROFILE_NONE},
        {tps65217_init,    DEV_ON_BASEBOARD, PROFILE_NONE},
        {mii1_init,    DEV_ON_BASEBOARD, PROFILE_NONE},
        {usb0_init,    DEV_ON_BASEBOARD, PROFILE_NONE},
        {usb1_init,    DEV_ON_BASEBOARD, PROFILE_NONE},
        {mmc0_init,    DEV_ON_BASEBOARD, PROFILE_NONE},
        {i2c2_init,    DEV_ON_BASEBOARD, PROFILE_NONE},

        {d_can_init,    DEV_ON_DGHTR_BRD, PROFILE_NONE},
        {NULL, 0, 0},
    };

    static void d_can_init(int evm_id, int profile)
    {
        switch (evm_id) {
        case IND_AUT_MTR_EVM:
            if ((profile == PROFILE_0) || (profile == PROFILE_1)) {
                setup_pin_mux(d_can_ia_pin_mux);
                /* Instance Zero */
                am33xx_d_can_init(0);
            }
            break;
        case GEN_PURP_EVM:
        case GEN_PURP_DDR3_EVM:
            if (profile == PROFILE_1) {
                setup_pin_mux(d_can_gp_pin_mux);
                /* Instance One */
                am33xx_d_can_init(1);
            }
            break;
        default:

             setup_pin_mux(uart1_digikeycan_pin_mux);

             am33xx_d_can_init(0);
            break;
        }
    }

  • Hi,

    Depending on your board, the "evm_id" read from the EEPROM would differ. This is how the different evm_dev_cfg structures are used.

    The beaglebone_dev_cfg structure contains the initialization sequence for the BeagleBone.

    The UART1_TXD and UART1_RXD pins of the AM335x should be multiplexed to OMAP_MUX_MODE2 - respectively dcan1_rx and dcan1_tx. Your pinmux_config should look like this:

    static struct pinmux_config uart1_digikeycan_pin_mux[] = {
            {"uart1_rxd.dcan1_tx", OMAP_MUX_MODE2 | AM33XX_PIN_INPUT_PULLUP},
            {"uart1_txd.dcan1_rx", OMAP_MUX_MODE2 | AM33XX_PULL_ENBL},
            {NULL, 0},
    };

    For more information you may take a look at page 21 (Application information) of the ISO1050 CAN transceiver (http://www.ti.com/lit/ds/symlink/iso1050.pdf), which is used in the CANBus cape (check schematics).

    Please don't put the pinmux setup in the "default" case of the switch statement inside d_can_init(). Instead make a new case for the BeagleBone boards. Since you are pinmuxing dcan1 signals and not dcan0 signals, you should initialize dcan1 instance and not dcan0 instance:


    case BEAGLE_BONE_OLD:
    case BEAGLE_BONE_A3:
            setup_pin_mux(uart1_digikeycan_pin_mux);
            am33xx_d_can_init(1);
            break;

    Also, the BeagleBone doesn't have a daughter board, so the entry inside the beaglebone_dev_cfg structure should look like this:

    {d_can_init, DEV_ON_BASEBOARD, PROFILE_NONE},

    Best regards,
    Miroslav

  • Its been recognized now thanks not convinced its actually transmitting over the connector. Got some buffer unavailable messages as well