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.

RTOS/PROCESSOR-SDK-AM437X: EtherCAT Master problems

Part Number: PROCESSOR-SDK-AM437X
Other Parts Discussed in Thread: TPS65218, SYSBIOS, AM3359, AM4379

Tool/software: TI-RTOS

Hello,

   I am trying to establish ethercat communication between PC and Drive. I have taken EcMasterDemo code from acountis website.

I can see the following message  on putty after power up.

Welcome to MYIRTECH

MYIRTECH login: root

#

U-Boot SPL 2016.05 (Mar 01 2017 - 14:44:57)

Trying to boot from MMC2

SPL: Please implement spl_start_uboot() for your board

SPL: Direct Linux boot not active!

reading u-boot.img

reading u-boot.img

reading u-boot.img

reading u-boot.img

U-Boot 2016.05 (Mar 01 2017 - 14:44:57 +0800)

I2C: ready

DRAM: 512 MiB

PMIC: TPS65218

MMC: OMAP SD/MMC: 0, OMAP SD/MMC: 1

reading uboot.env

** Unable to read "uboot.env" from mmc0:1 **

Using default environment

Net: <ethaddr> not set. Validating first E-fuse MAC

Could not get PHY for cpsw: addr 0

Could not get PHY for cpsw: addr 1

Could not get PHY for cpsw: addr 1

Could not get PHY for cpsw: addr 6

cpsw, usb_ether

Hit any key to stop autoboot: 0

switch to partitions #0, OK

mmc0 is current device

SD/MMC found on device 0

reading boot.scr

** Unable to read file boot.scr **

reading uEnv.txt

** Unable to read file uEnv.txt **

switch to partitions #0, OK

mmc0 is current device

switch to partitions #0, OK

mmc0 is current device

SD/MMC found on device 0

** Invalid partition 2 **

switch to partitions #0, OK

mmc1(part 0) is current device

switch to partitions #0, OK

mmc1(part 0) is current device

SD/MMC found on device 1

4527760 bytes read in 554 ms (7.8 MiB/s)

48868 bytes read in 16 ms (2.9 MiB/s)

Booting from mmc1 ...

Kernel image @ 0x82000000 [ 0x000000 - 0x451690 ]

## Flattened Device Tree blob at 88000000

Booting using the fdt blob at 0x88000000

Loading Device Tree to 8fff1000, end 8ffffee3 ... OK

Starting kernel ...

[ 0.000000] Booting Linux on physical CPU 0x0

[ 0.000000] Initializing cgroup subsys cpu

[ 0.000000] Initializing cgroup subsys cpuacct

[ 0.000000] Linux version 4.1.18 (sunny@myir-server1) (gcc version 5.4.ldroot 2017.02-git-00458-g3a0e257) ) #1 PREEMPT Wed Mar 1 14:42:44 CST 201

[ 0.000000] CPU: ARMv7 Processor [412fc09a] revision 10 (ARMv7), cr=10c

[ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instn cache

[ 0.000000] Machine model: MYIR-TECH MYD_C437X_PRU Industrial Developme

[ 0.000000] cma: Reserved 24 MiB at 0x9e800000

[ 0.000000] Memory policy: Data cache writeback

[ 0.000000] CPU: All CPU(s) started in SVC mode.

[ 0.000000] AM437x ES1.2 (neon )

[ 0.000000] Built 1 zonelists in Zone order, mobility grouping on. Totes: 129920

[ 0.000000] Kernel command line: console=ttyO0,115200n8 root=PARTUUID=00-02 rw rootfstype=ext4 rootwait

[ 0.000000] PID hash table entries: 2048 (order: 1, 8192 bytes)

[ 0.000000] Dentry cache hash table entries: 65536 (order: 6, 262144 by

[ 0.000000] Inode-cache hash table entries: 32768 (order: 5, 131072 byt

[ 0.000000] Memory: 484792K/524288K available (6407K kernel code, 258K , 2392K rodata, 276K init, 234K bss, 14920K reserved, 24576K cma-reserved,ghmem)

[ 0.000000] Virtual kernel memory layout:

[ 0.000000] vector : 0xffff0000 - 0xffff1000 ( 4 kB)

[ 0.000000] fixmap : 0xffc00000 - 0xfff00000 (3072 kB)

[ 0.000000] vmalloc : 0xe0800000 - 0xff000000 ( 488 MB)

[ 0.000000] lowmem : 0xc0000000 - 0xe0000000 ( 512 MB)

[ 0.000000] pkmap : 0xbfe00000 - 0xc0000000 ( 2 MB)

[ 0.000000] modules : 0xbf000000 - 0xbfe00000 ( 14 MB)

[ 0.000000] .text : 0xc0008000 - 0xc08a005c (8801 kB)

[ 0.000000] .init : 0xc08a1000 - 0xc08e6000 ( 276 kB)

[ 0.000000] .data : 0xc08e6000 - 0xc0926bf0 ( 259 kB)

[ 0.000000] .bss : 0xc0929000 - 0xc0963bec ( 235 kB)

[ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1

[ 0.000000] Preemptible hierarchical RCU implementation.

[ 0.000000] Additional per-CPU info printed with stalls.

[ 0.000000] NR_IRQS:16 nr_irqs:16 16

[ 0.000000] L2C: platform modifies aux control register: 0x0e030000 -> 0000

[ 0.000000] L2C: DT/platform modifies aux control register: 0x0e030000 e430000

[ 0.000000] L2C-310 enabling early BRESP for Cortex-A9

[ 0.000000] OMAP L2C310: ROM does not support power control setting

[ 0.000000] L2C-310 ID prefetch enabled, offset 1 lines

[ 0.000000] L2C-310 dynamic clock gating disabled, standby mode disable

[ 0.000000] L2C-310 cache controller enabled, 16 ways, 256 kB

[ 0.000000] L2C-310: CACHE_ID 0x410000c9, AUX_CTRL 0x7e430000

[ 0.000000] OMAP clockevent source: timer2 at 24000000 Hz

[ 0.000015] sched_clock: 32 bits at 24MHz, resolution 41ns, wraps every484971ns

[ 0.000039] clocksource timer1: mask: 0xffffffff max_cycles: 0xffffffffidle_ns: 79635851949 ns

[ 0.000049] OMAP clocksource: timer1 at 24000000 Hz

[ 0.001209] Console: colour dummy device 80x30

[ 0.001247] Calibrating delay loop... 1196.85 BogoMIPS (lpj=5984256)

[ 0.090231] pid_max: default: 32768 minimum: 301

[ 0.090349] Security Framework initialized

[ 0.090402] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)

[ 0.090417] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 b

[ 0.091175] Initializing cgroup subsys blkio

[ 0.091202] Initializing cgroup subsys memory

[ 0.091259] Initializing cgroup subsys devices

[ 0.091278] Initializing cgroup subsys freezer

[ 0.091294] Initializing cgroup subsys perf_event

[ 0.091325] CPU: Testing write buffer coherency: ok

[ 0.091709] Setting up static identity map for 0x80008200 - 0x80008270

[ 0.093673] devtmpfs: initialized

[ 0.108173] VFP support v0.3: implementor 41 architecture 3 part 30 var rev 4

[ 0.190395] clocksource jiffies: mask: 0xffffffff max_cycles: 0xfffffff_idle_ns: 19112604462750000 ns

[ 0.192497] pinctrl core: initialized pinctrl subsystem

[ 0.193883] NET: Registered protocol family 16

[ 0.195702] DMA: preallocated 256 KiB pool for atomic coherent allocati

[ 0.220221] cpuidle: using governor ladder

[ 0.250212] cpuidle: using governor menu

[ 0.258030] OMAP GPIO hardware version 0.1

[ 0.259447] omap_gpio 481ae000.gpio: could not find pctldev for node /owkup@44c00000/scm@210000/pinmux@800/gpio3_pins_default, deferring probe

[ 0.259827] omap_gpio 48320000.gpio: could not find pctldev for node /owkup@44c00000/scm@210000/pinmux@800/gpio4_pins_default, deferring probe

[ 0.267743] No ATAGs?

[ 0.267783] hw-breakpoint: found 5 (+1 reserved) breakpoint and 1 watchregisters.

[ 0.267796] hw-breakpoint: maximum watchpoint size is 4 bytes.

[ 0.311080] edma 49000000.edma: TI EDMA DMA engine driver

[ 0.315618] vgaarb: loaded

[ 0.316212] SCSI subsystem initialized

[ 0.316911] omap_i2c 44e0b000.i2c: could not find pctldev for node /ocpup@44c00000/scm@210000/pinmux@800/i2c0_pins_default, deferring probe

[ 0.316973] omap_i2c 4819c000.i2c: could not find pctldev for node /ocpup@44c00000/scm@210000/pinmux@800/i2c2_pins_default, deferring probe

[ 0.317118] media: Linux media interface: v0.10

[ 0.317196] Linux video capture interface: v2.00

[ 0.317276] pps_core: LinuxPPS API ver. 1 registered

[ 0.317286] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfotti <giometti@linux.it>

[ 0.317326] PTP clock support registered

[ 0.318220] omap-mailbox 480c8000.mailbox: omap mailbox rev 0x400

[ 0.318511] Advanced Linux Sound Architecture Driver Initialized.

[ 0.319348] Switched to clocksource timer1

[ 0.331295] NET: Registered protocol family 2

[ 0.332220] TCP established hash table entries: 4096 (order: 2, 16384 b

[ 0.332289] TCP bind hash table entries: 4096 (order: 2, 16384 bytes)

[ 0.332355] TCP: Hash tables configured (established 4096 bind 4096)

[ 0.332462] UDP hash table entries: 256 (order: 0, 4096 bytes)

[ 0.332486] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)

[ 0.332675] NET: Registered protocol family 1

[ 0.333064] RPC: Registered named UNIX socket transport module.

[ 0.333080] RPC: Registered udp transport module.

[ 0.333088] RPC: Registered tcp transport module.

[ 0.333095] RPC: Registered tcp NFSv4.1 backchannel transport module.

[ 0.335657] futex hash table entries: 256 (order: -1, 3072 bytes)

[ 0.335764] audit: initializing netlink subsys (disabled)

[ 0.335826] audit: type=2000 audit(0.310:1): initialized

[ 0.343280] VFS: Disk quotas dquot_6.6.0

[ 0.343508] VFS: Dquot-cache hash table entries: 1024 (order 0, 4096 by

[ 0.345803] NFS: Registering the id_resolver key type

[ 0.345867] Key type id_resolver registered

[ 0.345878] Key type id_legacy registered

[ 0.345958] jffs2: version 2.2. (NAND) (SUMMARY) © 2001-2006 Red Hat,

[ 0.347981] NET: Registered protocol family 38

[ 0.348057] io scheduler noop registered

[ 0.348074] io scheduler deadline registered

[ 0.348146] io scheduler cfq registered (default)

[ 0.350780] pinctrl-single 44e10800.pinmux: 199 pins at pa f9e10800 siz

[ 0.353497] backlight supply power not found, using dummy regulator

[ 0.355562] wkup_m3_ipc 44e11324.wkup_m3_ipc: could not get rproc handl

[ 0.356917] Serial: 8250/16550 driver, 10 ports, IRQ sharing enabled

[ 0.360948] omap_uart 44e09000.serial: no wakeirq for uart0

[ 0.360993] omap_uart 44e09000.serial: No clock speed specified: using t: 48000000

[ 0.361173] 44e09000.serial: ttyO0 at MMIO 0x44e09000 (irq = 30, base_b3000000) is a OMAP UART0

[ 1.096909] console [ttyO0] enabled

[ 1.101246] omap_uart 481a6000.serial: no wakeirq for uart3

[ 1.107199] omap_uart 481a6000.serial: No clock speed specified: using t: 48000000

[ 1.115988] 481a6000.serial: ttyO3 at MMIO 0x481a6000 (irq = 31, base_b3000000) is a OMAP UART3

[ 1.126296] omap_uart 481aa000.serial: no wakeirq for uart5

[ 1.132676] [drm] Initialized drm 1.1.0 20060810

[ 1.150564] brd: module loaded

[ 1.159873] loop: module loaded

[ 1.164314] mtdoops: mtd device (mtddev=name/number) must be supplied

[ 1.229411] davinci_mdio 4a101000.mdio: davinci mdio revision 1.6

[ 1.235877] davinci_mdio 4a101000.mdio: detected phy mask ffffffef

[ 1.243446] libphy: 4a101000.mdio: probed

[ 1.247699] davinci_mdio 4a101000.mdio: phy[4]: device 4a101000.mdio:04er Atheros 8035 ethernet

[ 1.258303] cpsw 4a100000.ethernet: Missing slave[1] phy_id property

[ 1.265146] cpsw 4a100000.ethernet: Detected MACID = 60:64:05:05:65:5b

[ 1.274124] mousedev: PS/2 mouse device common for all mice

[ 1.280244] i2c /dev entries driver

[ 1.286042] omap_hsmmc 48060000.mmc: Got CD GPIO

[ 1.349774] ledtrig-cpu: registered to indicate activity on CPUs

[ 1.356814] remoteproc0: wkup_m3 is available

[ 1.361624] remoteproc0: Note: remoteproc is still under development asidered experimental.

[ 1.371153] remoteproc0: THE BINARY FORMAT IS NOT YET FINALIZED, and bd compatibility isn't yet guaranteed.

[ 1.384549] oprofile: no performance counters

[ 1.389299] oprofile: using timer interrupt.

[ 1.394298] Initializing XFRM netlink socket

[ 1.398870] NET: Registered protocol family 17

[ 1.403702] NET: Registered protocol family 15

[ 1.408531] Key type dns_resolver registered

[ 1.413376] omap_voltage_late_init: Voltage driver support not added

[ 1.420578] cpu cpu0: of_pm_voltdm_notifier_register: Failed to get cpulator/voltdm: -517

[ 1.429882] cpu cpu0: cpu0 clock notifier not ready, retry

[ 1.436105] ThumbEE CPU extension supported.

[ 1.440725] Registering SWP/SWPB emulation handler

[ 1.448663] GPIO line 104 (EMMC_RST) hogged as output/high

[ 1.455451] GPIO line 147 (SelPRUorLCDEN) hogged as output/low

[ 1.461735] GPIO line 149 (SelPRUorLCDSEL) hogged as output/low

[ 1.490196] rtc-rx8025t 0-0032: rtc core: registered rx8025t as rtc0

[ 1.508131] omap_i2c 44e0b000.i2c: bus 0 rev0.12 at 400 kHz

[ 1.515320] omap_i2c 4819c000.i2c: bus 2 rev0.12 at 100 kHz

[ 1.522408] omap_uart 481aa000.serial: no wakeirq for uart5

[ 1.528395] omap_uart 481aa000.serial: No clock speed specified: using t: 48000000

[ 1.537039] remoteproc0: powering up wkup_m3

[ 1.541687] remoteproc0: Booting fw image am335x-pm-firmware.elf, size3

[ 1.550167] remoteproc0: remote processor wkup_m3 is now up

[ 1.556168] wkup_m3_ipc 44e11324.wkup_m3_ipc: CM3 Firmware Version = 0x

[ 1.563645] 481aa000.serial: ttyO5 at MMIO 0x481aa000 (irq = 32, base_b3000000) is a OMAP UART5

[ 1.575440] omap_hsmmc 48060000.mmc: Got CD GPIO

[ 1.659766] cpu cpu0: of_pm_voltdm_notifier_register: Fail calculating e latency[1100000<->1325000]:-22

[ 1.670666] cpu cpu0: of_pm_voltdm_notifier_register: Fail calculating e latency[1100000<->1325000]:-22

[ 1.683016] rtc-rx8025t 0-0032: setting system clock to 1970-01-01 00:1TC (842)

[ 1.694861] ALSA device list:

[ 1.697999] No soundcards found.

[ 1.702343] Waiting for root device PARTUUID=00000000-02...

[ 1.717633] mmc0: host does not support reading read-only switch, assumite-enable

[ 1.730895] mmc0: new high speed SDHC card at address aaaa

[ 1.737166] mmcblk0: mmc0:aaaa JULIE 14.8 GiB

[ 1.746112] mmcblk0: p1

[ 1.793010] mmc1: MAN_BKOPS_EN bit is not set

[ 1.800799] mmc1: new high speed MMC card at address 0001

[ 1.806959] mmcblk1: mmc1:0001 Q2J54A 3.59 GiB

[ 1.811955] mmcblk1boot0: mmc1:0001 Q2J54A partition 1 16.0 MiB

[ 1.818363] mmcblk1boot1: mmc1:0001 Q2J54A partition 2 16.0 MiB

[ 1.825873] mmcblk1: p1 p2

[ 1.965652] EXT4-fs (mmcblk1p2): recovery complete

[ 1.971224] EXT4-fs (mmcblk1p2): mounted filesystem with ordered data mpts: (null)

[ 1.980122] VFS: Mounted root (ext4 filesystem) on device 179:10.

[ 1.987664] devtmpfs: mounted

[ 1.991356] Freeing unused kernel memory: 276K (c08a1000 - c08e6000)

INIT: version 2.88 booting

[ 2.154298] EXT4-fs (mmcblk1p2): re-mounted. Opts: errors=remount-ro,daered

INIT: Entering runlevel: 3

Starting logging: OK

modprobe: module mmc_core not found in modules.dep

modprobe: module mmc_block not found in modules.dep

modprobe: module omap_hsmmc not found in modules.dep

Populating /dev using udev: [ 3.022407] ov2659 0-0030: Sensor detectiond (3030, 0)

[ 3.379087] PM: bootloader does not support rtc-only!

[ 3.676646] prueth 54400000.pruss:pruss1_eth: port 1: using random MAC c2:ac:a3:b6:b5:ca

[ 3.790713] prueth 54400000.pruss:pruss1_eth: port 2: using random MAC 6a:7e:a2:2b:4e:18

done

Initializing random number generator... done.

Starting network: [ 4.849929] libphy: PHY not found

[ 4.853524] net eth0: phy not found on slave 1

udhcpc: started, v1.25.1

udhcpc: sending discover

udhcpc: sending discover

udhcpc: sending discover

udhcpc: no lease, failing

FAIL

Starting sshd: OK

Initializing SGX graphics driver PVR:(Error): OpenServices: Cannot open deriver /dev/omapdrm_pvr. [140, /pvr_bridge_u.c]

PVR:(Error): PVRSRVInitSrvConnect: PVRSRVConnect failed [2572, /bridged_pv.c]

PVR:(Error): SrvInit: PVRSRVInitSrvConnect failed (4) [37, /srvinit.c]

PVR:(Error): main: SrvInit failed (4) [49, /pvrsrvinit.c]

FAIL

so help me out.

Thanks in Advance.

 

  • Part Number: PROCESSOR-SDK-AM437X

    Tool/software: TI-RTOS

    Hello,

       I am trying to establish ethercat communication between PC and Drive. I have taken EcMasterDemo code from acountis website. The code is uild and debug successfully. ethercat cable is physically connected to drive and AM437x board. still i got the following message on putty after debug the code.

    SYS/BIOS EcMasterDemo CPSW Sample application
    0000000022: Full command line: -auxclk 2000 -v 2 -t 10000 -perf -cpsw 1 1 1 m am4 37x-idk
    0000000022: Run demo now with cycle time 2000 usec
    0000000022: Using AuxClock
    0000000022: OsMeasGet100kHzFrequency(): 600 MHz
    0000000022: ==========================
    0000000022: Initialize EtherCAT Master
    0000000022: ==========================
    0000000022: EC-Master V3.0.1.12 (Protected) for SYSBIOS Copyright acontis technol ogies GmbH @ 2018
    0000000045: mdio ACK missing
    0000000045: PHY initialization failed
    0000000045: EtherCAT network adapter MAC: 60-64-05-05-65-5B
    0000000226: Protected version, stop sending ethernet frames after 60 minutes if n ot licensed!
    0000000236: Scan bus mismatch for the first slave on bus
    0000000236: Expected Slave: EK1100 (0x44c2c52), Beckhoff Automation GmbH (0x2)
    0000000236: Found Slave...: ----
    0000000236: Cannot scan bus: ERROR: Ethernet link cable disconnected (0x9811002d)
    0000000236: ========================
    0000000236: Shutdown EtherCAT Master
    0000000236: ========================
    0000000238: ===================================================================== =======
    0000000238: PerfMsmt 'JOB_ProcessAllRxFrames' (min/avg/max) [usec]: 0.4/ 3.6 / 6.8
    0000000238: PerfMsmt 'JOB_SendAllCycFrames ' (min/avg/max) [usec]: 0.3/ 1.8 / 8.2
    0000000238: PerfMsmt 'JOB_MasterTimer ' (min/avg/max) [usec]: 0.3/ 11.0 / 108.4
    0000000238: PerfMsmt 'JOB_SendAcycFrames ' (min/avg/max) [usec]: 0.3/ 1.6 / 3.4
    0000000238: PerfMsmt 'Cycle Time ' (min/avg/max) [usec]: 551.6/1317.2 /2153.2
    0000000238: PerfMsmt 'myAppWorkPd ' (min/avg/max) [usec]: 0.4/ 1.2 / 1.9
    0000000585: EcMasterDemo stop.

    Please help me.

    Thanks

  • Hi Sayali, the error shown above is due to "bus mistmatch" which means that your EC-Master is expecting an type of slave(s) network, but see other slaves or don't see any.

    This could happen if the Ethernet communication is not correct (ex, cable unplugged or connected to the wrong Ethernet port, slave is turn off, etc) or due to a mistmach in the ENI file. For your Information MasterENI.c is the file the master uses to understand which field buses are connected to it, and in which type of topology.

    From console error I think is the second option, console shows "Expected Slave: EK1100 (0x44c2c52), Beckhoff Automation GmbH (0x2)", which, if I recall correctly, is the Out-Of-Box slave used by EC-Master demo. You need to change MasterENI.c to reflect your network (which I believe is a servo drive).

    thank you,

    Paula

  • Hi,

     I am trying to put correct eni.c file and run the code. but still i got the same error on putty,"  Cannot scan bus: ERROR: Ethernet link cable disconnected (0x9811002d)". Also i checked that cable is connected  to correct port and slave is also powered on. the output on putty is :

    SYS/BIOS EcMasterDemo CPSW Sample application
    0000000022: Full command line: -auxclk 2000 -v 2 -t 10000 -perf -cpsw 1 1 1 m am 437x-idk
    0000000022: Run demo now with cycle time 2000 usec
    0000000022: Using AuxClock
    0000000022: OsMeasGet100kHzFrequency(): 600 MHz
    0000000022: ==========================
    0000000022: Initialize EtherCAT Master
    0000000022: ==========================
    0000000022: EC-Master V3.0.1.12 (Protected) for SYSBIOS Copyright acontis techno logies GmbH @ 2018
    0000000045: mdio ACK missing
    0000000045: PHY initialization failed
    0000000045: EtherCAT network adapter MAC: 60-64-05-05-65-5B
    0000000151: Protected version, stop sending ethernet frames after 60 minutes if not licensed!
    0000000161: Scan bus mismatch for the first slave on bus
    0000000161: Expected Slave: Unknown (0x3000600), Unknown (0x6a)
    0000000161: Found Slave...: ----
    0000000161: Cannot scan bus: ERROR: Ethernet link cable disconnected (0x9811002d )
    0000000161: ========================
    0000000161: Shutdown EtherCAT Master
    0000000161: ========================
    0000000162: ==================================================================== ========
    0000000162: PerfMsmt 'JOB_ProcessAllRxFrames' (min/avg/max) [usec]: 0.4/ 4. 6/ 6.8
    0000000162: PerfMsmt 'JOB_SendAllCycFrames ' (min/avg/max) [usec]: 0.3/ 2. 3/ 8.4
    0000000162: PerfMsmt 'JOB_MasterTimer ' (min/avg/max) [usec]: 0.3/ 13. 7/ 91.2
    0000000162: PerfMsmt 'JOB_SendAcycFrames ' (min/avg/max) [usec]: 0.3/ 2. 1/ 3.4
    0000000162: PerfMsmt 'Cycle Time ' (min/avg/max) [usec]: 553.6/1081. 6/2154.9
    0000000162: PerfMsmt 'myAppWorkPd ' (min/avg/max) [usec]: 0.4/ 1. 6/ 2.2
    0000000507: EcMasterDemo stop.

  • Hi Sayali, can you describe how are you generating MasterENI.c file from your slave ESI (.xml) file?

    thank you,

    Paula

  • Hello paula,

          I have taken ESI.xml file from kollmorgen site and convert this ESI file to ENI using EC engineer tool then convert  the new ENI.xml to a "c" file by following "http://software.acontis.com/EC-Master/2.9/EC-Master_V2.9-ClassB.pdf"(chapter 2.4.1.4.2).

      As per given in " http://www.ti.com/lit/ug/tiduaf8a/tiduaf8a.pdf" (Select the CPSW using jumpers J18 and J19 between pin 1 and 2 when Am3359 used as master)  So, Is there any need to do hardware setup for AM437x when used as master and select CPSW??  I tried connecting slave to EC engineer tool software to convert ESI to ENI file. The slave connected successfully on that software using same ethernet cable. So,there is no fault in cable and ENI file is also correct.

       DEMO_PARAMETERS in ATEMDemoConfig.h. is as follows:

    #define DEMO_PARAMETERS "-auxclk 500 -v 2 -t 10000 -perf " \
    "-cpsw " \
    "1 " /* port */ \
    "1 " /* mode */ \
    "1 " /* priority */ \
    "m " /* master flag */ \
    "custom am437x " /* custom board for AM33xx*/ \
    "0 " /* PHY address */ \
    "1 " /* PHY connection mode: RGMII */ \
    "0 " /* Not use DMA buffers */

  • Hi Sayali, few questions

    - Have you done sanity check of the Driver ESI? for example, checking your driver can connect via TwinCAT?

    - With respect to your question, no, there is no jumpers or any HW modification that you need to do on AM4379 IDK board. In the case of AM3359 ICEv2, PHY ports are shared between CPSW and PRU-ICSS EMAC, so that is the reason we need to use the jumpers.

    - After converting ENI.xml file to MasterENI.c file. Did you add, at the end of MasterENI.c, the printed in console data size to a MasterENI_xml_data_size variable?. Example below:

    unsigned int MasterENI_xml_data_size = 16426; 

    - I believe port numeration is correct inside ATEMDemoConfig.h, but if you want to do a quick test you can change port number to "0". 

    #elif (defined SOC_AM437x)
    #define DEMO_PARAMETERS "-auxclk 2000 -v 2 -t 10000 -perf " \
    "-cpsw " \
    "0 " /* port */ \
    "1 " /* mode */ \
    "1 " /* priority */ \
    "m " /* master flag */ \
    "am437x-idk " /* custom board for AM437x*/

    thank you,

    Paula

  • Hello,

     Thanks for reply.

    -Yes, I added unsigned int MasterENI_xml_data_size = 16426 at the end of MasterENI.c file.

    - I am using PRU-Ethernet 0 port . The  port numeration in ATEMDemoConfig.h file is as follows:-

      #elif (defined SOC_AM437x)
      #define DEMO_PARAMETERS "-auxclk 2000 -v 2 -t 10000 -perf " \
      "-cpsw " \
      "1 " /* port */ \
      "1 " /* mode */ \
      "1 " /* priority */ \
      "m " /* master flag */ \
      "am437x-idk " /* custom board for AM437x*/
      #endif

    -When I put "0" as port I got following error message on putty:-

    SYS/BIOS EcMasterDemo CPSW Sample application

    Port number must be 1 or 2

    SYNTAX_ERROR: -cpsw!

    Syntax:

    EcMasterDemo [-f ENI-FileName] [-t time] [-b time] [-a affinity] [-v lvl] [-perf] [-log Prefix] [-auxclk period] [-cpsw Instance Mode PortPriority MasterFlag [RefBoard CpswType PhyAddress PhyConnectionMode NotUseDmaBuffers]]

    -f Use given ENI file

    FileName file name .xml

    -t Demo duration

    time Time in msec, 0 = forever (default = 120000)

    -b Bus cycle time

    cycle time Cycle time in usec

    -a CPU affinity

    affinity 0 = first CPU, 1 = second, ...

    -v Set verbosity level

    lvl Level: 0=off, 1(default) ...n=more messages

    -perf Enable job measurement

    -log Use given file name prefix for log files

    Prefix prefix

    -flash Flash outputs

    address 0=all, >0 = slave address -auxclk use auxiliary clock

    period clock period in usec

    -cpsw Link layer = Texas Instruments Common Platform Switch (CPSW)

    Instance Device instance (port) 1 P1, 2 P2

    Mode Interrupt (0) or Polling (1)

    PortPriority Low priority (0) or high priority (1)

    MasterFlag (m) Master (Initialize Switch), (s) Slave

    RefBoard: custom | bone | am437x-idk | am572x-idk | 387X_evm (optional)

    if custom CpswType: am33XX | am437X | am57X | am387X

    if custom PhyAddress 0 .. 31

    if custom PhyConnection GMII (0) or RGMII (1)

    if custom NotUseDmaBuffers FALSE (0) or TRUE (1)

    EcMasterDemo stop.

  • Hi Sayali, as I just explained in your other thread we currently only have EC-Master developed for AM437x on CPSW interface. If you go to acontis-TI webpage you will see there different projects for  AM335x and AM572x to run on CPSW or PR-ICSS. But AM437x only has for CPSW.

    Please try to run using CPSW port.

    Thank you,

    Paula

  • Hi Paula,

        I change Ethernet  port J4 (Giga ethernet) as per your suggestion but still i got the same error.

  • Hi Sayali could you send me your CCS project? so, I can do a sanity test here with an AM4379 IDK, and with another slave (probably I would use AM3359 ICEv2)? 

    thank you,

    Paula