Controlling Ethernet Link Partner GPIOs with OAM
By using Ethernet OAM frames within the PHY layer to control remote GPIO ports, the complexity and latency issues in Ethernet communication systems are addressed, ensuring reliable and efficient control of GPIO ports in applications like automotive and avionics systems.
Patent Information
- Application Number
- JP2020074413
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Priority Date
- 2019-04-19
- Filing Date
- 2020-04-17
- Publication Date
- 2024-11-15
- Estimated Expiration
- 2040-04-17
AI Technical Summary
Existing Ethernet communication systems face challenges in efficiently controlling remote General Purpose Input/Output (GPIO) ports without affecting higher layers, leading to complexity, latency, and reliability issues, especially in applications requiring high data rate communication over short distances.
Implementing Ethernet Operations Administration and Maintenance (OAM) frames within the PHY layer to control remote GPIO ports, enabling direct control and verification without involving upper layers, thus simplifying the process and reducing latency and complexity.
This approach provides a reliable and efficient mechanism for controlling remote GPIO ports, reducing latency and complexity while maintaining high reliability, suitable for applications like automotive and avionics systems.
Smart Images

Figure 0007583980000003 
Figure 0007583980000004 
Figure 0007583980000005
Abstract
Description
[Technical field]
[0001] [CROSS REFERENCE TO RELATED APPLICATIONS] This application claims the benefit of U.S. Provisional Patent Application No. 62 / 836,536, filed April 19, 2019, the disclosure of which is incorporated herein by reference.
[0002] The present disclosure relates generally to Ethernet communications, and more specifically to methods and systems for operating a general purpose input / output (GPIO) interface using management frames, such as Ethernet Operations, Administration and Maintenance (OAM) frames. [Background technology]
[0003] Various applications, such as in-vehicle communication systems for automobiles, certain industrial communication systems, and smart home systems, require high data rate communication over relatively short distances. Several types of protocols and communication media have been proposed for such applications. For example, Ethernet communication over twisted-pair copper media for automotive applications is specified in IEEE Standard 802.3bp®-2016, entitled “IEEE Standard for Ethernet; Amendment 4: Physical Layer Specifications and Management Parameters for 1 Gb / s Operation over a Single Twisted-Pair Copper Cable” of June 2016. This standard is referred to herein as “IEEE 802.3bp” for brevity. Section 97.3.8 of the IEEE 802.3bp standard specifies 1000BASE-T1 Operation, Administration, and Maintenance (OAM).
[0004] The above discussion is provided as a general overview of the related art in this field and should not be construed as an admission that any of the information contained therein constitutes prior art to the present patent application. Summary of the Invention
[0005]
[0005] The embodiments described herein provide an Ethernet physical layer (PHY) device operative to control a remote peer Ethernet PHY device. The Ethernet PHY device includes a PHY interface and a PHY circuit. The PHY interface is configured to connect to a physical link. The PHY circuit is configured to generate a layer 1 frame carrying data for transmission to the peer Ethernet PHY device, insert one or more management frames into the layer 1 frame that are separate from the layer 1 frame and configured to control general purpose input / output (GPIO) ports associated with the peer Ethernet PHY device, transmit the layer 1 frame and the inserted management frame via the PHY interface through the physical link to the peer Ethernet PHY device for controlling operation of one or more of the GPIO ports associated with the peer Ethernet PHY device, and receive one or more verifications via the PHY interface that confirm that the one or more management frames have been successfully received at the peer Ethernet PHY device.
[0006] In some embodiments, the PHY circuitry is configured to insert management frames by inserting one or more Operation, Administration and Maintenance (OAM) frames. In one embodiment, in at least one of the management frames, the PHY circuitry is configured to instruct the peer Ethernet PHY device to set the GPIO port to a particular output logic level. In another embodiment, in at least one of the management frames, the PHY circuitry is configured to instruct the peer Ethernet PHY device to read the input logic level of the GPIO port. In a disclosed embodiment, in at least one of the management frames, the PHY circuitry is configured to instruct the peer Ethernet PHY device to control a microcontroller to perform a safety control operation in the vehicle.
[0007] In some embodiments, the PHY circuitry is configured to receive one or more management frames from a host, while in other embodiments, the PHY circuitry is configured to receive parameters for controlling the GPIO port via a register and to configure the one or more management frames based on the parameters.
[0008] Further provided by the embodiments described herein is an Ethernet physical layer (PHY) device controlled by a remote peer Ethernet PHY device. The Ethernet PHY device includes a PHY interface and a PHY circuit. The PHY interface is configured to connect to a physical link, and the PHY circuit is configured to receive, via the PHY interface, layer 1 frames carrying data transmitted from a peer Ethernet PHY device over the physical link, receive in the layer 1 frames one or more management frames transmitted from the peer PHY device that control a general purpose input / output (GPIO) port associated with the Ethernet PHY device, control the GPIO port according to instructions contained in the one or more management frames, and transmit, via the PHY interface, one or more verifications to the peer Ethernet PHY device confirming successful reception of the one or more management frames.
[0009] In some embodiments, the PHY circuitry is configured to receive management frames, such as receiving one or more Operation, Administration and Maintenance (OAM) frames. In an exemplary embodiment, in response to at least one of the management frames, the PHY circuitry is configured to set the GPIO port to a particular output logic level. In another embodiment, in response to at least one of the management frames, the PHY circuitry is configured to read an input logic level of the GPIO port and report the input logic level of the GPIO to a peer Ethernet PHY device. In some embodiments, in response to at least one of the management frames, the PHY circuitry is configured to control a microcontroller to perform a safety control operation in the vehicle.
[0010] An Ethernet communication system is further provided according to the embodiments described herein, including a microcontroller, a first Ethernet PHY device, and a second Ethernet PHY device. The first Ethernet PHY device is connected to the microcontroller by a general purpose input / output (GPIO) port. The second Ethernet PHY device is connected to the first Ethernet PHY device via a physical link. The second Ethernet PHY device is configured to exchange layer 1 frames with the first Ethernet PHY device carrying data, transmit one or more management frames in the layer 1 frames to the first Ethernet PHY device via the GPIO port of the first Ethernet PHY device, the management frames being separate from the layer 1 frames and configured to control the microcontroller, and receive one or more verifications from the first Ethernet PHY device via the PHY interface that confirm that the one or more management frames have been successfully received at the first Ethernet PHY device.
[0011] In one embodiment, in at least one of the management frames, the second Ethernet PHY device is configured to initiate a safety control operation in the vehicle, and the first Ethernet PHY device is configured to control a microcontroller via a GPIO port to perform the safety control operation, the microcontroller being configured to perform the safety control operation in response to controlling the GPIO port.
[0012] In another embodiment, in response to at least one of the management frames, the first Ethernet PHY device is configured to reset the microcontroller via the GPIO port. In yet another embodiment, in response to at least one of the management frames, the first Ethernet PHY device is configured to read a status of the microcontroller via the GPIO port. In yet another embodiment, the first Ethernet PHY device is configured to control the GPIO port regardless of whether the microcontroller is functioning normally or malfunctioning.
[0013] Also provided by the embodiments described herein is a method for controlling a remote peer Ethernet physical layer (PHY) device. The method includes generating a layer 1 frame at an Ethernet PHY device that connects to the peer Ethernet PHY device over a physical link, the layer 1 frame carrying data for transmission to the peer Ethernet PHY device. One or more management frames are inserted into the layer 1 frame at the Ethernet PHY device. The one or more management frames are separate from the layer 1 frame and configured to control a general purpose input / output (GPIO) port associated with the peer Ethernet PHY device. The layer 1 frame and the inserted management frame are transmitted over the physical link from the Ethernet PHY device to the peer Ethernet PHY device to control one or more operations of the GPIO port associated with the peer Ethernet PHY device. One or more verifications are received at the Ethernet PHY device from the peer Ethernet PHY device confirming that the one or more management frames were successfully received at the peer Ethernet PHY device.
[0014] Further provided by embodiments described herein is a method for controlling a general purpose input / output (GPIO) port associated with an Ethernet physical layer (PHY) device. The method includes receiving at an Ethernet PHY device a layer 1 frame carrying data transmitted from a peer Ethernet PHY device over a physical link. One or more management frames transmitted from the peer PHY device to control a GPIO port associated with the Ethernet PHY device are received within the layer 1 frame. The GPIO port associated with the Ethernet PHY device is controlled according to instructions contained in the one or more management frames. One or more verifications confirming successful reception of the one or more management frames are transmitted from the Ethernet PHY device to the peer Ethernet PHY device.
[0015] The present disclosure will be more fully understood from the following detailed description of the embodiments thereof when taken in conjunction with the drawings, in which: [Brief description of the drawings]
[0016] [Figure 1] FIG. 1 is a block diagram that generally illustrates an automotive communication system in accordance with embodiments described herein.
[0017] [Diagram 2] 2 is a block diagram that generally illustrates an Ethernet physical layer (PHY) device in the system of FIG. 1, in accordance with embodiments described herein.
[0018] [Diagram 3] FIG. 2 illustrates an Ethernet Operation, Administration and Maintenance (OAM) frame carrying a GPIO command, according to embodiments described herein.
[0019] [Figure 4]1 is a flow chart that generally illustrates a method for controlling a general purpose input / output (GPIO) port in a peer Ethernet PHY device, according to embodiments described herein.
[0020] [Diagram 5] 1 is a block diagram that generally illustrates an avionics communication system in accordance with embodiments described herein.
[0021] [Figure 6] 2 is a block diagram that generally illustrates a communication system according to another embodiment described herein. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0022] The embodiments described herein provide improved Ethernet communication methods and systems in which an Ethernet PHY device controls GPIO ports at a peer Ethernet PHY device via an exchange of management frames, such as, for example, Operation, Administration and Maintenance (OAM) frames.
[0023] In some embodiments, an Ethernet PHY device communicates with a peer PHY device over a physical link, such as a twisted pair link. The PHY device is configured, among other functions, to generate Layer 1 frames that encode Layer 2 Ethernet frames in a manner suitable for transmission over the physical link (physical medium) to the peer PHY device. The peer PHY device (also referred to as a "link partner") is associated with a general purpose input / output (GPIO) port (e.g., has an integrated GPIO port or is locally connected to a host that has a GPIO port). Encoding Layer 2 frames to generate a stream of Layer 1 frames is typically not a one-to-one translation process. The encoding process is typically performed according to an appropriate algorithm specified for the applicable link layer technology.
[0024] In assembling a stream of Layer 1 frames, the PHY device is configured to encode, within a Layer 2 Ethernet frame, one or more Ethernet OAM frames configured to control a GPIO port associated with a peer PHY device (sometimes referred to as a link partner). The PHY device is configured to transmit the Layer 1 frame, comprising the Layer 2 frame and the OAM frame, over a physical link to the peer PHY device.
[0025] For example, as specified in the above-referenced IEEE 802.3bp standard, Ethernet OAM supports a built-in confirmation mechanism using OAM frames in the opposite direction. In some embodiments, a PHY device is configured to receive one or more OAM verifications from a peer Ethernet PHY device that confirm that one or more OAM frames were successfully received at the peer PHY device. In this way, a highly reliable mechanism for controlling remote GPIO ports is implemented entirely within the PHY link layer, i.e., within OSI layer-1.
[0026] In principle, it is possible to control remote GPIO ports using conventional Ethernet frames dedicated to GPIO control. This solution, however, impacts the Media Access Control (MAC) layer and possibly higher layers, making it complex to implement and incurring large delays. On the other hand, the disclosed technique is implemented entirely within the PHY device without involving higher layers, making it simpler to implement and incurring minimal latency overhead.
[0027] Furthermore, using dedicated Ethernet frames to control remote GPIO ports typically requires the use of additional microcontrollers and software stacks, and additional scheduling and interleaving of such Ethernet frames, among other data frames. This additional complexity results in reduced reliability and risk of missed delivery. Furthermore, the disclosed technology provides a suitable replacement for Controller Area Networks (CAN), which are used in some conventional automotive networks as a redundant communication means for safety messages between electronic control units (ECUs). As described and exemplified below, the reliability of the disclosed technology is not dependent on other systems or controllers. In some exemplary implementations, the disclosed solution is entirely self-contained in a single integrated circuit (IC).
[0028] Some embodiments disclosed herein are described in the context of an automotive application, e.g., a system in which various automotive peripherals communicate with an electronic control unit (ECU) and the ECUs communicate with each other. Other exemplary embodiments are described in the context of an avionics communication system. Some use cases relate to safety control functions of the automotive communication system and the avionics communication system. However, these embodiments and use cases are provided as examples only. The disclosed techniques are similarly applicable in other applications, such as, for example, industrial and / or smart home networks.
[0029] For clarity, the embodiments described herein refer primarily to Ethernet OAM frames, however, in general the disclosed techniques are not limited to OAM frames and may be implemented using any suitable type of management frame.
[0030] In some embodiments, the OAM frames are configured by a host connected to the PHY device. In these embodiments, the PHY device receives the OAM frames from the host and encodes the OAM frames as part of a stream of Layer 1 frames. In alternative embodiments, the OAM frames are configured internally to the PHY device. In an exemplary embodiment, the PHY device receives parameters for controlling a remote GPIO, e.g., via a register, and configures the OAM frames based on the received parameters.
[0031] 1 is a block diagram that illustrates a schematic of an automotive communication system 20 according to an embodiment described herein. The system 20 is typically installed in a vehicle, such as a passenger car. The system 20 includes one or more automotive electronic control units (ECUs) 24 and a main automotive ECU 28 that control multiple automotive peripherals 32 using Ethernet communication.
[0032] As described in more detail below, among other tasks, ECU 24 and main ECU 28 verify the safety status of various system components by transmitting safety status messages embedded in Ethernet OAM frames and controlling remote GPIO ports based on the embedded safety status messages. In this example, system 20 operates in accordance with the above-mentioned IEEE 802.3bp standard. However, alternatively, any other suitable Ethernet standard or other suitable network communication protocol may be used. The disclosed techniques may be used to modify any suitable physical layer to carry additional information for purposes of control of remote GPIOs.
[0033] In various embodiments, the automotive peripherals 32 may include, for example, lidar, radar, cameras, stereo amplifiers, telematics radios, body ECUs, powertrains, and / or any other suitable type of peripherals. For communication and control purposes, each of the peripherals 32 includes a host controller, also referred to as a system on chip (SoC) 36, and a PHY device 40. Each peripheral 32 is connected to one of the ECUs 24 by a respective physical layer.
[0034] Each ECU 24 includes a number of PHY devices 44 that communicate with peripherals 32. Each PHY device 44 includes a physical coding sublayer (PCS) circuit 48 that performs the PHY device's PCS functions and a physical medium attachment sublayer (PMA) circuit 52 that performs the PHY device's PMA functions.
[0035] In one embodiment, each ECU 24 further includes an automotive Ethernet network switch 56 that connects the peripherals 32 to the main ECU 28. The switch 56 includes a number of ports 57. Each PHY device 48 is connected to a respective port 57 of the switch 56. Each ECU 24 further includes a safety microcontroller (μC) 68 that verifies a safety status of the ECU 24 and / or of the associated peripherals 32 and sends corresponding safety messages to the main ECU 28. The safety μC 68 includes a status output circuit 72 that outputs safety status messages as one or more logic signals (illustrated as “STATUS”).
[0036] In this example, each ECU 24 comprises a PHY device 58 responsible for communicating with the main ECU 28. The PHY device 58 is connected to one of the ports 57 of the switch 56 and to a physical link 62 connecting the ECU 24 with the main ECU 28. In this example, the link 62 comprises a twisted pair link conforming to IEEE 802.3bp.
[0037] As part of its communication with the main ECU 28, the PHY device 58 transmits conventional Layer 2 Ethernet frames and also transmits safety status messages generated by the safety μC 68 embedded in Ethernet OAM frames. Typically, the PHY device 58 combines the Layer 2 Ethernet frames and the OAM frames in accordance with an applicable link layer algorithm to form a Layer 1 frame for transmission over the physical medium. In the case of IEEE 802.3bp, the physical medium comprises an unshielded twisted pair (UTP).
[0038] The PHY device 58 of the ECU 24 includes the PCS circuit 48, the PMA circuit 60, and a GPIO control circuit 64. The GPIO control circuit 64 receives logic signal(s) conveying safety status messages from the safety μC 68 using respective GPIO input port(s). The PHY device 58 embeds the safety status messages into Ethernet OAM frames and inserts the OAM frames into the stream of Ethernet Layer 1 frames transmitted to the main ECU 28 over link 62. This functionality and internal structure of the PHY device 58 is described in more detail below in FIG. 2.
[0039] The main ECU 28 includes a network switch 56, a number of PHY devices 58 connected to ports 57 of the network switch 56, and a main safety μC 76. Each PHY device 58 is connected to a respective ECU 24 through a respective physical layer 62.
[0040] In each PHY device 58 of the main ECU 28, the PMA circuit 60 and the PCS circuit 48 carry conventional Ethernet traffic between the ECU 24 and the switch 56 of the main ECU 28. Additionally, in each PHY device 58 of the main ECU 28, the PCS circuit 48 extracts OAM frames from the stream of layer 1 frames received from the ECU 24, extracts safety status messages from the OAM frames, and sends the safety status messages to the GPIO control circuit 64. The GPIO control circuit 64 sets one or more GPIO outputs according to the safety status messages. The main safety μC 76 includes a status input circuit 80 that receives the GPIO outputs from the PHY devices 58. The main safety μC 76 may initiate any appropriate safety-related action in response to the safety status messages received from the various safety μCs 68 of the ECUs 24.
[0041] 2 is a block diagram that generally illustrates an internal structure of an Ethernet PHY device 58 of system 20 in accordance with an embodiment described herein. Typically, PHY devices 58 in ECU 24 and main ECU 28 have similar internal structures. In this example, PCS circuitry 48 includes PCS transmit (TX) circuitry 100, PCS receive (RX) circuitry 104, and PCS OAM circuitry 108.
[0042] PCS TX circuit 100 receives Ethernet Layer 2 frames for transmission (e.g., from switch 56), encodes them to generate a stream of Layer 1 frames, and provides the Layer 1 frames to PMA circuit 60. PMA circuit 60, also referred to herein as a PHY interface, transmits the Layer 1 frames over physical link 62. In the opposite direction, PMA circuit 60 receives Layer 1 frames over physical link 62 and provides them to PCS RX circuit 104. PCS RX circuit 104 decodes the Layer 1 frames to generate Layer 2 frames and outputs the Layer 2 frames (e.g., to switch 56).
[0043] In some embodiments, the PHY device 58 further includes a PHY controller 112, a link monitor 116, and a GPIO control circuit 64. The PHY controller 112 is connected to the switch 56 (e.g., to a media access control (MAC) device of the switch 56) through a serial management interface (SMI) for receiving control and configuration commands from the switch, for example. The switch 56 may initialize and monitor the PHY device 58 via the SMI, for example. The link monitor 116 is configured to monitor communication quality through the physical link 62.
[0044] Also, in some embodiments, the PHY controller 112 is responsible for sending and receiving safety status messages. When the PHY device 58 operates with one of the ECUs 24, the PHY controller 112 receives (from the safety μC 68 via the GPIO control circuitry 64) a logic value indicating a safety status message to be reported to the main ECU 28. The PHY controller 112 transmits the logic value to the PCS OAM circuitry 108. The PCS OAM circuitry 108 constructs one or more OAM frames carrying the safety status messages and includes the OAM frames in a stream of Layer 1 frames generated by the PCS TX circuitry 100. The Layer 1 frames encoded from the Layer 2 Ethernet frames and the OAM frames are transmitted by the PMA circuitry 60 over the link 62.
[0045] When the PHY device 58 operates in the main ECU 28, the PMA circuit 60 receives a stream of Layer 1 frames over link 62 from one of the ECUs 24, the Layer 1 frames encoding Layer 2 Ethernet frames and one or more OAM frames carrying safety status messages. The PMA circuit 60 provides the stream of Layer 1 frames to the PCS RX circuit 104. The PCS OAM circuit 108 extracts the OAM frames from the stream, extracts the safety status messages from the OAM frames, and sends corresponding logic values to the PHY controller 112. The PHY controller 112 sends the logic values to the GPIO control circuit 64, which then sets the appropriate GPIO output. The GPIO output is thus provided as an input to a status input circuit 80 of the main safety μC 76.
[0046] In the embodiment described herein, the logic values (exchanged between the safety μC 68 and the main safety μC 76 to indicate safety status messages) are static discrete logic values. However, the disclosed technology is not limited to this type of implementation. In alternative embodiments, any logic value may change over time, for example to form a temporal pattern of logic values that convey multiple bits of information. By varying the logic value at a particular GPIO port (pin) over time, it is possible to implement a serial data link that transmits data between PHY devices according to any suitable protocol. By varying multiple logic values that each correspond to multiple GPIO ports (pins), the disclosed technology may be used to implement a parallel data link between PHY devices. Additionally or alternatively, the logic values need not necessarily be discrete digital values, but may have analog waveforms that convey information in any suitable manner.
[0047] In the present context, the PCS circuitry 48 (including the PCS TX circuitry 100, the PCS RX circuitry 104 and the PCS OAM circuitry 108), the PHY controller 112, the GPIO control circuitry 64 and the link monitor 116 are collectively referred to as the “PHY circuitry.” In alternative embodiments, the PHY circuitry may be implemented in any other suitable manner.
[0048] FIG. 3 is a diagram illustrating an OAM frame carrying a GPIO command, e.g., a safety status message, in accordance with an embodiment described herein. In one embodiment, a PHY device (e.g., PHY device 58 in FIGS. 1 and 2) uses this type of OAM frame to control a remote GPIO port of a link partner (e.g., remote PHY device 58). The structure of the example OAM frame of FIG. 3 complies with section 97.3.8 of the above-mentioned IEEE 802.3bp standard. However, the disclosed technology is not limited to any particular format, or any other suitable format. Furthermore, as noted above, the disclosed technology may be implemented using other suitable types of management frames, not necessarily OAM frames.
[0049] As shown in the figure, the OAM frame comprises 12 symbols (denoted Symbol_0 to Symbol_11), each of which contains 9 bits (denoted D0 to D8). Symbol_0, bits D4 to D7 of Symbol_1, Symbol_10, and Symbol_11, and bit D8 of each symbol are defined as per IEEE 802.3bp.
[0050] In some embodiments, the "message number" field 120, occupying bits D0 through D3 of Symbol_1, is set to a 4-bit value dedicated to GPIO message indication. In various embodiments, any or all of symbol_2 through Symbol_10 can be space 124 for the actual GPIO command or commands. In one embodiment, each symbol is used to specify a GPIO command for a respective different GPIO port (input or output) of the remote PHY device.
[0051] In one embodiment, the "Message Number" field 120 in Symbol_1 of the OAM frame is set to 4b'1111, although any other suitable value may be used. The GPIO command is embedded in Symbol_8 and Symbol_9 of the OAM frame as follows: [Table 1]
[0052] As shown, Symbol_9 is set to 0x01 to indicate that the OAM frame carries a remote GPIO command. The GPIO command in Symbol_8 contains the following fields: GPIO command code (0x00 indicates a GPIO read request, 0x01 indicates a GPIO write request, 0x02 indicates a GPIO read response, i.e., confirmation, 0x03 indicates a reserved value) GPIO direction bit ("1" = output, "0" = input) GPIO value ("1" = high, "0" = low)
[0053] Alternatively, any other suitable format and / or any other suitable numeric values may be used to embed the GPIO commands in the OAM frame.
[0054] In one embodiment, if the disclosed remote GPIO function is enabled on both link partners (PHY devices), the function begins working upon link up. During operation, the pin status and value of each GPIO port (pin) is typically reflected in both the GPIO control circuit 64 (of the remote PHY device) and in the remote GPIO register. In one embodiment, following the example of Table 1 above, the GPIO register of the remote PHY device has the following format: [Table 2]
[0055] In this example, the GPIO register bits are defined as follows: Bit <15> :Enable remote GPIO control function Bit<14:8>: Reserved, set to all 0 Bit <7> :1 to perform a GPIO read / write. If bit 6 (defined below) indicates a GPIO write, the PHY device automatically sends a "GPIO write request" to the link partner with the GPIO direction and value in bits <5:0>. If bit 6 indicates a GPIO read, the PHY device automatically sends a "GPIO read request" and updates bits <5:0> with the received GPIO direction and value in the next received "GPIO read response" OAM frame. This bit is automatically cleared when the GPIO write is acknowledged by the link partner or when a GPIO read response is received to the GPIO read request. Bit <6> :0=read, 1=write ·Bit<5:3>:GPIO direction<2:0> Bit<2:0>: GPIO value<2:0>
[0056] In one embodiment, the update rate of the GPIO information is set to match the OAM period (3.6 μs x 12 = 43.2 μs). If the disclosed remote GPIO feature is enabled, upon receiving a new OAM frame carrying a GPIO command, the remote PHY device interprets the "GPIO command" field to determine the appropriate action.
[0057] If the GPIO command is a "GPIO write request", the remote PHY device updates its local GPIO registers and GPIO pins according to the direction and values indicated in the OAM frame and marks the OAM frame as a read. Upon processing the GPIO command, the mr_rx_lp_valid state variable (specified in IEEE 802.3bp) is cleared to "0" to indicate that the PHY device is ready for the next OAM frame.
[0058] If the GPIO command is a "GPIO Read Request", the remote PHY device sends a "Remote GPIO OAM" frame back to the requesting PHY device, where the GPIO command is set to "GPIO Read Response" and the "GPIO Direction" and "GPIO Value" fields reflect the current status of the local GPIO register. Upon processing the GPIO command, mr_rx_lp_valid is cleared to "0" to indicate the PHY device is ready for the next OAM frame.
[0059] If the GPIO command is a "GPIO read response", the receiving PHY device stores the received remote GPIO direction and value in its own remote GPIO register. Upon processing the command, if the read request originates from the remote GPIO register, mr_rx_lp_valid is cleared to "0" and prepared for the next OAM frame. Otherwise, mr_rx_lp_valid is kept at "1" so that the management entity can process it through the OAM message register.
[0060] In some practical scenarios, it may occur that an existing OAM frame is in progress (i.e., transmitted but not yet acknowledged) while another user OAM frame is waiting to be transmitted. In such a case, the PHY device will typically transmit the remote GPIO OAM frame just after the existing OAM transmission has been acknowledged, but before the next user OAM message is transmitted. The management entity will typically detect and handle scenarios where an OAM frame cannot be transmitted for an extended period of time because the link partner's management entity is not processing OAM, similar to normal OAM operation.
[0061] In one embodiment, for example, when using "open drain" mirroring, a single GPIO port (pin) can be used for bidirectional signaling, i.e., as both an input and an output. This type of implementation is useful, for example, for transmitting a two-wire serial interface bidirectionally to initialize, monitor, or manage a remote system. In an exemplary embodiment, after initialization or other management tasks are completed, a mode switch can be performed to use the GPIO pin as a unidirectional pin.
[0062] 4 is a flow chart that generally illustrates a method carried by an Ethernet PHY device 58 for controlling a GPIO port in a peer Ethernet PHY device 58, according to an embodiment described herein. The method begins with a host in the PHY device (e.g., a MAC device of network switch 56) composing an OAM frame incorporating a GPIO command in an OAM frame composition operation 130. The host writes the OAM frame to an OAM register in the host. In a write operation 134, the host writes the OAM frame from the OAM register to the PHY device through an SMI.
[0063] In an insert operation 138, the PHY controller 112 and PCS OAM circuitry 108 of the PHY device include the OAM frame in the stream of Layer 1 frames that the PCS TX circuitry 100 generates from the Layer 2 Ethernet frames, e.g., between two consecutive Layer 2 Ethernet frames. In a transmit operation 142, the PMA circuitry 60 of the PHY device transmits the Layer 1 frame to the peer PHY device using a medium dependent interface (MDI), e.g., over link 62. The Layer 1 frame carries the Layer 2 Ethernet frame and the OAM frame.
[0064] At the peer PHY device, in receive and extract operation 146, PMA circuitry 60 receives the stream of layer 1 frames and PCS OAM circuitry 108 extracts the OAM frames from the stream. In GPIO command process operation 150, PHY controller 112 identifies the OAM frame as carrying a GPIO command and controls GPIO control circuitry 64 accordingly. For example, if the GPIO command is a write command, PHY controller 112 writes the value specified in the command to the GPIO port specified in the command. If the GPIO command is a read command, PHY controller 112 reads the value from the GPIO port specified in the command.
[0065] The PHY controller 112 of the peer PHY device constructs and returns an acknowledge message to the PHY device initiating the GPIO command in an acknowledge operation 154. The acknowledge message is itself an OAM frame sent in the opposite direction, as specified in IEEE 802.3bp section 97.3.8.2.8.
[0066] The method of FIG. 4 is an exemplary method and is shown merely for clarity. In alternative embodiments, the PHY device and the peer PHY device may use any other suitable flow of operations to perform the disclosed techniques. For example, in an alternative embodiment, the PHY device, rather than the host, constructs the OAM frame that carries the GPIO command. In this embodiment, the host typically sends the command parameters (e.g., command code, GPIO port number, and value to be written in the case of a write command), and the PHY controller 112 constructs the OAM frame using these parameters.
[0067] In various embodiments, the PHY device may apply any suitable operation using the disclosed techniques using a GPIO port or a port of a remote PHY device. In one exemplary embodiment, the GPIO port of the remote PHY device is connected to a reset pin of a remote host, and the PHY device uses the disclosed techniques to remotely reset the remote host through a physical Ethernet link. In another exemplary embodiment, the "status output" port of the remote host is connected to a GPIO port of the remote PHY device, and the PHY device uses the disclosed techniques to remotely query the status of the remote host through a physical Ethernet link. In one embodiment, the "status output" ports of two or more remote hosts are combined using appropriate logic (e.g., an OR or NOR gate), and the output of the logic is connected to a GPIO port of the remote PHY device. In this way, the PHY device is able to query the combined status of multiple remote hosts (e.g., whether any of the hosts have failed) using a single GPIO port.
[0068] The above discussion illustrates a use case example of the disclosed remote GPIO control technique for the exchange of safety status messages between safety microcontrollers in an automotive communication system. The following discussion provides two additional use cases, one related to simplifying software validation in avionics systems and the other related to transparent GPIO-based communication between controllers.
[0069] 5 is a block diagram that generally illustrates an avionics communication system according to an embodiment described herein. In the system of FIG. 5, a main system microcontroller (μC) 160 is coupled to an Ethernet PHY device 168, and a remote μC 164 is coupled to an Ethernet PHY device 172. The PHY devices 168 and 172 are link partners and communicate with each other using an MDI over an appropriate physical layer, such as a twisted pair link. For data transmission, the main μC 160 transmits data in a layer 2 frame to the PHY device 168 via a MAC interface, the PHY device 168 transmits data in a layer 1 frame to the PHY device 172 using the MDI, and the PHY device 172 transmits data to the remote μC 164 in a layer 2 frame via the MAC interface.
[0070] In addition to transmitting data between μCs 160 and 164, in this example, safety messages must also be transmitted over the same physical layer link (MDI). Reusing the same physical layer link for traveling safety messages is useful, for example, to reduce the number of wires and simplify the wiring process.
[0071] In one exemplary use case, a safety state having four possible values (designated State_0 through State_3) is transmitted to the aircraft entertainment system, for example to pause the entertainment system during a public announcement (PA). To simplify software validation, it is desirable for the safety message to be transmitted independently from the main μC 160 and the remote μC 164.
[0072] 5 embodiment, safety messages (safe state values) are transmitted independently from the rest of the system using safety control μC 176, 4-to-2 encoder 180, and 2-to-4 decoder 184. Additionally, PHY device 168 has two GPIO input ports, denoted GPIO1 and GPIO2, and PHY device 172 has two GPIO output ports, denoted GPIO1 and GPIO2. The two PHY devices are configured to transmit input values of GPIO1 and GPIO2 of PHY device 168 to PHY device 172 and to set outputs of GPIO1 and GPIO2 of PHY device 172 to these values. The PHY devices transmit the two GPIO values by incorporating them as GPIO commands in an OAM frame, as described above.
[0073] In this example, the safe state values are provided through four inputs (on the left side of the diagram) corresponding to State_0 to State_3. A single one of these inputs is set to "1" to indicate the current safe state, and the other inputs are set to "0". 4-to-2 encoder 180 converts the four inputs into a 2-bit value and provides the 2 bits as inputs to ports GPIO1 and GPIO2 of PHY device 168. PHY device 168 transmits the values of GPIO1 and GPIO2 to its link partner (also referred to as peer PHY device) PHY device 172 using the disclosed techniques. PHY device 172 sets its GPIO1 and GPIO2 outputs to these values. 2-to-4 decoder 184 decodes the 2-bit values carried by GPIO1 and GPIO2, thereby reconstructing and outputting (on the right side of the diagram) the four original values State_0 to State_3.
[0074] In this embodiment, the transmission of secure messages is managed by the secure control μC 176, independent of other microcontrollers in the system. In this example, the serial management interface (SMI) between the main system μC 160 and the PHY device 168 passes through the secure control μC 176. This setting is useful, for example, to ensure that the secure aspects of the system cannot be reconfigured later by the main μC 160 (e.g., by malware that has compromised the main μC). However, passing the SMI through the secure control μC 176 is not required.
[0075] During normal operation, safety control μC 176 allows SMI traffic to pass transparently between main system μC 160 and PHY device 168. To transmit safety messages, safety control μC 176 overrides SMI, i.e., prevents main system μC 160 SMI traffic from being sent to PHY device 168, and controls PHY device 168 itself. Safety control μC 176 also typically initializes PHY devices 168 and 172 upon power-up.
[0076] Typically, the safety control μC 176 is small and executes only a small amount of simple software code. Because of this, and because the safety control μC 176 is separate from the μCs 160 and 164, validation of the safety-related software is greatly simplified. For example, if the software of the μCs 160 or 164 is updated, there is no need to revalidate the safety-related software.
[0077] FIG. 6 is a block diagram that generally illustrates a communication system in accordance with another embodiment described herein. The embodiment of FIG. 6 illustrates a configuration in which the GPIO port is part of the host rather than part of the PHY device. In the context of this disclosure and in the claims, the GPIO port is referred to in association with the PHY device. The term "associated" refers to implementations in which the GPIO port is part of the PHY device (as in the examples of FIG. 1, FIG. 2, and FIG. 5) and implementations in which the GPIO port is part of the host that is coupled to the PHY device (as in the example of FIG. 6).
[0078] 6, main system μC 160 is coupled to Ethernet PHY device 188, and remote μC 164 is coupled to Ethernet PHY device 192. PHY devices 188 and 192 are link partners and communicate with each other using the MDI over an appropriate physical layer, such as a twisted pair link. For data transmission from main μC 160 to remote μC 164, main μC 160 transmits data in layer 2 frames to PHY device 188 via the MAC interface, PHY device 188 transmits data in layer 1 frames to PHY device 192 using the MDI, and PHY device 192 transmits data to remote μC 164 in layer 2 frames via the MAC interface.
[0079] 6 includes a pair of auxiliary μCs 196 and 200 that communicate with each other over the same MDI using the same pair of PHY devices 188 and 192. In this example, μC 196 sends three binary values, indicated by GPIO1, GPIO2, and GPIO3, to μC 200. The communication between auxiliary μCs 196 and 200 is independent of the communication between μCs 160 and 164.
[0080] Unlike the previously described embodiments, in this example the GPIO inputs and outputs are part of the host (the auxiliary μC in this example) rather than part of the PHY device.
[0081] In this embodiment, the SMI interface between the main system μC 160 and the PHY device 188 passes through the auxiliary μC 196. Similarly, the SMI interface between the remote system μC 164 and the PHY device 192 passes through the auxiliary μC 200. During communication between the main system μC 160 and the remote system μC 164, the auxiliary μC 196 allows SMI traffic to pass transparently between the main system μC 160 and the PHY device 188, and the auxiliary μC 200 allows SMI traffic to pass transparently between the remote system μC 164 and the PHY device 192.
[0082] In order for the auxiliary μCs 196 and 200 to communicate with each other, each of the auxiliary μCs 196 and 200 overrides its respective SMI and controls its respective PHY device itself. Overriding the SMI allows the auxiliary μCs 196 and 200 to control registers in the PHY devices 188 and 192 that are used to insert or read OAM frames. Additionally, overriding the SMI allows the auxiliary μCs 196 and 200 to prevent the main μC 160 and the remote μC 164 from interrupting the communication channel between the auxiliary μCs (e.g., as a result of malware).
[0083] 6 embodiment, auxiliary μC 196 transmits the values of GPIO1, GPIO2, and GPIO3 to auxiliary μC 200 by constructing an OAM frame that carries these values as a GPIO command, and writes the OAM frame to PHY device 188. PHY device 188 transmits the OAM frame as part of a stream of layer 1 frames to PHY device 192 using the disclosed techniques. PHY device 192 extracts the OAM frame from the stream and writes it to auxiliary μC 200, which then configures its GPIO1, GPIO2, and GPIO3 outputs accordingly.
[0084] The configurations of the communication systems shown in Figures 1, 5, and 6, their components such as the Ethernet PHY device shown in Figure 2, and the various ECUs and microcontrollers are merely example configurations shown for clarity, in alternative embodiments any other suitable configurations may be used.
[0085] For example, as described above, the logic values (transmitted between PHY devices to control the GPIO ports) may be discrete or analog, static or varying over time. The logic values may form a temporal pattern that conveys multiple bits of information. By varying one or more logic values over time, the disclosed techniques may be used to implement serial or parallel data links between PHY devices. As another example, the GPIO ports may be used for bidirectional signaling or communication, e.g., using an open-drain configuration. Any combination of such functions may be used, and any function may be reconfigured at any desired time. In an exemplary embodiment, the disclosed techniques are used to implement a protocol interface between PHY devices. Such an interface may be used, for example, to remotely configure the PHY devices. Elements not essential to an understanding of the disclosed techniques have been omitted from the drawings for clarity.
[0086] Different elements of the disclosed communications system, and components thereof, may be implemented using dedicated hardware or firmware, for example, using hardwired or programmable logic in one or more application specific integrated circuits (ASICs) or field programmable gate arrays (FPGAs), etc. Additionally or alternatively, some functions, such as those of any of the microcontrollers 68 and 76 (FIG. 1), of the PHY controller 112 (FIG. 2), of the microcontrollers 160, 164 and 176 (FIG. 5) and / or the microcontrollers 196 and 200 (FIG. 6), may be implemented in software and / or use a combination of hardware and software elements.
[0087] In some embodiments, any of microcontrollers 68 and 76 (FIG. 1), PHY controller 112 (FIG. 2), microcontrollers 160, 164 and 176 (FIG. 5), and / or microcontrollers 196 and 200 (FIG. 6) may comprise a programmable processor that is programmed with software to perform the functions described herein. The software may be downloaded to the processor in electronic form, for example over a network, or the software may alternatively or additionally be provided and / or stored on a non-transitory tangible medium, such as magnetic, optical, or electronic memory.
[0088] As noted above, while the embodiments described herein primarily address automotive and avionics applications, the methods and systems described herein may also be used in other applications involving control of GPIO ports, such as in industrial or smart home communication systems.
[0089] It should be noted that the above-described embodiments are given by way of example, and that the present invention is not limited to what has been specifically shown and described above. Rather, the scope of the present invention includes both combinations and subcombinations of the various features described above, as well as variations and modifications thereof that would occur to a person skilled in the art upon reading the above description and that are not disclosed in the prior art. Documents incorporated by reference into this patent application shall be considered as integral parts of this application. However, to the extent that any term is defined in these incorporated documents in a manner that contradicts a definition expressly or impliedly made herein, only the definition contained herein shall be considered.
Claims
1. 1. An Ethernet physical layer (PHY) device operative to control a remote peer Ethernet PHY device, comprising: a PHY interface configured to connect to a physical link; generating a Layer 1 frame carrying data for transmission to a peer Ethernet PHY device; inserting one or more management frames into the Layer 1 frame, the management frames being separate from the Layer 1 frame and configured to control a general purpose input / output (GPIO) port associated with the peer Ethernet PHY device; transmitting the Layer 1 frame and the one or more inserted management frames via the PHY interface over the physical link to the peer Ethernet PHY device for controlling operation of one or more of the GPIO ports associated with the peer Ethernet PHY device; receiving one or more verifications via the PHY interface confirming that the one or more management frames were successfully received at the peer Ethernet PHY device; and a PHY circuit configured to:
11. An Ethernet PHY device, wherein in at least one of the one or more management frames, the PHY circuitry is configured to instruct the peer Ethernet PHY device to control a microcontroller.
2. 10. The Ethernet PHY device of claim 1, wherein the PHY circuitry is configured to insert the one or more management frames by inserting one or more Operation, Administration and Maintenance (OAM) frames.
3. 3. The Ethernet PHY device of claim 1 or 2, wherein in at least one of the one or more management frames, the PHY circuitry is configured to instruct the peer Ethernet PHY device to set the GPIO port to a particular output logic level.
4. 4. The Ethernet PHY device of claim 1, wherein in at least one of the one or more management frames, the PHY circuitry is configured to instruct the peer Ethernet PHY device to read an input logic level of the GPIO port.
5. 5. The Ethernet PHY device of claim 1, wherein in at least one of the one or more management frames, the PHY circuitry is configured to instruct the peer Ethernet PHY device to control the microcontroller to perform a safety control operation in a vehicle.
6. 6. The Ethernet PHY device of claim 1, wherein the PHY circuitry is configured to receive the one or more management frames from a host.
7. 7. An Ethernet PHY device according to claim 1, wherein the PHY circuitry is configured to receive parameters for controlling the GPIO port via a register and to configure the one or more management frames based on the parameters.
8. An Ethernet physical layer (PHY) device operative to control a remote peer Ethernet PHY device, comprising: a PHY interface configured to connect to a physical link; generating a Layer 1 frame carrying data for transmission to a peer Ethernet PHY device; inserting one or more management frames into the Layer 1 frame, the management frames being separate from the Layer 1 frame and configured to control a general purpose input / output (GPIO) port associated with the peer Ethernet PHY device; transmitting the Layer 1 frame and the one or more inserted management frames via the PHY interface over the physical link to the peer Ethernet PHY device for controlling operation of one or more of the GPIO ports associated with the peer Ethernet PHY device; receiving one or more verifications via the PHY interface confirming that the one or more management frames were successfully received at the peer Ethernet PHY device; and a PHY circuit configured to: An Ethernet PHY device, wherein the PHY circuitry is configured to receive parameters for controlling the GPIO port via a register and to configure the one or more management frames based on the parameters.
9. 1. An Ethernet physical layer (PHY) device controlled by a remote peer Ethernet PHY device, comprising: a PHY interface configured to connect to a physical link; receiving, via the PHY interface, a Layer 1 frame carrying data transmitted from a peer Ethernet PHY device over the physical link; receiving, within the Layer 1 frame, one or more management frames transmitted from the peer Ethernet PHY device for controlling a general purpose input / output (GPIO) port associated with the Ethernet PHY device; controlling the GPIO port in response to instructions contained in the one or more management frames; transmitting, via the PHY interface, one or more verifications to the peer Ethernet PHY device confirming successful reception of the one or more management frames; a PHY circuit configured to Equipped with An Ethernet physical layer (PHY) device, wherein in response to at least one of the one or more management frames, the PHY circuitry is configured to control a microcontroller.
10. 10. The Ethernet PHY device of claim 9, wherein the PHY circuitry is configured to receive the one or more management frames by receiving one or more Operation, Administration and Maintenance (OAM) frames.
11. 11. An Ethernet PHY device as claimed in claim 9 or 10, wherein in response to at least one of the one or more management frames, the PHY circuitry is configured to set the GPIO port to a particular output logic level.
12. 12. The Ethernet PHY device of claim 9, wherein in response to at least one of the one or more management frames, the PHY circuitry is configured to read an input logic level of the GPIO port and report the input logic level of the GPIO to the peer Ethernet PHY device.
13. 13. The Ethernet PHY device of claim 9, wherein in response to at least one of the one or more management frames, the PHY circuitry is configured to control the microcontroller to perform a safety control operation in a vehicle.
14. A microcontroller; a first Ethernet PHY device connected to said microcontroller by a general purpose input / output (GPIO) port; a second Ethernet PHY device connected to the first Ethernet PHY device via a physical link; Equipped with The second Ethernet PHY device exchanging Layer 1 frames with the first Ethernet PHY device carrying data; transmitting one or more management frames within the Layer 1 frame to the first Ethernet PHY device, the management frames being separate from the Layer 1 frame and configured to control the microcontroller via the GPIO port of the first Ethernet PHY device; configured to receive, via a PHY interface, one or more verifications from the first Ethernet PHY device confirming that the one or more management frames have been successfully received at the first Ethernet PHY device; Ethernet communication system.
15. In at least one of the one or more management frames, the second Ethernet PHY device is configured to initiate a safety control action in a vehicle; the first Ethernet PHY device is configured to control the microcontroller via the GPIO port to perform the safety control operations; the microcontroller is configured to perform the safety control operation in response to control of the GPIO port.
15. The Ethernet communication system of claim 14.
16. 16. The Ethernet communication system of claim 14 or 15, wherein in response to at least one of the one or more management frames, the first Ethernet PHY device is configured to reset the microcontroller via the GPIO port.
17. 17. The Ethernet communication system of claim 14, wherein in response to at least one of the one or more management frames, the first Ethernet PHY device is configured to read a status of the microcontroller via the GPIO port.
18. 18. An Ethernet communication system according to claim 14, wherein the first Ethernet PHY device is configured to control the GPIO port regardless of whether the microcontroller is functioning properly or malfunctioning.
19. 1. A method for controlling a remote peer Ethernet physical layer (PHY) device, comprising: generating, at an Ethernet PHY device connected to a peer Ethernet PHY device over a physical link, a Layer 1 frame carrying data for transmission to the peer Ethernet PHY device; inserting, at the Ethernet PHY device, one or more management frames into the Layer 1 frame, the management frames being separate from the Layer 1 frame and configured to control a general purpose input / output (GPIO) port associated with the peer Ethernet PHY device; transmitting the Layer 1 frame and the one or more inserted management frames from the Ethernet PHY device over the physical link to the peer Ethernet PHY device to control operation of one or more of the GPIO ports associated with the peer Ethernet PHY device; receiving, at the Ethernet PHY device, one or more verifications from the peer Ethernet PHY device, the one or more verifications confirming that the one or more management frames were successfully received at the peer Ethernet PHY device; Equipped with In at least one of the one or more management frames, the Ethernet PHY device instructs the peer Ethernet PHY device to control a microcontroller.
20. A method for controlling a remote peer Ethernet physical layer (PHY) device, comprising: generating, at an Ethernet PHY device connected to a peer Ethernet PHY device over a physical link, a Layer 1 frame carrying data for transmission to the peer Ethernet PHY device; receiving, via a register at the Ethernet PHY device, parameters for controlling the GPIO port and inserting, based on the parameters, one or more management frames into the Layer 1 frame that are separate from the Layer 1 frame and configured to control a general purpose input / output (GPIO) port associated with the peer Ethernet PHY device; transmitting the Layer 1 frame and the one or more inserted management frames from the Ethernet PHY device over the physical link to the peer Ethernet PHY device to control operation of one or more of the GPIO ports associated with the peer Ethernet PHY device; receiving, at the Ethernet PHY device, one or more verifications from the peer Ethernet PHY device, the one or more verifications confirming that the one or more management frames were successfully received at the peer Ethernet PHY device; A method comprising:
21. 21. The method of claim 19 or 20, wherein inserting one or more management frames comprises inserting one or more Operation, Administration and Maintenance (OAM) frames.
22. 1. A method for controlling a general purpose input / output (GPIO) port associated with an Ethernet physical layer (PHY) device, comprising: receiving at the Ethernet PHY device a Layer 1 frame carrying data transmitted from a peer Ethernet PHY device over a physical link; receiving in the Layer 1 frame one or more management frames transmitted from the peer Ethernet PHY device and controlling the GPIO port associated with the Ethernet PHY device; controlling the GPIO port associated with the Ethernet PHY device in response to instructions contained in the one or more management frames; transmitting one or more verifications from the Ethernet PHY device to the peer Ethernet PHY device, the one or more verifications confirming that the one or more management frames were successfully received; Equipped with In response to at least one of the one or more management frames, the Ethernet PHY device controls a microcontroller.
23. 23. The method of claim 22, wherein receiving one or more management frames comprises receiving one or more Operation, Administration and Maintenance (OAM) frames.
Citation Information
Patent Citations
Transmission apparatus with management function, status management system, status management method and status management program
JP2009135767A
Information processing system and information processing method
JP2013246647A
Synchronous slave-to-slave communications
JP2017135711A
Remote monitoring and configuration of physical layer devices
US20160205224A1
