WO1996019058A1 - Communications network, a dual mode data transfer system therefor - Google Patents

Communications network, a dual mode data transfer system therefor Download PDF

Info

Publication number
WO1996019058A1
WO1996019058A1 PCT/US1995/016246 US9516246W WO9619058A1 WO 1996019058 A1 WO1996019058 A1 WO 1996019058A1 US 9516246 W US9516246 W US 9516246W WO 9619058 A1 WO9619058 A1 WO 9619058A1
Authority
WO
WIPO (PCT)
Prior art keywords
mcu
bus
byte
link apparatus
data
Prior art date
Application number
PCT/US1995/016246
Other languages
French (fr)
Other versions
WO1996019058A9 (en
Inventor
Richard A. Halter
Robert J. Randel
Ronald F. Hormel
John Stark
Original Assignee
Chrysler Corporation
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Chrysler Corporation filed Critical Chrysler Corporation
Priority to AU44699/96A priority Critical patent/AU4469996A/en
Priority to EP95943428A priority patent/EP0797881B1/en
Priority to AT95943428T priority patent/ATE196045T1/en
Priority to DE69518665T priority patent/DE69518665T2/en
Publication of WO1996019058A1 publication Critical patent/WO1996019058A1/en
Publication of WO1996019058A9 publication Critical patent/WO1996019058A9/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/40Bus networks
    • H04L12/407Bus networks with decentralised control
    • H04L12/413Bus networks with decentralised control with random access, e.g. carrier-sense multiple-access with collision detection (CSMA-CD)
    • H04L12/4135Bus networks with decentralised control with random access, e.g. carrier-sense multiple-access with collision detection (CSMA-CD) using bit-wise arbitration
    • FMECHANICAL ENGINEERING; LIGHTING; HEATING; WEAPONS; BLASTING
    • F02COMBUSTION ENGINES; HOT-GAS OR COMBUSTION-PRODUCT ENGINE PLANTS
    • F02BINTERNAL-COMBUSTION PISTON ENGINES; COMBUSTION ENGINES IN GENERAL
    • F02B75/00Other engines
    • F02B75/02Engines characterised by their cycles, e.g. six-stroke
    • F02B2075/022Engines characterised by their cycles, e.g. six-stroke having less than six strokes per cycle
    • F02B2075/027Engines characterised by their cycles, e.g. six-stroke having less than six strokes per cycle four

Definitions

  • This invention relates to communication over a multiplex data communications network.
  • this invention relates to a system for interchanging data bytes within a node between a microcontroller (MCU) and a first peripheral at a chosen clock
  • the first peripheral generates a protocol bit and then converts both the protocol bit and each bit of the data bytes from the MCU into variable pulse width modulated (VPWM) bits forming a VPWM message.
  • VPWM variable pulse width modulated
  • the first peripheral sends the VPWM bits to a second peripheral that converts each VPWM bit into a communications symbol (known as a J1850 symbol) conforming to the communication requirements of the Society of Automotive Engineers (SAE) established
  • the second peripheral drives these symbols onto a single-wire communications bus to communicate the message to other nodes connected -to the bus.
  • the second peripheral also routes a reflection of the symbols back to the first peripheral and reconverts the symbols into VPWM bits.
  • the first peripheral than reassembling the reflected bits into bytes used in the next interchange of bytes with the MCU and to check for the achievement of arbitration if other nodes on the bus are transmitting.
  • That search ended in the present invention which accomplishes reducing the time restraints required to process the data prior to converting the data into J1850 symbols and for determining whether a node has gained control of the bus by winning an arbitration contest with competing nodes during a message frame.
  • the present invention discloses using a
  • LSPDR serial peripheral data register
  • Link link device
  • the transfer of data bytes between the MCU and the Link occurs in the form of individual bits of a byte transferred serially from a data register in the MCU to a data register in the link during a SPI transfer (SPI-XFR) at a chosen clock rate illustratively, one bit/one ⁇ s pulse.
  • the individual bits of the SPI-XFRed byte are converted to variable pulse width modulated bits and are then driven onto the bus by an integrated driver/receiver (IDR) module as J1850 symbols at the chosen clock rate but delayed to compensate for the variations in pulse width of each symbol, e.g., one symbol may be longer than another (64 or 128 ⁇ s long). Hence 64 clock pulses would occur during the transfer of a 64 ⁇ s long symbol.
  • IDR integrated driver/receiver
  • IDR integrated driver receiver circuit
  • Clock signal clocks bits of data bytes through circuits within the MCU at a fixed clock frequency while shift clock (SHCLK), clock (CLK) and clock divide by 2 (CLKDIV2) and clock circuits within the Link and IDR during transfers of VPWM bits and symbols
  • Fig. l illustrates in block diagram form a
  • FIG. 2 depicts in expanded block diagram form to show the components of the Link in a pair of nodes of Fig. 1 connected to the communication bus;
  • Figs. 3, 4 and 5 illustrate in partial block and logic diagram form the transmitter/receiver, the transmitter and receiver circuits, respectively, of the symbol encoder/decoder modified to interface and form a part of the Link;
  • Fig. 6A-6G depict significant timing sequences associated with the operation of the SPI-XFR system
  • Fig. 7A-7J illustrate timing diagrams associated with transferring a three-byte message from the MCU to the Link and over the single-wire bus to other nodes of the network;
  • Fig. 8 illustrates a state diagram of the various states required to transfer byte messages from the MCU to the bus and for checking arbitration of symbols on the bus;
  • Fig. 9A-9C illustrates in partial block and partial logic diagram form the devices in Link used to exchange data bytes with the MCU and to send to and receive from the bus data symbols;
  • Fig. 10A and 10B depict the flowchart of the firmware programs for controlling the operation of the MCU during solicited and unsolicited SPI-XFRs of data bytes.
  • Fig. 10C represents a detail of said flowchart.
  • Fig. 1 depicts a block diagram of a communications network 10 with several nodes 16a-16f coupled between a single-wire bus 12 and a plurality of sensors or application devices 14a-14f.
  • the nodes include MCUs 18a-18f and Links 22a-22f circuits and interfaces for performing SPI-XFRs, and IDRs 20a-20f connected to the Links for converting between digital pulses and J1850 symbols during sending and receiving messages over bus 12.
  • Each Link 22 interconnects between an MCU 18 and an IDR 20.
  • Nodes 16a-16f disposed throughout the vehicle, connect to bus 12 via stubs 13a-l3f, respectively.
  • Bus 12 supports bi-directional transfers of serial data between nodes.
  • Nodes 16a-l6f permit exchange of bit stream information of almost any established protocol. THE NODES
  • FIG. 2 there a block diagram depicts additional details of nodes 16a and 16b.
  • sensor 14a detects analog measurands and an analog to digital converter in MCU
  • MCU 18a converts that signal into digital signals usable by MCU 18a.
  • MCU 18a accepts and then transforms the digital signals into a series of message bytes for transfer over bus 12. To effect the transfers, each message byte routes over a parallel bus within MCU 18a and into a conventional MCU serial peripheral data register (MSPDR) 19f for temporary storage.
  • MSPDR MCU serial peripheral data register
  • MCU 18a interchanges the stored message byte by a SPI-XFR, bit-by-bit, serially with a previously transferred data byte stored in a serial peripheral data register (LSPDR) 28a of Link 22a.
  • LSPDR serial peripheral data register
  • MCU 18a gets unusable data while Link 22a gets the first message byte associated with the sensed data.
  • the interchanging of bits occur via SPI circuit 19d through master-in slave-out (MISO) and master-out slave-in (MOS1) pins of MCU 18a that connects MSPDR 19f to LSPDR 28a.
  • MISO master-in slave-out
  • MOS1 master-out slave-in
  • SPISCK starts after MCU 18a strobes a handshaking signal called Byte Ready (BYT RDY) from a designated output port to holding registers STATEIN 62a, STATEOUT 70a and a main state machine (MSTATE 48a) of Link 22a.
  • BYT RDY Byte Ready
  • MSTATE 48a main state machine
  • Link 22a Upon receipt of BYT RDY, Link 22a immediately initiates, illustratively, a high-speed l MHz, eightbit, SPI- XFR.
  • MSPDR unloads byte 1 through the MISO pin transferring serially one bit at a time of the first byte of the message to LSPDR.
  • LSPDR serially unloads bits of byte X (unknown data) into the MOSI pin of MCU 18a.
  • Figs. 6E and 6F show the SPI-XFR in response to SPISCK of Fig. 6C.
  • the rising edge of SPISCK causes MCU 18 to place data at the sending MISO pin and at the sending MOSI pin of Link 22.
  • the falling edge of SPISCK causes the latching of the data on the receiving pins of MCU 18a and Link 22a.
  • the transfer of each byte consumes about 11 ⁇ s.
  • MCU 18a Following the transfer of byte 1, and the receipt of an unusable byte X, MCU 18a writes the next byte, byte 2, over byte X in MSPDR 19f and then strobes BYT RDY again.
  • the rising edge of this second BYT RDY must occur at least 2.1 ⁇ s after the falling edge of the last SPISCK pulse of the SPI transfer. (See Fig. 7D and 7G Index # 2). Link and IDR Converting the SPI
  • Encoder 37a converts each bit into send codes SNDO and 6ND1. These send codes have values of 00, 01, 10 or 11 depending upon the bit value and level (HIGH or LOW) of the bus for the next symbol.
  • This three-bit-send code joins with a three-bit-receive code (not shown) to form a six-bit code that routes to a 6 to 3 ROM address multiplexer (MUX) 38.
  • MUX ROM address multiplexer
  • each data byte bit from the SPI-XFR causes an address from MUX 38 of XMIT/REC Ckt 24 in SED 23 to select one of eight 10 bit transmit words stored in a decoder ROM 40.
  • These 10 bit words represent nominal lengths of time for the various J1850 symbols (minus 19 ⁇ s). It takes about 19 ⁇ s for SED 22a of Fig. 2 to receive back from IDR 20a the reflection of the leading edge of the transmitted symbol.
  • the messages will contain symbols for the start-of-frame (SOF) (also referred to as start-of-message (SOM)), a long bit (nominally 128 ⁇ s), a short bit (nominally 64 ⁇ s), an end-of-data (EOD) and an end-of-frame (EOF) symbol which are nominally 200 and 239 ⁇ s respectively.
  • SOF start-of-frame
  • SOM start-of-message
  • EOD end-of-data
  • EEF end-of-frame
  • a comparator 44 compares time counted in a 10-bit counter 42 to the value of the ROMDATA word from the 4 to 10 Decoder ROM 40 to determine if a comparison occurs. If so, then circuits in Transmit (XMIT) Ckt 26 of Fig. 4 ends the transmission of that symbol. The link then starts the transmission of the next symbol and initiates a variable pulse width modulated (VPWMout) signal of the selected width and logic level from SED 23a of Fig. 2 to the transmitter (XMIT) circuit of an interface driver receiver (IDR) circuit 20a.
  • the XMIT ckt of IDR 20a converts each VPWMout signal into a trapezoidal pulse shaped symbol resembling an analog signal. These symbols travel over bus 12 at a rate of about 10.4 K bits/sec. or 10.4 Kilobauds.
  • a receiver circuit in IDR 20a taps single-wire bus 12 and reflects each symbol back towards transmitting MCU 18a. For data symbols, not protocol symbols, this reflection of symbols occurs during state 10 (ST10), explained infra (or see Fig. 8, of the main state machine in Link 23a). Arbitration of the symbols on bus 12 occurs with respect to a BITVAL signal from SED 23a. (The transfer and arbitration of protocol symbols are explained in co-pending application of Garr et. al. filed December 16, 1994, serial no. U.s.S.N.
  • a change to ST10 the main state for bus 12 transmitting and receiving bits to and from bus 12, causes the XMITMODE of STATEIN 62a to set and to initiate transmission of a symbol bit onto bus 12.
  • the receiver circuit of IDR 20a receives a reflection of the symbol placed on bus 12 and converts the symbol to a digital bit and routes the bit back to a receive pin of link 22a.
  • the receive pin connects to REC Ckt 27 of Fig. 5 within SED 23a.
  • the REC Ckt 27 contains
  • BIT CNT does not equal zero
  • MSTATE 48a moves back to ST 10.
  • Arbitration of symbols and the movement between ST10 and ST12 continues until all symbols in the message byte passes.
  • the Link clock signal, SHCLK clocks the bit movement during ST 10 and ST12.
  • Fig. 6G illustrates the reception of logic 1 and logic 0 bits from bus 12.
  • the time between SHCLK pulses is determined by the duration of the pulse. A logic 0 could be a long or short symbol, hence the duration of the pulse may be either 64 or 128 ⁇ s. From ST 12, if BIT CNT equals zero, then MSTATE 48a moves ⁇ o ST 13.
  • node 16a prepares for a SPI transfer after receiving eight reflections of bits from bus 13 and placing them in LSPDR 28a.
  • CNT, Link 22a and MCU 18a interchange the eight bits in the LSPDR 28a with the eight bits of byte 2 in MSPDR
  • SED 23 provides clock signals for the node.
  • An OSC signal from MCU 18 provides a source of continuous and accurate clock signals used for clocking system operations.
  • a multiplexer (MUX) circuit extracts from the two pulse trains a first clock signal (CLK) of Fig. 6A of a chosen frequency, e.g., 2 MHz and the inverse clock signal (CLKL) .
  • a sequential logic divide by two () circuit converts, illustratively, the 2 MHz CLK signal to a 1 MHz CLKDIV2 signal of Fig. 6B that routes to various sequential logic circuits of Link 22.
  • CLKDIV2 signals control the transfer of input signals into Link 22 and the changing of the states. Note in Fig. 9A, the rising edge of the CLKDIV2 signal clocks memory 33b.
  • a combinational logic circuit converts CLKDIV2 to a 1 MHz INTCLK signal of FIG. 6C offset from CLKDXV2 by a 1/4 cycle.
  • the INTCLK signal clocks the setting of flags and other output signals from Link 22 including SO-0 through so-33. (See Fig. 9A).
  • INTCLK combines with other control signals to create additional control signals such as SPICLK that occur at the same time as INTCLK.
  • Another delay circuit converts the INTCLK ⁇ ignal into a 1/4 cycle pulse occurring in the last 1/4 of the INTCLK cycle.
  • the STENH signal, Fig. 6D provides the clock signal for gating the state output signals.
  • a sensor 14 supplies variable
  • MCU 18 measurand information such as pressure, rate of flow, speed etc. in digital form to MCU 18.
  • MCU 18 measurand information such as pressure, rate of flow, speed etc. in digital form to MCU 18.
  • J1850 messages require a protocol symbol (SOF) to precede a header byte and one or two protocol symbols (EOD and EOF) to follow the cyclic redundancy check (CRC) bytes in a message frame.
  • SOF protocol symbol
  • EOD and EOF protocol symbols
  • CRC cyclic redundancy check
  • Fig. 7A shows the sequence of numbers of the state machine flow diagram of Fig. 8 in an effort to coordinate the operation of the system.
  • Fig. 7B shows an idle condition of bus 12 and that bus 12 has been idle for some period of time before MCU 18 initiates a transmission. This means that when bus 12 became idle, MCU 18 did not have a message queued up for transmission.
  • MCU 18 When MCU 18 obtains a message for transmission, MCU 18 attempts to perform a solicited transfer. Such a transfer occurs when MCU 18 transmits an initial message byte, usually the header byte. MCU 18 enters a transmitting mode by not setting the serial peripheral interface status flag (SPIF) in Fig. 10A of the serial peripheral status register (SPSR) or as a result of a reset of the system. MCU 18 asserts the BYT RDY pin to start the transmission of a message.
  • SPIF serial peripheral interface status flag
  • SPSR serial peripheral status register
  • SPIF After the solicited transfer, SPIF gets set automatically by MCU hardware. Then unsolicited transfers occur for all subsequent transfers between Link 22 and MCU 18.
  • Figs. 10A and 10B illustrate in flowchart form, the software operations in MCU 18 used to communicate with link 22. These charts represent an effort to organize the generation and flow of signals through MCU 18. These flowcharts differ from the conventional box and diamond flowcharts.
  • a branch may be caused by either a YES or NO condition, with these being signified by a Y or N in a small box as indicated.
  • An arrowhead depicts where secondary flow rejoins the main flow.
  • reference number indicates the position or step along the line being discussed.
  • this firmware program requires MCU 18 to determine the status of SP ⁇ F. Assuming a set SPIF, MCU 18 then must determine the status of bus 12. Link 22 provides an idle bus status signal to MCU 18. For an idle bus 12, CPU 19a receives instructions to determine the status of the input capture flag (ICF). A set ICF signal means an idle bus has occurred since the last time MCU 18 inspected bus 12, i.e., there is an
  • MCU 18 was receiving a message, for which the transmission has finished. MCU 18 must process the received message before starting the transmission, due to time
  • XMTBUF has a non-zero value.
  • XMTNUM 3. Assuming an idle bus 12, and CPU 19a learns the
  • CPU 19a sets the
  • An event (internal or external to MCU 181 causes CPU 19a to generate a message frame for transmission over bus 12.
  • An application layer subroutine formats the message frame and stores the bytes in XMTBUF.
  • XMTNUM gets set to the number of bytes that MCU 18 will transmit.
  • CPU 19a fills XMTBUF
  • Fig. 10C so that the first byte to send gets stored as XMTBUF, XMTNUM-1 or XMTBUF, 2; the second byte stored as XMTBUF, XMTNUM-2 or XMTBUF, 1; and the third byte stored as XMTBUF, XMTNUM-3 or XMTBUF, 0.
  • CPU 19a After establishing XMTNUM-3, with bus 12 idle, CPU 19a sets XMTNDXBXMTNUM, illustratively to 3 and
  • ARBNDX XMTNUM or 3.
  • ARBNDX is an index into XMTBUF that points to the next byte coming back from bus 12. (See steps 210-212).
  • CPU 19a receives instructions to load
  • CPU 19a then sets XMTNDX equal to XMTNDX-1 or in this illustration to 2.
  • CPU 19a receives instructions to determine if the SPI-XFR between MCU 18 and Link 22 has been completed. (See Fig. 10A, step 219) . Usually, this transfer consumes about 11 ⁇ s well within the first 400 ⁇ s polling cycle. The byte that was stored in the LSPDR 28, which is unusable, comes into the MSPDR 19f of MCU 18.
  • MCU 18 After completion of the transfer, the hardware in MCU 18 automatically clears the SPIF bit in the SPI Status Register, (SPSR) (not shown). Then CPU 19a receives instructions to load the byte received from the LSPDR 28 into a non-volatile MCU register. This completes the solicited transfer. MCU 18 does not care about the initial byte that comes back into the MSPDR from Link 22. (See steps 220-221). If XMTNDX does not equal zero, CPU 19a sets BYT RDY pin LO.
  • SPSR SPI Status Register
  • IDR 20 and Link 22 After loading byte 1 on bus 12, IDR 20 and Link 22 reflect byte 1 (received off bus 12) back to MCU 18 via an unsolicited transfer. (See Fig. 7G, index #3).
  • Fig. 10A during another 400 ⁇ s polling cycle, at step 200, CPU 19a determines if SPIF is set. This serial peripheral transfer flag notifies MCU 18 that the solicited data transfer between MCU 18 and Link 22 has been completed. Hence the program branches to the unsolicited transfer program on Fig. 10B.
  • Link 22 receives byte 2 (if any) from MCU 18 via the SPI-XFR. During the time Link 22 was attempting to transmit byte 1, Link 22 could ave lost arbitration to another transmitting node. If so, the byte it was attempting to transmit is not the byte that ends up being transmitted on bus 12. MCU 18 checks each byte it receives back from Link 22 against the byte it attempted to transmit. If byte 1 does not match, MCU 18 switches to a receive operation. If the first byte received back matches but subsequent bytes do not, MCU 18 assumes an error has occurred. This is due to the fact that this system utilizes a single-byte header and arbitration should be resolved with the first byte. If the second or subsequent bytes do not match, MCU 18 terminates transmission of the message and waits for the next idle bus period.
  • CPU 19a reacts to the next instruction of accessing the SPI STATUS REGISTER (SPSR). Then CPU 19a receives the instruction to load the data byte read from bus 12 into a nonvolatile MCU register (not shown). This action also clears the SPIF bit.
  • SPSR SPI STATUS REGISTER
  • CPU 19a determines if the byte received from bus 12 equals the byte transmitted. If so, CPU 19a updates the ARBNDX by setting it to [3-1] or 2. (See steps 230-240).
  • CPU 19a receives instructions to determine if XMTNDX equals zero. Since XMTNDX does not, CPU 19a executes the next instruction to place the last byte in the SPDR (XMTNDX-1) . Then CPU 19a receives the instruction to set the BYT RDY pin HI. Leaving the BYT RDY pin HI indicates that the byte in the MSPDR is the last byte to be transmitted. CPU 19a then moves to execute the instruction to update the XMTNDX before existing the program. XMTNDX now becomes zero.
  • CPU 19a loads the last byte into MSPDR 19f and asserts the BYT RDY pin HI.
  • BYT RDY pin remains HI through the next unsolicited transfer. This is referred to as the long form of BYT RDY.
  • This tells Link 22 that the byte sitting in MSPDR I9f is the last byte to transmit.
  • the rising edge of a long BYT RDY must occur at least 2.1 ⁇ s after the falling edge of the last SCK pulse of the SPI XFR.
  • MCU 18 receives BYTE 2
  • Link 22 receives byte 3. Following the transfer, MCU 18 returns the BYT RDY pin LO.
  • unsolicited transfer (Fig. 7G, index ⁇ 5) sends byte 3 to MCU 18. Then MCU 18 exits the Unsolicited program. Link 22 automatically transmits the proper CRC byte on to bus 12. Unsolicited transfer (index ⁇ 6) sends the CRC to MCU 18. During the unsolicited transfer for the CRC, ARBNDX equals 0, so MCU 18 does not participate in this transfer. The idle pin returns to LO (index # 7) indicating bus 12 is once again idle. This causes an interrupt to MCU 18.

Abstract

A link apparatus in a node of a multinode, collision-resolution, multiplexing communications system connected between a microcontroller (MCU) that receives measurand data from an input device such as a sensor and an integrated driver and receiver (IDR) for assuming some of the functions of the MCU in delivering and receiving messages to and from a single-wire bus communications network. The MCU contains firmware for converting the measurand data into data bytes, the link apparatus and the MCU contain circuits for effecting a SPI transfer and the link apparatus contains additional circuits for converting each bit of the message bytes into variable pulse width modulated (VPWM) bits. The VPWM bits get converted into J1850 symbols before being placed on a single-wire communication bus. Circuits are provided in the link apparatus for checking arbitration of the protocol and data symbols communicated over the bus.

Description

COMMUNICATIONS NETWORK, A DUAL
MODE DATA TRANSFER SYSTEM THEREFOR
This invention relates to communication over a multiplex data communications network. In particular, this invention relates to a system for interchanging data bytes within a node between a microcontroller (MCU) and a first peripheral at a chosen clock
frequency. Then within the same node, the first peripheral generates a protocol bit and then converts both the protocol bit and each bit of the data bytes from the MCU into variable pulse width modulated (VPWM) bits forming a VPWM message. After forming the message of VPWM bits, the first peripheral sends the VPWM bits to a second peripheral that converts each VPWM bit into a communications symbol (known as a J1850 symbol) conforming to the communication requirements of the Society of Automotive Engineers (SAE) established
Recommended Practice J18S0 (a set of technical
requirements and parameters).
The second peripheral, a transceiver, drives these symbols onto a single-wire communications bus to communicate the message to other nodes connected -to the bus. The second peripheral also routes a reflection of the symbols back to the first peripheral and reconverts the symbols into VPWM bits. The first peripheral than reassembling the reflected bits into bytes used in the next interchange of bytes with the MCU and to check for the achievement of arbitration if other nodes on the bus are transmitting.
Normally, transmitting and receiving serial bytes between the first peripheral device and the MCU require interrupts in the transfer programming. U.S. Patent No. 5,274,636 dated Dec. 26, 1993 of Halter et al.
entitled "Automatic Multiplex Data Link System, Symbol Encoder Decoder Therefor" (or SED patent) teaches such a system. Such interruptions imposes a heavy burden on the MCU to perform the process of transmitting and receiving serially arranged byte messages. During transmission, programming of the MCU must allow for, illustratively, 34 microseconds between bytes for the introduction of an interrupt. This imposes time restraints on the MCU when preparing each byte for transmission, similar time restraints occur for receiving bytes of data. We searched for ways to reduce the imposed time restraints on the MCU while improving the processing performance. That search ended in the present invention which accomplishes reducing the time restraints required to process the data prior to converting the data into J1850 symbols and for determining whether a node has gained control of the bus by winning an arbitration contest with competing nodes during a message frame.
The present invention discloses using a
conventional serial peripheral interface (SPI)
transfer circuit within the MCU to communicate with a serial peripheral data register (LSPDR) in a peripheral referred to as a link device (Link) . The transfer of data bytes between the MCU and the Link occurs in the form of individual bits of a byte transferred serially from a data register in the MCU to a data register in the link during a SPI transfer (SPI-XFR) at a chosen clock rate illustratively, one bit/one μs pulse. Then, from the Link, the individual bits of the SPI-XFRed byte are converted to variable pulse width modulated bits and are then driven onto the bus by an integrated driver/receiver (IDR) module as J1850 symbols at the chosen clock rate but delayed to compensate for the variations in pulse width of each symbol, e.g., one symbol may be longer than another (64 or 128 μs long). Hence 64 clock pulses would occur during the transfer of a 64 μs long symbol. The ratio of SPI transfer to bus transfer are such that a period of time,
illustratively 500 μs, may result between SPI-XFRs of individual bytes, removing the need for interrupts. The system, however, contains the capability of operating in an interrupt mode.
The sending and receiving of bits of the data bytes between the Link and the second peripheral called an integrated driver receiver circuit (IDR) and over the single-wire bus occur at the same rates of speed that symbols travel over the bus.
Clock signal (SPISCK) clocks bits of data bytes through circuits within the MCU at a fixed clock frequency while shift clock (SHCLK), clock (CLK) and clock divide by 2 (CLKDIV2) and clock circuits within the Link and IDR during transfers of VPWM bits and symbols
The invention and its modes of operation will be more fully understood from the following detailed description when taken with the appended drawing figures in which:
Fig. l illustrates in block diagram form a
communications network employing the dual-stage data transfer system of this invention in each node of the network; Fig. 2 depicts in expanded block diagram form to show the components of the Link in a pair of nodes of Fig. 1 connected to the communication bus;
Figs. 3, 4 and 5 illustrate in partial block and logic diagram form the transmitter/receiver, the transmitter and receiver circuits, respectively, of the symbol encoder/decoder modified to interface and form a part of the Link;
Fig. 6A-6G depict significant timing sequences associated with the operation of the SPI-XFR system;
Fig. 7A-7J illustrate timing diagrams associated with transferring a three-byte message from the MCU to the Link and over the single-wire bus to other nodes of the network;
Fig. 8 illustrates a state diagram of the various states required to transfer byte messages from the MCU to the bus and for checking arbitration of symbols on the bus;
Fig. 9A-9C illustrates in partial block and partial logic diagram form the devices in Link used to exchange data bytes with the MCU and to send to and receive from the bus data symbols; and
Fig. 10A and 10B depict the flowchart of the firmware programs for controlling the operation of the MCU during solicited and unsolicited SPI-XFRs of data bytes.
Fig. 10C represents a detail of said flowchart.
Fig. 1 depicts a block diagram of a communications network 10 with several nodes 16a-16f coupled between a single-wire bus 12 and a plurality of sensors or application devices 14a-14f. The nodes include MCUs 18a-18f and Links 22a-22f circuits and interfaces for performing SPI-XFRs, and IDRs 20a-20f connected to the Links for converting between digital pulses and J1850 symbols during sending and receiving messages over bus 12. Each Link 22 interconnects between an MCU 18 and an IDR 20.
Nodes 16a-16f, disposed throughout the vehicle, connect to bus 12 via stubs 13a-l3f, respectively. Bus 12 supports bi-directional transfers of serial data between nodes. Nodes 16a-l6f permit exchange of bit stream information of almost any established protocol. THE NODES
Sensor to MCU Tranefers
Referring to Fig. 2, there a block diagram depicts additional details of nodes 16a and 16b.
Illustratively, in node 16a, sensor 14a detects analog measurands and an analog to digital converter in MCU
18a converts that signal into digital signals usable by MCU 18a. MCU 18a accepts and then transforms the digital signals into a series of message bytes for transfer over bus 12. To effect the transfers, each message byte routes over a parallel bus within MCU 18a and into a conventional MCU serial peripheral data register (MSPDR) 19f for temporary storage. Loading a Message Byte into the L ink by a SPT-XFR From MCU.
Assume node 22a desires to transmit a message over bus 12 to other nodes connected to the bus. When prompted, MCU 18a interchanges the stored message byte by a SPI-XFR, bit-by-bit, serially with a previously transferred data byte stored in a serial peripheral data register (LSPDR) 28a of Link 22a. During the initial SPI- XFR, MCU 18a gets unusable data while Link 22a gets the first message byte associated with the sensed data. The interchanging of bits occur via SPI circuit 19d through master-in slave-out (MISO) and master-out slave-in (MOS1) pins of MCU 18a that connects MSPDR 19f to LSPDR 28a. A SPI clock (SPISCX) signal emanating from Link 22a clocks movement of bits through MSPDR 19f while a Link clock signal (SHCLK) clocks movement of bits through LSPDR 28a. SPISCK starts after MCU 18a strobes a handshaking signal called Byte Ready (BYT RDY) from a designated output port to holding registers STATEIN 62a, STATEOUT 70a and a main state machine (MSTATE 48a) of Link 22a. The operation and structural details of MSTATE 48a, STATEIN 62a and STATEOUT 70a appear in co-pending patent application, serial number U.S.S.N. 08/356,999 of
Halter et. al. filed December 16, 1994.
Upon receipt of BYT RDY, Link 22a immediately initiates, illustratively, a high-speed l MHz, eightbit, SPI- XFR. MSPDR unloads byte 1 through the MISO pin transferring serially one bit at a time of the first byte of the message to LSPDR. Simultaneously, LSPDR serially unloads bits of byte X (unknown data) into the MOSI pin of MCU 18a. Figs. 6E and 6F show the SPI-XFR in response to SPISCK of Fig. 6C. The rising edge of SPISCK causes MCU 18 to place data at the sending MISO pin and at the sending MOSI pin of Link 22. The falling edge of SPISCK causes the latching of the data on the receiving pins of MCU 18a and Link 22a. The transfer of each byte consumes about 11 μs.
Following the transfer of byte 1, and the receipt of an unusable byte X, MCU 18a writes the next byte, byte 2, over byte X in MSPDR 19f and then strobes BYT RDY again. The rising edge of this second BYT RDY must occur at least 2.1 μs after the falling edge of the last SPISCK pulse of the SPI transfer. (See Fig. 7D and 7G Index # 2). Link and IDR Converting the SPI
Transferred Data Bits into Data Symbols
The most significant bit (MSB) and then each succeeding bit of byte l in LSPDR 28a routes to an Encoder 37a of Fig. 2. Encoder 37a converts each bit into send codes SNDO and 6ND1. These send codes have values of 00, 01, 10 or 11 depending upon the bit value and level (HIGH or LOW) of the bus for the next symbol.
Send codes route to ports of the XMIT/REC Ckt 24 of Fig. 3 of the symbol/encoder (SED) 23a and join (not shown) an additional code (a logic 0 code or a fixed ground signal) to form a three-bit-send code. This three-bit-send code joins with a three-bit-receive code (not shown) to form a six-bit code that routes to a 6 to 3 ROM address multiplexer (MUX) 38. As described in the SED patent, U.S. Patent No. 5,274,636, each data byte bit from the SPI-XFR causes an address from MUX 38 of XMIT/REC Ckt 24 in SED 23 to select one of eight 10 bit transmit words stored in a decoder ROM 40. These 10 bit words represent nominal lengths of time for the various J1850 symbols (minus 19 μs). It takes about 19 μs for SED 22a of Fig. 2 to receive back from IDR 20a the reflection of the leading edge of the transmitted symbol. Primarily, the messages will contain symbols for the start-of-frame (SOF) (also referred to as start-of-message (SOM)), a long bit (nominally 128 μs), a short bit (nominally 64 μs), an end-of-data (EOD) and an end-of-frame (EOF) symbol which are nominally 200 and 239 μs respectively.
Converting Nomi nal Length Words i nto J1850 Symbols
Within the XMIT/REC Ckt24, a comparator 44 compares time counted in a 10-bit counter 42 to the value of the ROMDATA word from the 4 to 10 Decoder ROM 40 to determine if a comparison occurs. If so, then circuits in Transmit (XMIT) Ckt 26 of Fig. 4 ends the transmission of that symbol. The link then starts the transmission of the next symbol and initiates a variable pulse width modulated (VPWMout) signal of the selected width and logic level from SED 23a of Fig. 2 to the transmitter (XMIT) circuit of an interface driver receiver (IDR) circuit 20a. The XMIT ckt of IDR 20a converts each VPWMout signal into a trapezoidal pulse shaped symbol resembling an analog signal. These symbols travel over bus 12 at a rate of about 10.4 K bits/sec. or 10.4 Kilobauds.
Checking Arbitration
A receiver circuit in IDR 20a taps single-wire bus 12 and reflects each symbol back towards transmitting MCU 18a. For data symbols, not protocol symbols, this reflection of symbols occurs during state 10 (ST10), explained infra (or see Fig. 8, of the main state machine in Link 23a). Arbitration of the symbols on bus 12 occurs with respect to a BITVAL signal from SED 23a. (The transfer and arbitration of protocol symbols are explained in co-pending application of Halter et. al. filed December 16, 1994, serial no. U.s.S.N.
08/356,999).
A change to ST10, the main state for bus 12 transmitting and receiving bits to and from bus 12, causes the XMITMODE of STATEIN 62a to set and to initiate transmission of a symbol bit onto bus 12. The receiver circuit of IDR 20a receives a reflection of the symbol placed on bus 12 and converts the symbol to a digital bit and routes the bit back to a receive pin of link 22a. The receive pin connects to REC Ckt 27 of Fig. 5 within SED 23a. The REC Ckt 27 contains
circuits that determine whether a logic 1 or 0 bit value (BITVAL) relates to the reflected symbol. Then STATEIN holding register 62a of Fig. 2 compares the BITVAL received from SED 23A to the previous MSB of LSPDR 28a. (See Fig. 9B). If the same bit comes in that was previously the MSB of LSPDR 28a, then Link 22a wins arbitration and moves to ST 12. If not. Link 22a loses arbitration to another node on bus 12. (See Fig. 7H, I, and J that illustrates which node wins
arbitration).
In ST 12, the arbitrated bit shifts into LSPDR 28a and the BITCNT in STATEIN 62a increments. (See
9C). If the BIT CNT does not equal zero, then MSTATE 48a moves back to ST 10. Arbitration of symbols and the movement between ST10 and ST12 continues until all symbols in the message byte passes. The Link clock signal, SHCLK, clocks the bit movement during ST 10 and ST12. Fig. 6G illustrates the reception of logic 1 and logic 0 bits from bus 12. The time between SHCLK pulses is determined by the duration of the pulse. A logic 0 could be a long or short symbol, hence the duration of the pulse may be either 64 or 128 μs. From ST 12, if BIT CNT equals zero, then MSTATE 48a moves^o ST 13.
SPI TRANSFER FOR UNLOADING TO THE MCU THE RECEIVED BYTE AMP LOADING THE NEXT BYTE TO THE LINK
In ST 13, node 16a prepares for a SPI transfer after receiving eight reflections of bits from bus 13 and placing them in LSPDR 28a.
in ST14, the SPI-XFR between Link 22a and MCU 18a occurs in response to the 1 μs SPISCK. By using BIT
CNT, Link 22a and MCU 18a interchange the eight bits in the LSPDR 28a with the eight bits of byte 2 in MSPDR
19f. TRANSMITTING THE NEXT BYTE ONTO THE BUS In ST 15, Link 22a clears the SPI-XFR holding register in STATEOUT 70a due to the completion of the SPI-XFR. Assuming BYTE 2 does not represent the LAST BYTE and MCU 18a has indicated another BYT RDY (BYTE 3), MSTATE 48a moves to ST17, the normal transmitting path.
In ST17, the bits of BYTE 2 are transmitted over bus 12. BYT RDY holding register in STATEIN 27a is cleared, and the LAST BYTE shift register is shifted. The shifting of the LAST BYTE is necessary because its status is associated with the data byte that was most recently shifted in from MCU 18a. Upon completion of the message, a cycle redundancy check (CRC) of the transmitted characters is performed (ST15, 19, 20, 21, 10) . After the (CRC), an end of frame (EOF) occurs (ST10, 23, 24).
TIMING WITHIN LINK
As noted in Fig. 2, SED 23 provides clock signals for the node. An OSC signal from MCU 18 provides a source of continuous and accurate clock signals used for clocking system operations.
THE CL K SIGNAL.
After dividing OSC into OSCDIV2 and 0SCDIV4, a multiplexer (MUX) circuit (not shown) extracts from the two pulse trains a first clock signal (CLK) of Fig. 6A of a chosen frequency, e.g., 2 MHz and the inverse clock signal (CLKL) .
THE CLKDIV2 SIGNAL
Within SED 23, a sequential logic divide by two () circuit converts, illustratively, the 2 MHz CLK signal to a 1 MHz CLKDIV2 signal of Fig. 6B that routes to various sequential logic circuits of Link 22. CLKDIV2 signals control the transfer of input signals into Link 22 and the changing of the states. Note in Fig. 9A, the rising edge of the CLKDIV2 signal clocks memory 33b.
THE INTCLK SIGNAL
A combinational logic circuit converts CLKDIV2 to a 1 MHz INTCLK signal of FIG. 6C offset from CLKDXV2 by a 1/4 cycle. The INTCLK signal clocks the setting of flags and other output signals from Link 22 including SO-0 through so-33. (See Fig. 9A). INTCLK combines with other control signals to create additional control signals such as SPICLK that occur at the same time as INTCLK.
THE STENH SIGNAL
Another delay circuit converts the INTCLK βignal into a 1/4 cycle pulse occurring in the last 1/4 of the INTCLK cycle. The STENH signal, Fig. 6D, provides the clock signal for gating the state output signals.
THE OPERATTON OF THE SYSTEM
To describe the operation of the system when transferring data bytes, refer to Fig. 7 through Fig. 10B. In Fig. 9A, a sensor 14 supplies variable
measurand information such as pressure, rate of flow, speed etc. in digital form to MCU 18. MCU 18,
illustratively, which could be a microcontroller such as the M68HCO5 of Motorola or an equivalent, converts the digital bits from sensor 14 into message frames:. J1850 messages require a protocol symbol (SOF) to precede a header byte and one or two protocol symbols (EOD and EOF) to follow the cyclic redundancy check (CRC) bytes in a message frame. The manner this MCU/Link system deals with protocol symbols is
explained in the copending application mentioned supra.
With reference to Fig. 7, Fig. 7A shows the sequence of numbers of the state machine flow diagram of Fig. 8 in an effort to coordinate the operation of the system. Fig. 7B shows an idle condition of bus 12 and that bus 12 has been idle for some period of time before MCU 18 initiates a transmission. This means that when bus 12 became idle, MCU 18 did not have a message queued up for transmission.
Solicited Transfer: SPI-XFR Initiated by MCU
When MCU 18 obtains a message for transmission, MCU 18 attempts to perform a solicited transfer. Such a transfer occurs when MCU 18 transmits an initial message byte, usually the header byte. MCU 18 enters a transmitting mode by not setting the serial peripheral interface status flag (SPIF) in Fig. 10A of the serial peripheral status register (SPSR) or as a result of a reset of the system. MCU 18 asserts the BYT RDY pin to start the transmission of a message.
After the solicited transfer, SPIF gets set automatically by MCU hardware. Then unsolicited transfers occur for all subsequent transfers between Link 22 and MCU 18.
Figs. 10A and 10B illustrate in flowchart form, the software operations in MCU 18 used to communicate with link 22. These charts represent an effort to organize the generation and flow of signals through MCU 18. These flowcharts differ from the conventional box and diamond flowcharts.
In these charts, signals entering and leaving the flow of control pass along lines and proceed down the page. Conventional start of program and end of program are used. Trapezoidal or rectangularly shaped boxes indicate signals entering and leaving the flow of control. Actions are signified by a small black circle on the lines, the description of the action being given to the left or right of the flow lines. When
introducing a decision, the flow line branches to the right or left. A branch may be caused by either a YES or NO condition, with these being signified by a Y or N in a small box as indicated. An arrowhead depicts where secondary flow rejoins the main flow. A
reference number indicates the position or step along the line being discussed.
Returning now to the solicited transfer, note in Fig. 10A, this firmware program requires MCU 18 to determine the status of SPΣF. Assuming a set SPIF, MCU 18 then must determine the status of bus 12. Link 22 provides an idle bus status signal to MCU 18. For an idle bus 12, CPU 19a receives instructions to determine the status of the input capture flag (ICF). A set ICF signal means an idle bus has occurred since the last time MCU 18 inspected bus 12, i.e., there is an
outstanding unprocessed idle signal. For example, MCU 18 was receiving a message, for which the transmission has finished. MCU 18 must process the received message before starting the transmission, due to time
considerations. Assuming no ICF, then CPU 19a
determines whether the XMTNUM RAM counter, used to count the number of bytes in the transmit buffer
(XMTBUF), has a non-zero value. Using the message depicted in Fig. 7C, illustratively, XMTNUM equals 3. Assuming an idle bus 12, and CPU 19a learns the
availability of a message, then CPU 19a sets the
XMITMODE flag. (See steps 200-209 of Fig. 10A).
An event (internal or external to MCU 181 causes CPU 19a to generate a message frame for transmission over bus 12. An application layer subroutine formats the message frame and stores the bytes in XMTBUF.
XMTNUM gets set to the number of bytes that MCU 18 will transmit.
In this configuration, CPU 19a fills XMTBUF
(usually an 11 byte buffer) backwards, as shown in
Fig. 10C, so that the first byte to send gets stored as XMTBUF, XMTNUM-1 or XMTBUF, 2; the second byte stored as XMTBUF, XMTNUM-2 or XMTBUF, 1; and the third byte stored as XMTBUF, XMTNUM-3 or XMTBUF, 0.
After establishing XMTNUM-3, with bus 12 idle, CPU 19a sets XMTNDXBXMTNUM, illustratively to 3 and
ARBNDX=XMTNUM or 3. ARBNDX is an index into XMTBUF that points to the next byte coming back from bus 12. (See steps 210-212).
At step 214, CPU 19a receives instructions to load
XMTNDX-1 or the data in XMTBUF, 2 into the SPI data register (SPDR) 19f. Then at step 216, CPU 19a sets BYT RDY pin HI. This informs link 22 of a byte ready for transmission. (See Fig. 7G, index #1).
CPU 19a then sets XMTNDX equal to XMTNDX-1 or in this illustration to 2. CPU 19a receives instructions to determine if the SPI-XFR between MCU 18 and Link 22 has been completed. (See Fig. 10A, step 219) . Usually, this transfer consumes about 11 μs well within the first 400 μs polling cycle. The byte that was stored in the LSPDR 28, which is unusable, comes into the MSPDR 19f of MCU 18.
After completion of the transfer, the hardware in MCU 18 automatically clears the SPIF bit in the SPI Status Register, (SPSR) (not shown). Then CPU 19a receives instructions to load the byte received from the LSPDR 28 into a non-volatile MCU register. This completes the solicited transfer. MCU 18 does not care about the initial byte that comes back into the MSPDR from Link 22. (See steps 220-221). If XMTNDX does not equal zero, CPU 19a sets BYT RDY pin LO. This means that there are more bytes to transmit, if there are more bytes to transmit, then CPU 19a loads the second byte to be transmitted in the MSPDR 19f by writing over the returned initial byte and then setting BYT RDY pin HI a second time. (See steps 222-224) . The rising edge of the second short BYT RDY pulse must occur at least 2.1 μs after the falling edge of the last SPISCK pulse of the SPI-XFR. (See the waveforms in Fig. 7D and 7F) . When the SOF symbol ends, Link 22 begins transmitting the first byte onto bus 12. CPU 19a then sets XMTNDX equal to XMTNDX-1. XMTNDX is now 1. If XMTNDX is not equal to zero, then CPU 19a sets BYT RDY pin LOW. CPU 19a then exits the. solicited transfer routine. (See steps 226-229).
MCU RECEIPT OF AN UNSOLICITED BYTE BY SPT XFR and SPI XFR OF 2ND BYTE
After loading byte 1 on bus 12, IDR 20 and Link 22 reflect byte 1 (received off bus 12) back to MCU 18 via an unsolicited transfer. (See Fig. 7G, index #3).
In Fig. 10A, during another 400 μs polling cycle, at step 200, CPU 19a determines if SPIF is set. This serial peripheral transfer flag notifies MCU 18 that the solicited data transfer between MCU 18 and Link 22 has been completed. Hence the program branches to the unsolicited transfer program on Fig. 10B.
ARBTTRATTON CHECKED
At the same time MCU 18 receives back the
unsolicited byte 1, Link 22 receives byte 2 (if any) from MCU 18 via the SPI-XFR. During the time Link 22 was attempting to transmit byte 1, Link 22 could ave lost arbitration to another transmitting node. If so, the byte it was attempting to transmit is not the byte that ends up being transmitted on bus 12. MCU 18 checks each byte it receives back from Link 22 against the byte it attempted to transmit. If byte 1 does not match, MCU 18 switches to a receive operation. If the first byte received back matches but subsequent bytes do not, MCU 18 assumes an error has occurred. This is due to the fact that this system utilizes a single-byte header and arbitration should be resolved with the first byte. If the second or subsequent bytes do not match, MCU 18 terminates transmission of the message and waits for the next idle bus period.
PERFORMANCE OF THE UNSOL ICTTED TRANSFER
In Fig. 10B, after the SPIF bit goes to a logic 1, MCU 18 receives instructions to clear BYT RDY and then to determine if XMITMODE flag is set. Since node 1 is transmitting, the program branches to the next
instruction which requires determining if ARBNDX is equal to zero. If so, then the program exits but, illustratively, since ARBNDX was previously set to 3,
CPU 19a reacts to the next instruction of accessing the SPI STATUS REGISTER (SPSR). Then CPU 19a receives the instruction to load the data byte read from bus 12 into a nonvolatile MCU register (not shown). This action also clears the SPIF bit.
Then CPU 19a determines if the byte received from bus 12 equals the byte transmitted. If so, CPU 19a updates the ARBNDX by setting it to [3-1] or 2. (See steps 230-240).
TRANSFER OF THE TAST BYTE
CPU 19a receives instructions to determine if XMTNDX equals zero. Since XMTNDX does not, CPU 19a executes the next instruction to place the last byte in the SPDR (XMTNDX-1) . Then CPU 19a receives the instruction to set the BYT RDY pin HI. Leaving the BYT RDY pin HI indicates that the byte in the MSPDR is the last byte to be transmitted. CPU 19a then moves to execute the instruction to update the XMTNDX before existing the program. XMTNDX now becomes zero.
Illustratively, CPU 19a loads the last byte into MSPDR 19f and asserts the BYT RDY pin HI. BYT RDY pin remains HI through the next unsolicited transfer. This is referred to as the long form of BYT RDY. This tells Link 22 that the byte sitting in MSPDR I9f is the last byte to transmit. As with the short BYT RDY pulse, the rising edge of a long BYT RDY must occur at least 2.1 μs after the falling edge of the last SCK pulse of the SPI XFR. During the unsolicited transfer (Fig. 7G, index #4), MCU 18 receives BYTE 2, while Link 22 receives byte 3. Following the transfer, MCU 18 returns the BYT RDY pin LO.
Illustratively, two more unsolicited transfers must occur, namely an unsolicited transfer for the third byte and one for the CRC byte. For each of these two unsolicited transfers, XMTNDX equals zero. So no more bytes are sent to Link 22 for transmission. After each unsolicited transfer, CPU 19a must check the byte received against XMTBUF, ARBNDX-1 and decrement ARBNDX afterwards. LINK A UTOMATICA LLY TRANSMITS A CRC
Following the transmission of byte 3, unsolicited transfer (Fig. 7G, index≠ 5) sends byte 3 to MCU 18. Then MCU 18 exits the Unsolicited program. Link 22 automatically transmits the proper CRC byte on to bus 12. Unsolicited transfer (index≠ 6) sends the CRC to MCU 18. During the unsolicited transfer for the CRC, ARBNDX equals 0, so MCU 18 does not participate in this transfer. The idle pin returns to LO (index # 7) indicating bus 12 is once again idle. This causes an interrupt to MCU 18.
Since other modifications and changes varied to fit particular operating requirements and environments will be apparent to those skilled in the art, the invention is not considered limited to the example chosen for purposes of disclosure, and covers all changes and modifications which do not constitute departures from the true spirit and scope of this invention.

Claims

What is claimed is:
1. A link apparatus containing a circuit for interchanging data bytes using a serial peripheral interface (SPI) circuit of a microcontroller (MCU) at a chosen clock rate to accomplish loading a series of data bytes from the MCU into the link apparatus and unloading another series of data bytes from the link apparatus into the MCU substantially simultaneously and then for transferring each bit of the loaded byte onto a single-wire communications bus (bus) as J1850 data symbols at the chosen clock rate but delayed in proportion to a variation in length of the variable pulse width of each symbol, the link apparatus being contained in a node of a multiple node vehicle
communications network and having output terminals connected to the bus, the bus and the J1850 symbols being prescribed for use in an automobile industrial standard for data communications network interfaces, each node also having the MCU connected between an external input device and input terminals of the link apparatus for receiving a chosen measurand from the input device and then translating the measurand into digital byte messages in response to changes of the measurand and for cooperating with the link apparatus to affect the SPI transfers, the link apparatus also containing a symbol encoder/decoder (SED) for receiving the bits of the bytes loaded from the MCU and then formatting each bit of the bytes into a symmetrical, variable pulse width modulated (VPWM) signal, the VPWM signal being routed from the link apparatus to an integrated driver/receiver (IDR) circuit that connects to the bus, the IDR containing a transmitter circuit for converting each VPWM signal into a trapezoidal shaped waveform analog signal (symbol) containing information expressing a magnitude value of the digital bit component of the byte message being communicated so that other nodes on the bus night use the communicated information, the IDR also containing a receiver circuit for reflecting each symbol placed on the bus and reconverting the symbol into a restructured VPWM bit, the restructured bit being routed back, to the link device where the VPWM bit is converted by the SED into a digital data bit and then a series of the digital data bits are reassembled as a data byte in a data register of the link and then unloaded into the MCD via another SPI-XFR providing arbitration and status information to the MCU regarding the placement of the data message on the communications bus, the link apparatus comprising:
A) λ state machine device for establishing a series of operating states for the node comprising:
1) a statein unit having a plurality of synchronous and asynchronous holding registers;
2) a main state machine unit having:
a) a next state decoder at an input port,
b) a memory circuit composed of a parallel arrangement of a plurality of flip-flops having input terminals connected to the output of next state decoder,
c) an output decoder having input terminals connected to the output of the memory circuit, and
d) synchronized output gates having input terminals connected to the output of the memory circuit and output terminals of the statein unit for providing synchronous output state signals within the link apparatus;
the state machine device being used to monitor output signals from the SED that provide information concerning the status of and the symbols on the bus and to provide a SPI transfer clock and handshaking signals to the MCU, the state machine device alβo determining vhen the bus is idle and in a condition to receive a new message and to respond to handshaking signals from the MCU indicating that the MCϋ has converted measurand information into data bytes;
&} a stateout unit having input terminals connected to output terminals of the state machine device and the statein unit for providing control signals within the link apparatus and to the MCU;
C) a link apparatus SPI data register (LSPDR) circuit having an input connected to receive each data bit of the byte transferred from a MCU SPI data register (MSPDR) during a SPI transfer operation of the MCU;
D) an encoder circuit for accepting a signal from the state machine device during a particular state and then automatically generating a coded address that routes to the SED for generating a VPWM signal that routes to the transmitter circuit of the IDR for placing a start of frame (SOT) protocol symbol on the bus during a chosen state of the state machine device and for accepting data bits from the LSPDR in response to handshaking signals from the state machine device and control signals of SED in order to initiate the loading of data symbols on the bus after the protocol symbol SOF has been communicated over the bus;
E) a firmware program stored in a ROM of the MCU that instructs a CPU to perform a solicited transfer of data bytes in a message frame and for responding to unsolicited transfers of data bytes interchanged with the link apparatus; and
F) a vector device connected to the SED and the main state machine device containing circuits for determining arbitration of the SOF protocol symbol with respect to other SOF protocol symbols that might appear on the bus nearly simultaneously, the vector device providing an error signal that resets the state machine device to an initial state if another protocol symbol from another node appears on the bus prior to a transmitting node.
2. The link apparatus of claim 1 wherein the SED receives a reference clock signal (CLK) from the MCU ai-d divides that signal in half forming a SED reference clock signal (CLKDIV2) , wherein the SED provides a circuit that offsets CLKDIV2 by 1/4 of a cycle to form an INTCLK signal (INTCLK) and a SPI clock signal
(SPISCK) , wherein INTCLK is used to synchronize the output gates of the main state machine unit and SPICLK is used by the MCU to clock the SPI transfers, wherein SED provides a circuit combining CLKDIV2 and INTCLK to form a pulse 1/2 the frequency of CLK called STENH.
3. The link apparatus of claim 1 wherein the statein unit includes circuits that combines certain output signals of the meanory unit of the main state machine unit with INTCLK forming a shift clock (SHCLK) signal that clocks the LSPDR during unloading bits during a SPI transfer.
4. The link apparatus of claim 3 wherein an analog-to digital converter circuit within the MCU receives measurands from the input device and converts the variations of the measurands into a series of digital byte messages, wherein the CPU polls the firmware to determine whether the state machine device has provided a hand shakinq signal to the MCU informing the MCU of the condition of the bus, wherein if the bus is idle, and the MCU has a byte ready to include in a message, then the CPU, during a polling cycle of the firmware asserts a short: BYT ROY handshaking signal to the link apparatus to inform the link apparatus that a byte is ready.
5. The link apparatus of claim 4 wherein the MCU initiates a solicited SPI transfer (SPI-XFR), wherein the MCU exchanges a header byte from the MSPDR with an unknown byte from the LSPDR, wherein SPICLK clocks the SPI- XFR.
6. The link apparatus of claim 5 wherein after the occurrence of the SPI-XFR, the link apparatus automatically prepends a start-of-frame (SOF) protocol symbol on the bus, wherein after determining that the SOF symbol won arbitration using the vector circuit, the link apparatus unloads each bit of the header byte as a VPWM bit to the IDR clocked by the SHCLK, wherein the IDR changes the VPWM into J1850 symbols.
7. The link apparatus of claim 6 wherein each reflected bit from the IDR is checked to determined if arbitration occurs with any bit on the bus from a competing node, wherein each arbitrated bit is
restructured into a byte and stored in the LSPDR for an unsolicited transfer exchange with the next data byte stored in the MSPDR, wherein the MCU conducts
unsolicited SPI-XFRs with all succeeding bytes until the last byte is loaded in the MSPDR.
8. The link apparatus of claim 7 wherein the firmware program in the MCU instructs the CPU to assert a long BYT RDY handshaking signal to the link apparatus if the last byte is loaded into the MSPDR and wherein if any of the data bytes after the header byte do not match during arbitration, MCO asserts a NXT control bit and waits for the next idle handshake signal from the link apparatus.
PCT/US1995/016246 1994-12-16 1995-12-15 Communications network, a dual mode data transfer system therefor WO1996019058A1 (en)

