FlexCase E/G

MCU Ethernet Guide

Specifications

Features Specification
Maximum Voltage 4.6 V
Signal Conditioning and Protection ESD Protection > +/-8 KV according to IEC 61000-4-2, Voltage Filtering, Polarity Detection and Correction
Differential Impedance 100 Ohm

 

Connection Setup

  • Connect twisted pair wires to MCU ETH+, MCU ETH- pins (see model-specific datasheet for pin IDs)
  • Connect wires to 100BASE-TX – 100BASE-T1 media converter (example), and connect RJ45 cable from converter to PC or network switch. NOTE: Media converter must be in slave mode.
  • Identify IP address for Ethernet adapter/switch or set it manually

  • Open the sample model, Ethernet_IMU_k3.slx, in Simulink, or insert the Audesse library block, FLX_Eth_Setup, into your custom model
  • Double click on the FLX_Eth_Setup block and set the PC/switch address, FlexCase address, and UDP port for general Tx/Rx applications.
    • NOTE: FreeMASTER-over-Ethernet uses a separate UDP port – see FreeMASTER guide
    • NOTE: The PC and FlexCase addresses and Gateway must share the same subnet, e.g., 192.168.2.X

  • Click OK to close dialog window, then build and flash the code to your FlexCase
  • In a terminal window on your PC, verify the connection by pinging the FlexCase address:

ping 192.168.2.200

Functional Blocks

The Audesse Simulink library features numerous helper functions for transmitting and receiving MCU data via ethernet. Additionally, the FLX_Eth_Status block provides a number of status variables to diagnose the ethernet connection: IsLinkUp == 1 when a connection has been established with the media converter. State has one of the following values: 0 – Initializing, 1 – PHY released, 2 – GMAC + MDIO, 3 – PHY found, 4 – PHY normal, 5 – lwIP up, 6 – Link up. RxIndications and TxConfirmations count the number of received and transmitted frames, respectively.

Open the sample model, Ethernet_IMU_k3.slx to see the usage of each block, as shown below: