Project Home
Project Home
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - simple ping using bsp mx53 driver: (5 Items)
   
simple ping using bsp mx53 driver  
Hi,

I am attempting to do a simple ping between my PC and our platform running QNX 6.5.0 without any success.

After boot I am doing the following.....

#io-pkt-v4 -d mx53 mac=xxxxxxxxxxxx,verbose=10

#ifconfig
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 33192
        inet 127.0.0.1 netmask 0xff000000
fec0: flags=8a02<BROADCAST,ALLMULTI,SIMPLEX,MULTICAST> mtu 1500
        address: 00:04:9f:cc:9a:b5
        media: Ethernet none

# ifconfig fec0 192.168.128.161

# ifconfig
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 33192
        inet 127.0.0.1 netmask 0xff000000
fec0: flags=8a43<UP,BROADCAST,RUNNING,ALLMULTI,SIMPLEX,MULTICAST> mtu 1500
        address: 00:04:9f:cc:9a:b5
        media: Ethernet autoselect (100baseTX full-duplex)
        status: active
        inet 192.168.128.161 netmask 0xffffff00 broadcast 192.168.128.255

# ping 192.168.128.1
PING 192.168.128.1 (192.168.128.1): 56 data bytes
ping: sendto: Host is down
ping: sendto: Host is down
ping: sendto: Host is down
ping: sendto: Host is down

----192.168.128.1 PING Statistics----
11 packets transmitted, 0 packets received, 100% packet loss

# nicinfo
fec0:
  IMX 51 FEC Ethernet Controller

  Physical Node ID ........................... 000000 000000
  Current Physical Node ID ................... 00049F CC9AB5
  Current Operation Rate ..................... 100.00 Mb/s full-duplex
  Active Interface Type ...................... MII
    Active PHY address ....................... 0
  Maximum Transmittable data Unit ............ 1500
  Maximum Receivable data Unit ............... 1500
  Hardware Interrupt ......................... 0x57
  Memory Aperture ............................ 0x9f00000000 - 0x63fecfff
  Promiscuous Mode ........................... Off
  Multicast Support .......................... Disabled

  Packets Transmitted OK ..................... 6
  Bytes Transmitted OK ....................... 384
  Broadcast Packets Transmitted OK ........... 6
  Multicast Packets Transmitted OK ........... 0
  Memory Allocation Failures on Transmit ..... 0

  Packets Received OK ........................ 8
  Bytes Received OK .......................... 536
  Broadcast Packets Received OK .............. 0
  Multicast Packets Received OK .............. 0
  Memory Allocation Failures on Receive ...... 0

  Late Collision on Transmit errors .......... 0
  Transmits aborted (excessive collisions) ... 0
  Transmit Underruns ......................... 0
  Receive Alignment errors ................... 0
  Received packets with CRC errors ........... 2
  Packets Dropped on receive ................. 0
  Ethernet Header length field mismatches .... 0
  Oversized Packets received ................. 0
  Short packets .............................. 0
  Invalid Symbol Errors ...................... 0
  Total Frames experiencing Collison(s) ...... 0

As far as I can tell this all looks good apart from the CRC errors. Would this prevent a successful ping?

Packets are being sent and received according to nicinfo.

I also try from the PC side and get 100% packet loss as well.

Is there anything I have missed in the above or is there something else I could try?

Thanks
Simon
Re: simple ping using bsp mx53 driver  
Try...

route add default 192.x.x.x

where 192.x.x.x is the "default gateway" on your network.  The default gateway is set when using DHCP, but not in static
 case.
Re: simple ping using bsp mx53 driver  
Hi, thanks for the reply.

I forgot to mention the PC is connected directly to the platform. The PC has a static IP of 192.168.128.1 and the 
platform a static of 192.168.128.2 (actually this is set manually so change it from time to time but on same subnet).

Tried route but wasn't sure exactly what to set it to for a point-point connection. At the platform end I tried...

route add default 192.168.128.1   (not sure about this)

Anyway no improvement. I have observed the following....

1. When I ping from the PC (4 packets) the Packets Received OK at the platform end increase by 4.
    But the Transmitted values at the platform end do not increase.

   Do I need something running on the QNX platform to turn these around or is this the job of the driver?
   I tried inetd but I believe this is to route packets to ports. I believe ping does not use this.

2. When I ping from the platform end the Transmitted values increase as expected. The PC shows no
    packets received.

I am now thinking there is a HW fault, TX side. However, with the ping from the PC and the fact that the platform 
receives the packets I still would have expected the transmitted bytes to have increased.

Any thoughts/suggestions?

Thanks
Simon
Re: simple ping using bsp mx53 driver  
I connected a PC to a usb ethernet dongle and used the asix driver and ping works ok in both directions on the same 
device.

Possibly a driver and/or HW problem?

Any tips on debugging this issue with the bsp mx53 driver?

Thanks
Simon
Re: simple ping using bsp mx53 driver  
Hi,

Realised I haven't reported back on my resolution.

Turned out mx53 pads were not set correctly and that the driver was set to use RMII when HW was connected for MII.

Hope this helps someone.
Simon