Priority Applications (4)

Application Number Priority Date Filing Date Title
AU44699/96A AU4469996A (en) 1994-12-16 1995-12-15 Communications network, a dual mode data transfer system therefor
EP95943428A EP0797881B1 (en) 1994-12-16 1995-12-15 Communications network, a dual mode data transfer system therefor
AT95943428T ATE196045T1 (en) 1994-12-16 1995-12-15 COMMUNICATION NETWORK WITH DUAL MODE DATA TRANSFER SYSTEM
DE69518665T DE69518665T2 (en) 1994-12-16 1995-12-15 COMMUNICATION NETWORK WITH DOUBLE-MODE DATA TRANSFER SYSTEM

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
US357,002 1994-12-16
US08/357,002 US5579299A (en) 1994-12-16 1994-12-16 Communications network, a dual mode data transfer system therefor

Publications (2)

Publication Number Publication Date
WO1996019058A1 true WO1996019058A1 (en) 1996-06-20
WO1996019058A9 WO1996019058A9 (en) 1996-09-12

Family

ID=23403891

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/US1995/016246 WO1996019058A1 (en) 1994-12-16 1995-12-15 Communications network, a dual mode data transfer system therefor

Country Status (6)

Country Link
US (1) US5579299A (en)
EP (1) EP0797881B1 (en)
AT (1) ATE196045T1 (en)
AU (1) AU4469996A (en)
DE (1) DE69518665T2 (en)
WO (1) WO1996019058A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1553731A3 (en) * 2004-01-07 2007-09-05 Hitachi, Ltd. Data communication system and controller

Families Citing this family (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH1032883A (en) * 1996-07-16 1998-02-03 Alps Electric Co Ltd Multiplex communication device for vehicle
US5850556A (en) * 1996-12-26 1998-12-15 Cypress Semiconductor Corp. Interruptible state machine
US6691183B1 (en) * 1998-05-20 2004-02-10 Invensys Systems, Inc. Second transfer logic causing a first transfer logic to check a data ready bit prior to each of multibit transfer of a continous transfer operation
US6275167B1 (en) 1998-06-08 2001-08-14 Visteon Global Technologies, Inc. Method and system for communicating between remote-controlled modules in automotive vehicles
JP3916024B2 (en) * 1998-08-05 2007-05-16 本田技研工業株式会社 Data destruction prevention method in multiplex communication device
CA2280571A1 (en) * 1998-11-30 2000-05-30 Daimlerchrysler Corporation J1850 application specific integrated circuit (asic) and messaging technique
US6460096B1 (en) 1999-08-25 2002-10-01 Daimlerchrysler Corporation Automatic serial bus transmission sequencer
US7519005B2 (en) * 2002-05-08 2009-04-14 Semtech Corp. Single-wire communication bus for miniature low-power systems
DE102004013629B4 (en) 2004-03-19 2023-06-01 Volkswagen Ag Communication system for a motor vehicle
US7660685B2 (en) * 2006-08-02 2010-02-09 Lecroy Corporation Virtual probing
US7809872B2 (en) * 2007-12-14 2010-10-05 Infineon Technologies Ag Master and slave device for communicating on a communication link with limited resource
US7921231B2 (en) 2008-01-04 2011-04-05 Silicon Image, Inc. Discovery of electronic devices utilizing a control bus
US7856520B2 (en) * 2008-01-04 2010-12-21 Silicon Image, Inc. Control bus for connection of electronic devices
US8090030B2 (en) * 2008-01-04 2012-01-03 Silicon Image, Inc. Method, apparatus and system for generating and facilitating mobile high-definition multimedia interface
DE102009044936B4 (en) * 2009-09-24 2022-10-13 Robert Bosch Gmbh Procedure for exchanging data
US10768211B2 (en) 2017-08-25 2020-09-08 Oracle International Corporation System and method for current sense resistor compensation

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0246666A2 (en) * 1986-05-22 1987-11-25 Chrysler Corporation Serial data bus for different modes of operation (SCI, SPI and buffered SPI) and methods for a serial peripheral interface in a serial data bus
US5274636A (en) * 1992-04-20 1993-12-28 Chrysler Corporation Automatic multiplex data link system, symbol encoder decoder therefor

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
DE3103884A1 (en) * 1981-02-05 1982-09-02 Robert Bosch Gmbh, 7000 Stuttgart REMOTE CONTROL SYSTEM FOR SELECTIVE CONTROL OF CONSUMERS
JPS6184138A (en) * 1984-10-01 1986-04-28 Nissan Motor Co Ltd Network system
US4715031A (en) * 1985-09-23 1987-12-22 Ford Motor Company Vehicular data transfer communication system
JPH0771088B2 (en) * 1987-04-06 1995-07-31 古河電気工業株式会社 Multiplex transmission system
US5287523A (en) * 1990-10-09 1994-02-15 Motorola, Inc. Method for servicing a peripheral interrupt request in a microcontroller
JP2839054B2 (en) * 1991-08-12 1998-12-16 株式会社デンソー Communication device
WO1993022857A1 (en) * 1992-05-04 1993-11-11 Ford Motor Company Limited Slave bus controller circuit for class a motor vehicle data communications
US5337042A (en) * 1992-09-28 1994-08-09 Chrysler Corporation Vehicle communications network transceiver, transmitter circuit therefor
US5363405A (en) * 1992-11-27 1994-11-08 Chrysler Corporation Vehicle communications network transceiver, bus driver therefor

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0246666A2 (en) * 1986-05-22 1987-11-25 Chrysler Corporation Serial data bus for different modes of operation (SCI, SPI and buffered SPI) and methods for a serial peripheral interface in a serial data bus
US5274636A (en) * 1992-04-20 1993-12-28 Chrysler Corporation Automatic multiplex data link system, symbol encoder decoder therefor

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
"CLASS INTRODUCTION TO MEDIUM-SPEED MULTIPLEXING", AUTOMOTIVE ENGINEERING, vol. 100, no. 9, 1 September 1992 (1992-09-01), pages 37 - 40, XP000310446 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1553731A3 (en) * 2004-01-07 2007-09-05 Hitachi, Ltd. Data communication system and controller

Also Published As

Publication number Publication date
DE69518665D1 (en) 2000-10-05
ATE196045T1 (en) 2000-09-15
EP0797881B1 (en) 2000-08-30
US5579299A (en) 1996-11-26
AU4469996A (en) 1996-07-03
DE69518665T2 (en) 2001-05-03
EP0797881A1 (en) 1997-10-01

Similar Documents

Publication Publication Date Title
US5579299A (en) Communications network, a dual mode data transfer system therefor
WO1996019058A9 (en) Communications network, a dual mode data transfer system therefor
US5495469A (en) Communications network, state machine therefor
US6049837A (en) Programmable output interface for lower level open system interconnection architecture
US6266710B1 (en) Serial data transfer device
JPS5951186B2 (en) Control device
US6385319B1 (en) Encoding circuit and method of detecting block code boundary and establishing synchronization between scrambler and descrambler
KR0156921B1 (en) A process and a monolithically integrated device for speed adaptation for integrated services digital network
US6215817B1 (en) Serial interface device
JPS62122432A (en) Error check system in serial data transfer
EP1063596A2 (en) Circuit and method for reliably performing bus reset regardless of cable length
US4720828A (en) I/o handler
JP3459075B2 (en) Synchronous serial bus method
JPH02502780A (en) Method and apparatus for detecting impending overflow and/or underrun in a mutable buffer
EP0725352B1 (en) Communication system and relay thereof
JPH0142177B2 (en)
US5661736A (en) Multiple use timer and method for pulse width generation, echo failure detection, and receive pulse width measurement
WO1997041700A1 (en) Signal concentrator for connection between cellular telephone and associated accessories
JPS58133066A (en) Multiplexing method of loop communication system
JPH0614649B2 (en) Terminal adapter having multiple HDLC communication channel receiver
JP2623816B2 (en) Signal transmission method
JPH03258132A (en) Communication terminal equipment
JPH09114776A (en) Data transmission system
JP3456009B2 (en) Communication method
US7388880B2 (en) Data transmission method, transmission circuit, and communication device

Legal Events

Date Code Title Description
AK Designated states

Kind code of ref document: A1

Designated state(s): AL AM AT AU BB BG BR BY CA CH CN CZ DE DK EE ES FI GB GE HU IS JP KE KG KP KR KZ LK LR LS LT LU LV MD MG MK MN MW MX NO NZ PL PT RO RU SD SE SG SI SK TJ TM TT UA UG UZ VN

AL Designated countries for regional patents

Kind code of ref document: A1

Designated state(s): KE LS MW SD SZ UG AT BE CH DE DK ES FR GB GR IE IT LU MC NL PT SE BF BJ CF CG CI CM GA GN ML MR NE SN TD TG

DFPE Request for preliminary examination filed prior to expiration of 19th month from priority date (pct application filed before 20040101)
COP Corrected version of pamphlet

Free format text: PAGES 1-18,DESCRIPTION,REPLACED BY NEW PAGES 1-16;PAGES 19-24,CLAIMS,REPLACED BY NEW PAGES 17-21,AND PAGES 1/12-12/12,DRAWINGS,REPLACED BY NEW PAGES 1/11-11/11;DUE TO LATE TRANSMITTAL BY THE RECEIVING OFFICE

121 Ep: the epo has been informed by wipo that ep was designated in this application
WWE Wipo information: entry into national phase

Ref document number: 1995943428

Country of ref document: EP

WWP Wipo information: published in national office

Ref document number: 1995943428

Country of ref document: EP

REG Reference to national code

Ref country code: DE

Ref legal event code: 8642

WWG Wipo information: grant in national office

Ref document number: 1995943428

Country of ref document: EP