========================================================================= LAN9500 console command line Utility Ver. 2.5 ========================================================================= 1. Overview =========== The LAN9500 command line Utility runs in a Windows Command prompt provide support for programming the EEPROM and testing basic LAN95xx functionality. 2. Device support ================= This utility supports the following devices: LAN9500 LAN9500A LAN9512 LAN9513 LAN9514 LAN9530 LAN89530 LAN9730 LAN89730 3. Supported Operating Systems Windows XP (x86), Windows 7 (x86/x64), Windows 8/8.1 (x86/x64). IMPORTANT NOTE: =============== 1. Before using the utility the latest Windows driver for LAN95xx/LAN9730/LAN89730/LAN89530 needs to be installed. 2. While using under Windows 8/8.1 the "Selective Suspend" driver advance properties (device manager -> controller -> properties -> advanced) needs to be disabled. 4. Files Manifest ================= 9500eepApp.EXE: Utility to program and verify EEPROM in the device 9514eep.ini ini file where settings are saved when programming a LAN9513/14 device 9512eep.ini ini file where settings are saved when programming a LAN9512 device 9500eep.ini ini file where settings are saved when programming a LAN9500 device 9500Aeep.ini ini file where settings are saved when programming a LAN9500A device 9530eep.ini ini file where settings are saved when programming a LAN9530/89530 device 9730eep.ini ini file where settings are saved when programming a LAN9730/LAN89730 device readme: This document 5. Networking Partner ------------------ To test the device using 9500eepApp.EXE on real network, a network partner is REQUIRED. The end network partner should be another machine with ping echo capabilities. The test partner system must be capable of (and configured to) autonegotiate advertising all 10/100 half/full duplex. 6. Starting LAN9500 Utility =========================== Open A Windows Command prompt with Administrator privilege and run this utility with the Parameters. 7. Utility Command Line Parameters Details ============================================== 9500eepApp [-X ] (-b -i )(-w -r) [-M -S -m -s -N ] [-l ] [-p ] [-L] [-h] [d] [-R ] [-W -v ] [-y ] [-Y -v ] [-x] [-G (v b l k p o)] -X Support for multiple adapters. If more than one LAN9500 is plugged in, all commands can be directed to a specific LAN9500. The index is a zero based number associated with the adapter. See -G commands for more info. -w Write the EEPROM Contents specified in the file + overwrites to the device and verify them. The input file specified with the -b or -i option will be updated after the verification is complete according to the -N option. -r Read the current EEPROM Contents in the device and write to the 9500eep_128.bin/9500eep_256/9500eep_512.bin binary file (depending on the device) under the current folder. -b Uses the binary file as "base" for the EEPROM contents. This option is mutually exclusive with the "-i" option, but either -b or -i must be present when operate write (-w) action. The Mac address and/or serial in the bin can be increased by using the -M/-S/-m/-s and -N options. -i Uses the options file as the "base" for the EEPROM Contents. This option is mutually exclusive with the "-b" option, but either -b or -i must be present when operate write (-w) action. The Mac address and/or serial in the ini can be increased by using the -M/-S/-m/-s and -N options. -M Overrides the mac address to the device eeprom with the mac_address provided. mac_address format is ab:cd:ef:gh:ij:kl with a thru l hexdigits (i.e. 00:80:0F:95:04:00). if -N is not specified, the binary/ini file will not be updated with the Mac Address, only the eeprom content that writen to the device get updated. -S Overrides the serial number to the device eeprom with the serial_num provided. Serial_num format is a 16 characters. if -N is not specified, the binary/ini file will not be updated with the serial number, only the eeprom content that writen to the device get updated. If the supplied serial number is not contain all hex digits (ie: other than 000950404 format) then serial number cannot be incremented with -N option. -m This option increase the mac address from the ini/binary file for the next write. The maximum increment step is 255. Any value less than or equal to 0 will be overrided with 1. It must be used with -N option. -s This option increase the Serial number from the ini/binary file for the next write. The maximum increment step is 255. Any value less than 0 will be overrided with 1. The value 0 means do not update serial number. If the value greater than 0 then -N option must be specified. -N Update ini or bin file with next mac address and serial number. Next mac address and serial number will be computed with -m and -s . If there is no -m or -s specified, the increament will be 1 if -N is specified. "-N" option is required when the "-m/-s" option is present. If the serial number in the binary/ini file or supplied with the -S option is not contain all hex digits then the increment serial will not work. -p Ping option. IP address must must be specified when the "-p" option is present. -L External loop back test. External loopback plug needed for this test. Don't need to specify IP address. Will ignore it. -l The utility will attempt to autonegotiate using one of the following restricted negotiation capabilities "10hd", "10fd", "100hd", "100fd". -R Read Control and Status register. The Register address as hex value. -W Write Control and Status register. Register address as hex value. The -v option should be used along with this option. -y Read PHY register. The PHY register index in hex. -Y Write PHY register. the PHY register index in hex. The -v option should be along with this option. -x Print Tx and Rx statistics -d Print EEPROM feilds -G -G commands cannot be used with any other commands except for -X. -G v Get driver version -G b Get adapter bits. Each bit represents an adapter. If 2 adapters are plugged in, you might see 0x03. That can be used to set the index with -X. -G l Get adapter location. For multiple adapters, this command helps identify the location of the adapter. An example is: "Port_#0006.Hub_#0007" Does not work on Windows XP. See -G p. -G k Get adapter registry key. For multiple adapters, this command returns the registry key for the adapter. An example is: "{4d36e972-e325-11ce-bfc1-08002be10318}\0015" If that is appended to: "HKLM\SYSTEM\CurrentControlSet\Control\Class\" You would have a full path to the registry key. -G p Get adapter port. For multiple adapters, this command returns the port number. On Windows XP -G l does not return the port number. This is an alternative. -G o Get adapter PDO name. For multiple adapters, this command returns the PDO name for the adapter. An example is: "\Device\USBPDO-9" -h Displays help menu. ---------------------------------------------------------------------------- 8. Ini file configurations: ========================== MAC Address [MacAddress]: This is the 6-byte universally unique Mac address the board will use. Bytes are separated by a colon. CurrentMacAddress - Defines the first MAC address (it will be incremented after Manual/Auto burn for the next device) MaximumMacAddress - Defines the last MAC address to be used before rolling over to 0. MacAddressIncrement - Will be added to Current MAC Address after successful EEPROM burn cycle (max is 255). Serial Number [SerialNumber]: This is the (unique for this model of device) USB serial number. It is a 9-digit hexadecimal number. CurrentSerialNumber - Defines the first Serial Number (it will be incremented after Manual/Auto burn for the next device) MaximumSerialNumber - Defines the last serial number to be used before rolling over. SerialNumberIncrement - Will be added to Current serial number after successful EEPROM burn cycle (max is 255). Strings [String]: The user can save 4 customized strings (Manufacturer, Product, Configuration and Interface) with different lengths in the EEPROM. Each string can be individually disabled or enabled. ID [ID]: VendorID - This is your company's USB Vendor Id. It is a 4-digit hexadecimal number ProductID - This is your device's USB Product Id. It is a 4-digit hexadecimal number BcdDevice - This is the release number you assign to the device. It is a 4-digit binary-coded decimal (BCD) number. For example revision 1.23 would be represented as bcdDevice=0123 FS/HS Interrupt Endpoint bInterval [PollingInterval]: Interval for polling the interrupt endpoint as defined in the bInterval field of the endpoint descriptor by the USB 2.0 specification. Illegal values will not be allowed; an error message will be displayed if one has been entered. (Valid ranges are 1-255 for Full Speed, 1-16 for High Speed). Power & Remote Wake [Power]: These parameters affect values of the USB configuration descriptor. Improper setups which violate the USB 2.0 specification will not be allowed. An error message will be displayed if an illegal value has been entered. RemoteWakeupEnable - To enable/disable remote USB wakeup capability (Enable when it is set to 1) BusPower - Select between BusPower/SelfPower device (Bus Power when it is set 1, 0 - for self power) MaxPower - Maximum Power Consumption in mA (between 2mA and 500mA for BusPower; between 0mA and 100mA for SelfPower) Configuration flags0 [ConfigFlags0]: PortSwap - Swaps the mapping of USBDP and USBDM. 0 = USBDP maps to the USB D+ line and USBDM maps to the USB D- line. 1 = USBDP maps to the USB D- line. USBDM maps to the USB D+ line. PHYBoost - Boost the electrical drive strength of the HS output current to the upstream port. 0 - Normal electrical drive strength 4 - Elevated electrical drive strength (+4% boost) 8 - Elevated electrical drive strength (+8% boost) 12 - Elevated electrical drive strength (+12% boost) DuplexDetection - When set MAC automatically determines the duplex operational mode. SpeedDetection - When set MAC automatically determines the speed of operation. SpeedLEDFunction - The value of this bit determines the operational mode of the speed LEDs (LED0 and LED1). 0 = LED0 and LED1 are Link and Speed LEDs 1 = LED0 and LED1 are Link and Speed and Activity LEDs GPIO Wake up [GPIOWake]: The GPIOWake0 to GPIOWake11 configures the GPIO wake up functionality. 0 = The GPIO can not wake up the device. 1 = The GPIO can trigger a wake up event. GPIO PME Flags [GPIOPME]: GPIOPMEEnable - Setting this bit enables the assertion of the GPIO5 pin, as a result of a Wakeup (GPIO) pin, Magic Packet, or PHY Link Up. The host processor may use the GPIO5 pin to asynchronously wake up, in a manner analogous to a PCI PME pin. 0 = The device does not support GPIO PME signaling. 1 = The device supports GPIO PME signaling. Note: When this bit is 0, the remaining GPIO PME parameters are ignored. GPIOPMEConfiguration - This bit selects whether the GPIO PME is signaled on the GPIO pin as a level or a pulse. 0 = GPIO PME is signaled via a level. 1 = GPIO PME is signaled via a pulse GPIOPMELength - When GPIOPMEConfiguration is set to 1 (pulse), this bit determines the duration of the pulse. 0 = GPIO PME pulse length is 1.5 mS. 1 = GPIO PME pulse length is 150 mS. GPIOPMEPolarity - Specifies the level of the signal or the polarity of the pulse used for GPIO PME signaling. 0 = GPIO PME signaling polarity is low. 1 = GPIO PME signaling polarity is high. GPIOBufferType - This bit selects the output buffer type for GPIO. 0 = Open drain driver / open source 1 = Push-Pull driver Note: Buffer Type = 0, Polarity = 0 implies Open Drain. Buffer Type = 0, Polarity = 1 implies Open Source. GPIOPMEWOLSelect - Selects WOL wakeup events or Link up wakeup events. 0 = WOL event wakeup supported. 1 = PHY linkup wakeup supported. Note: If WOL is selected, the PME Magic Packet Enable and PME Perfect DA Enable bits determine the WOL event(s) that will cause a wakeup. PMEMagicPacketEnable - When GPIOPMEWOLSelect set to 0 (WOL), this flag enables/disables Magic Packet detection and wakeup. 0 = Magic Packet event wakeup disabled. 1 = Magic Packet event wakeup enabled. PMEPerfectDAEnable - When GPIOPMEWOLSelect set to 0 (WOL), this flag enables/disables Perfect DA detection and wakeup. 0 = Perfect DA event wakeup disabled. 1 = Perfect DA event wakeup enabled. Configuration FLags1 [ConfigFlags1]: LED2Function - This flag specifies the functionality of LED2. 0 = LED2 is a Link and Activity LED 1 = LED2 is an Activity LED SWModeSelect - Specifies the modes of operation during which the SW_MODE pin will be asserted. 0 = SW_MODE asserted in SUSPEND2. 1 = SW_MODE asserted in SUSPEND2, SUSPEND1, and SmartDetach. SWModePolarity - Specifies the polarity of the SW_MODE pin. 0 = Active low. 1 = Active high. GPIOEnable0 - When set 0 GPIO-0 is enabled. When set to 1 the LED0 (speed LED) enabled. GPIOEnable1 - When set 0 GPIO-1 is enabled. When set to 1 the LED1 (speed LED) enabled. GPIOEnable2 - When set 0 GPIO-2 is enabled. If set to 1 the LED2 is enabled. GPIOEnable3 - When set 0 GPIO-3 is enabled. When set to 1 the LED3 (Link LED) will be enabled. GPIOEnable4 - when set to 0 GPIO-4 is enabled. When set to 1 the LED4 (Full Duplex LED) enabled. 9. Return Error code =================== SUCCESS 0 ERROR_FAIL 1 ERROR_NOMEM 2 ERROR_PARAMETER 3 ERROR_LINK 4 ERROR_EEPROMACCESS 5 ERROR_INVALIDEEPROMSIZE 6 ERROR_PING 7 ERROR_LOOPBACK 8 ERROR_EEPROMWRITE 9 ERROR_UPDATE 10 10. Release history =================== V2.5 (1/13/2015) - Added -d option to dump some of the eeprom fields (ex; MAC and serial for now). V2.4 (12/15/2014) - Added retries to EEPROM write V2.3 (07/21/2014) - Removed Non-SMSC adapter found message V2.2 (07/16/2014) - Fixed the loopback test fail V2.1 (04/22/2014) - Internal release for SET_LINK_STATUS command V2.0 (10/21/2013) - Added support for multiple adapters V1.7 (09/27/2013) - The -s 0 can be specified not to update serial number. V1.6 (09/25/2013) - The utility can take any string for serial number feild. V1.5 (08/30/2012) - Added -x option to print Tx and Rx statistics. V1.4 (04/16/2012) - Added remind user to run as Administrator while using this utility. V1.3 (04/02/2012) - Fixed bug for program LAN9514 Eeprom V1.2 (03/20/2012) - Added different error code return when fail to run the application v1.1 (06/24/2011) - Added External loop back test v1.0 (04/26/2011) - Initial version 11. Known Issues =============== None at this time.