Ethernet for Murata Modules

Ethernet support can be useful where a reliable Wi-Fi network is not available or not convenient. With Ethernet, the IP address is obtained via DHCP, and the link speed and duplex are configured automatically, so there’s no user setup needed. In terms of operation, only one network interface is used at a time by the Ayla module. If Ethernet support is provided, enabled, and correctly configured, the Wi-Fi interface will be disabled whenever a link is detected on the Ethernet interface. This is true even if there is no DHCP-provided IP address on the Ethernet interface.

Ethernet Chip Signals

The ASIX AX88796 chip is driven via SPI (Serial Peripheral Interface) from the Ayla Production Agent Module. The module is the master on this SPI bus. The Ethernet SPI bus is separate from the SPI bus used from the host MCU to connect to the module. The signals needed are:

  • Four SPI signals: SCK, MOSI, MISO, and NSS.
  • An interrupt request (IRQ) from the ASIX chip.
  • A reset to the ASIX chip.

The ASIX reset is connected to the module’s reset pin. This signal is open-drain and driven by a host MCU GPIO to reset the module and the ASIX chip, but also driven low by the module for at least 10 microseconds when it reboots itself. This way the Ethernet device and module are reset together. Do not tie this directly to the host MCU reset signal.

NOTE: For descriptions on the other connections to the ASIX chip, refer to the appropriate documentation from ASIX.

The following describes the Type-1LD module and Type-YD module connections.

Type-1LD Module

The Type-1LD module uses an SPI bus to connect to the Ethernet chip. This is separate from the SPI bus that might be used by the host MCU. This support requires the Ayla Production Agent version 2.10 or later. The host MCU may use either SPI or UART to connect to the module.

The following table provides the Type-1LD module signals for Ethernet. By default, none of the module GPIOs listed in the table below are used for other purposes, so be sure not to configure them. They should be shown as "not used" or "in use (eth)" by the "gpio" CLI command, which shows the status of various configurable I/Os.

Signal NameModule GPIO PinModule Pin NameModule PinDaughtercard Hirose Connector PinAX88796C PinASIX SMDK2440 V1.0 Demo board Pin
RESET_NsssnRESET321817J11-30
IRQPB4PB4/JTRST193923J11-18
MOSIPB15PB15/SPI2_MOSI28142J13-2
MISOPB14PB14/SPI2_MISO29341J13-3
SCKPB13PB13/SPI2_SCK30456J12-34
NSSPB12PB12/SPI2_NSS31252J11-2

Type-YD Module

The Type-YD module uses a SPI bus to connect to the Ethernet chip. This is separate from the SPI bus that might be used by the host MCU. This support requires production agent version 1.9.6 or later. The host MCU must use SPI to connect to the module, because Ethernet uses PA2 and PA3, which would be needed to connect the host MCU via UART.

The following table provides the Type-YD module signals for Ethernet. By default, none of the module GPIOs listed in the table below are used for other purposes, so be sure not to configure them. They should be shown as "not used" or "in use (eth)" by the "gpio" CLI command, which shows the status of various configurable I/Os.

Signal NameModule GPIO PinModule Pin NameModule PinDaughtercard Hirose Connector PinAX88796C PinASIX SMDK2440 V1.0 Demo board Pin
RSTNsssNRST2217J11-30
IRQPA3PA3/UART2_RX433723J11-18
MOSIPB15USBDP33842J13-2
MISOPB14USBDM34741J13-3
SCKPB13USB_DET32956J12-34
NSSPA2PA2/UART2_TX423652J11-2

Ethernet Configuration

Configuration of the Ethernet support is normally done using the ayla_config script from the Ayla OEM package. The script must be modified to configure the Ethernet MAC address, which must be unique for each module. The "eth" CLI command is used to show the Ethernet status or change its configuration. With no arguments, this CLI command shows the current configuration and usage:

setup-> eth
eth enabled
eth ip: 172.16.24.108
eth mac_addr: 12:34:56:78:9a:bc
eth spi_speed: 0

usage:
eth [enable|disable]
eth mac_addr <mac>
eth spi_speed [0..8]

The Ethernet MAC address must be configured; following is an example:

setup-> eth mac_addr 12:34:56:78:9a:bc
save+rst required
setup->

The message "save+rst required" is a reminder that the configuration has not been saved and will not be effective until the module reboots. You can continue with other configuration actions first, but when ready, type "save" and "reset". Note that to affect the factory configuration and to be effective after factory reset, Ethernet should be configured as desired while the module is in setup mode.

The other required action is to enable the interface, as shown below:

setup-> eth enable
save+rst required

The "eth spi_speed" sub-command is not needed. Leave it set to 0 (the default).