1 / 38

NASA/BAE SYSTEMS SpaceWire Efforts MAPLD 2003 September 9-11, 2003

SpaceWire. NASA/BAE SYSTEMS SpaceWire Efforts MAPLD 2003 September 9-11, 2003. Agenda. Background/Overview Verification Overview (description of environment) Tests Directed (matrix of test vs. standard requirement) Random Bug reports & Status Transport Layer FPGA Target Information

zanna
Télécharger la présentation

NASA/BAE SYSTEMS SpaceWire Efforts MAPLD 2003 September 9-11, 2003

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. SpaceWire NASA/BAE SYSTEMS SpaceWire EffortsMAPLD 2003September 9-11, 2003

  2. Agenda • Background/Overview • Verification • Overview (description of environment) • Tests • Directed (matrix of test vs. standard requirement) • Random • Bug reports & Status • Transport Layer • FPGA Target Information • BAE ASIC

  3. What Is SpaceWire? • ESA standard (ECSS-E-50-12A) • http://www.estec.esa.nl/tech/spacewire/ • High-speed point-to-point links • Scalable to create switched fabric using wormhole routing • Utilizes flow control to prevent data loss • Error detection and recovery • Simple hardware interface

  4. Space Wire/CCSDS Protocol Levels * OSI TCP/IP CCSDS Application CCSDS Application Application Presentation Session Transport TCP Transport Space Wire Levels Network IP Network Packet Network Data Link Data Link Exchange Host-to-Network Character Physical Physical Signal Physical * Slide from “SpaceWire Retry Mechanism”, Author: Steve Parks, Space Systems aaResearch Group, University of Dundee.

  5. Applications • Spacecraft high-speed data bus • High-reliable avionics command bus (with addition of SpaceWire transport layer*) • Clusters • Distributed systems • May be used similiar to “Myrinet”

  6. NASA IP Core • Link design – used for point-to-point applications • Router design – used for switched fabric applications • Exceptions to SpaceWire standard • Group Adaptive Routing • Interval labelling • User specific command format and error detection for Configuration Port • All designs are written in RTL VHDL for portability • All designs are extensively verified using directed and random testing to the standard

  7. NASA SpaceWire Missions • Swift BAT • JWST • GOES • SIM

  8. Router Functional Block Diagram

  9. IP Core User Interface • User role • Define “payload” packet format – packet generator (Application Specific) • Interpret receive packet – packet interpreter or decoder (Application Specific) • Sync Pulse for timing coordination (Application Specific) • Control may be hardwired in SpaceWire Core for many applications • SpaceWire Core • Handle all protocol functions • Provide simple transparent interface to User User SpaceWire Core Packet Generator 10 Packet Interpreter 10 DS Link TickIn Sync Pulse Time Code TickOut Time Master Control/Status Control

  10. Transmit Good Packet – User View User Interface SpaceWire Core 10 Packet to transmit AA (hex) - 1010 1010 BB (hex) - 1011 1011 CC (hex) - 1100 1100 DD (hex) - 1011 1011 EE (hex) - 1100 1100 FF (hex) - 1111 1111 FIFO Encoding 0AA (hex) - 00 1010 1010 0BB (hex) - 00 1011 1011 0CC (hex) - 00 1100 1100 0DD (hex) - 00 1011 1011 0EE (hex) - 00 1100 1100 1FF (hex) - 01 1111 1111 Data Byte eop type eop marker

  11. User I/F Error During Packet Transmission User Transmit View • User interface could terminate the partial packet with a error-end-of-packet (eep) marker and align on new packet boundary (consume remainder of packet) • Transparent to SpaceWire Core • * Recommended User Interface SpaceWire Core ERROR - Occurs in User Only 10 DS Link Packet to transmit AA (hex) - 1010 1010 BB (hex) - 1011 1011 CC (hex) - 1100 1100 DD (hex) - 1011 1011 EE (hex) - 1100 1100 FF (hex) - 1111 1111 Next Packet 55 (hex) – 0101 0101 66 (hex) – 0110 0110 FIFO Encoding 0AA (hex) - 00 1010 1010 0BB (hex) - 00 1011 1011 0CC (hex) - 00 1100 1100 3DD (hex) - 11 1011 1011 055 (hex) - 00 0101 0101 166 (hex) - 01 0110 0110 ERROR Data Byte eop type eop marker

  12. Link Error – User Transmit View • When a link goes down due to an error (parity,escape,credit,disconnect) the user does not take any action • Transparent to user • User continues to write packets to SpaceWire as if nothing has happened • SpaceWire will take care of consuming partial packet and start with beginning of new packet SpaceWire Core User Interface 10 DS Link Packet to transmit AA (hex) - 1010 1010 BB (hex) - 1011 1011 CC (hex) - 1100 1100 DD (hex) - 1011 1011 EE (hex) - 1100 1100 FF (hex) - 1111 1111 Next Packet 55 (hex) – 0101 0101 66 (hex) – 0110 0110 FIFO Encoding 0AA (hex) - 00 1010 1010 0BB (hex) - 00 1011 1011 0CC (hex) - 00 1100 1100 0DD (hex) - 00 1011 1011 0EE (hex) - 00 1100 1100 0FF (hex) - 01 1111 1111 055 (hex) - 00 0101 0101 166 (hex) - 01 0110 0110 SpaceWire core inserts Error-Packet-Marker (EEP) after this byte ERROR SpaceWire core consumes partial packet eop type eop marker Data Byte

  13. Receive Packet – User View User Interface SpaceWire Core 10 Packet to Receive Reset 1st Packet AA (hex) - 1010 1010 BB (hex) - 1011 1011 CC (hex) - 1100 1100 2nd Packet DD (hex) - 1011 1011 EE (hex) - 1100 1100 FF (hex) - 1111 1111 . . FIFO Encoding Link Initialization 0AA (hex) - 00 1010 1010 0BB (hex) - 00 1011 1011 0CC (hex) - 01 1100 1100 0DD (hex) - 00 1011 1011 0EE (hex) - 00 1100 1100 1FF (hex) - 11 1111 1111 Good Packet Bad Packet Note: eop type bit set either by receive link due to link error or by user on transmit side Data Byte eop type eop marker

  14. SpaceWire Verification Effort Omar Haddad Digital Verification Engineer, QSS

  15. Generate Packet C code VHDL Control Flow Data Signal Interrupt Signal Interrupt signal and backdoor bus Back door bus DUT SpaceWire Link User I/F BFM SpaceWire BFM CLKRST BFM Packet Scoreboard C-VHDL Gasket Test Bench Interface BFM ISR Check Packet test.c Verification Environment Link Block Diagram • SpaceWire IP Core - RTL in synthesizable VHDL • Skinny (smaller, slower) • Deluxe (larger, faster) • Bus Functional Models (BFM) in behavioral VHDL • SpaceWire BFM written independently of RTL for interoperability • C-VHDL gasket • Developed in-house • Process running the C test runs parallel to a process running VHDL simulator • C is more powerful than VHDL and runs simulations faster • Tests written in C • 14 Directed • 1 Random • Self-Checking (no visual verification required) Verification

  16. Check Packet Generate Packet C code VHDL Data Signal Interrupt Signal Back door bus Control Flow Interrupt signal and backdoor bus SpaceWire BFM SpaceWire BFM User I/F BFM DUT (Router) SpaceWire BFM Packet Scoreboard CLKRST BFM SpaceWire BFM C-VHDL Gasket Test Bench Interface BFM ISR test.c Verification Environment Router Block Diagram • RTL in synthesizable VHDL • Bus Functional Models (BFM) in behavioral VHDL • SpaceWire BFM written independently of RTL for interoperability • C-VHDL gasket • Developed in-house • Process running the C test runs parallel to a process running VHDL simulator • C is more powerful than VHDL and runs simulations faster • Tests written in C • 26 Directed • 2 Random • Self-Checking (no visual verification required) Verification

  17. Generate Packet C code VHDL Hub 0 Hub 1 Hub 2 Data Signal Interrupt Signal Back door bus Control Flow Interrupt signal and backdoor bus 2 E 1 A 3 D 1 4 3 2 2 B CLKRST BFM Test Bench Interface BFM Packet Scoreboard C-VHDL Gasket CLKRST BFM CLKRST BFM 3 C 1 User I/F BFM DUT Router Check Packet ISR test.c User I/F BFM User I/F BFM DUT Router DUT Router Verification Environment Network Block Diagram Verification

  18. Pick random seed Use seed to randomize parameters Transfer all packets Store seed and log file if test failed Does ‘stop’ file exist? no yes exit Random Test • Used to exercise corner-case situations that are hard to think of • Runs through an infinite loop • Randomizable Parameters • Constraints • Over 5000 loop iterations run so far • Seeds that exposed bugs are converted to directed tests • Perl script used to run infinitely • Test can be given a seed to replicate and debug a bug BACK-UP Verification

  19. NULL NULL NULL NULL Time Code RTL Bug Found By sswr_rand seed=39540 Verification • Router receives a time code from the external port while port 2 is initializing • Proper initialization protocol: Send NULL, then send FCTs, then move to RUN state, then time codes may be sent • Port 2’s transmitter block receives the command to transmit a time code and an FCT at the same time. • Port 2 is erroneously registered as being in the RUN state • Since time code characters have higher priority than FCTs, the time code is transmitted before the FCT which violates the initialization protocol

  20. SpaceWire Standard Feature Coverage Matrix Verification BACK-UP

  21. SpaceWire Standard Feature Coverage Matrix Verification BACK-UP

  22. SpaceWire Standard Feature Coverage Matrix Verification BACK-UP

  23. Design Integrity • Regression list • All directed tests • All random test with seed that previously exposed an RTL bug • Random test for 12 hours • Regression testing is used whenever the RTL/Test Bench is modified • Feature is added • Any bug is fixed • Regression testing is run during various phases of the design • Functional RTL • Synthesized design (gate level) • Placed and routed design (gate level with SDF delays) Verification

  24. Bug Reporting • Maintained in a shared MS Excel spreadsheet • 15 Router RTL bugs found and fixed during verification phase • 35 Link RTL bugs found and fixed during verification phase • Bug Report Fields • Bug number • Submit date • Submitter – Person who found bug • Owner – Person responsible for fixing bug • Block – IP core • Category – RTL, specification, test, BFM, tools script • Problem Description • Status – Broken, Fixed, In progress, Patched • Severity – High priority, Low priority, Minor • Resolution – description of fix • Date Fixed • Good practice: only submitter of an open bug can close it out after verifying the fix Verification

  25. Background • SpaceWire standard does not specify transport layer • Transport layer required to make standard more than data bus • command and data handling bus (MIL-STD 1553) • NASA has proposed transport layer to ESA • Proposed transport layer being implemented by BAE Transport Layer

  26. Connection Setup Diagram Node # 1 SpaceWire Network Node # 3 Transport Layer Node # 2 SpaceWire Node or Router Transport Application SpaceWire Point-to-Point Link Node # 1 Node # 2

  27. Basics • Transport layer handled between end users (not between intermediate routers) • Packet format defined for users of transport layer • Packets sent over channels • Reliable • Un-reliable • Each reliable packet acknowledged • Multiple reliable packets may be outstanding (not stop & wait) • Retransmission performed by time-out mechanism in transmitter • Channel is set-up using a configuration command with Channel ID set to “0” • Channel is unidirectional data transfer • Bidirectional communications requires 2 channels • Channel is opened from transmit node • Channel may be opened by “foreign” node for peer-to-peer communication between two other nodes • Channel commands • Open • Close • Error Transport Layer

  28. Destination 1 byte Source 1 byte Packet Control 1 byte Channel ID 1 byte = 0x00 Config Destination 1 byte Config Source 1 byte Config Channel 1 byte Config Command 1 byte Operand 0,1,2,4 or 8 bytes CRC 1 byte Destination 1 byte Source 1 byte Packet Control 1 byte Channel ID 1 byte Reserved (0x00) 1 byte CRC 1 byte Packet Formats Transport Header Transport Trailer • Data packet format • Configuration packet • Acknowledgement packet Destination 1 byte Source 1 byte Packet Control 1 byte Channel ID 1 byte Entire or Segment of Payload 0 to N bytes CRC 1 byte Transport Layer 7 6 5 4 3 2 1 0 Operand Length Type Opcode 7 6 5 4 3 2 1 0 Type 00 : Read 01 : Write 10 : Response 11 : ConfigurationError Response Opcode 0000 - 1111 Operand Length 00 = 1 Operand Bytes 01 = 2 Operand Byte 10 = 4 Operand Bytes 11 = 8 Operand Bytes Note : No operands with read opcodes Type Mode Sequence Number Type 00 : Transport01 : Reserved 10 : Reserved 11 : Reserved Mode 00 : Leading Segment of message 01 : Atomic or last segment of message 10 : Acknowledgement 11 : Transport Error Sequence Number 0000 – 1111 Incrementing Rollover

  29. Node # 1 SpaceWire Network Node # 3 Node # 1 SpaceWire Network Node # 2 Node # 3 Node # 2 Channel Setup - Half Open (one way) • Node # 1 is transmitter of channel to be set-up • Node # 1 sends configuration command to receiving Node # 2 Transport Layer • Node # 2 upon receiving command to open channel sends Ack to Node # 1 • Upon Node # 1 receiving Ack channel is open and ready to be used

  30. Node # 1 Node # 1 SpaceWire Network Node # 3 SpaceWire Network Node # 2 Node # 3 Node # 1 SpaceWire Network Node # 2 Node # 3 Node # 1 SpaceWire Network Node # 2 Node # 3 Node # 2 Channel Setup - Full Open (two way) • Channel set-up for data transfer from Node # 1 to Node # 2 Configuration Command Ack Response Transport Layer • Channel set-up for data transfer from Node # 2 to Node # 1 Configuration Command Ack Response

  31. Node # 1 Node # 1 SpaceWire Network SpaceWire Network Node # 3 Node # 3 Node # 2 Node # 2 Node # 1 SpaceWire Network Node # 3 Node # 2 Foreign Channel Setup - Half Open (one way) • Channel set-up for data transfer from Node # 1 to Node # 2 • Node # 3 sets up communication between Node # 1 and Node # 2 • 1st sends configuration command to receive node (Node # 2) • 2nd sends configuration command to transmit node (Node # 1) • Node # 1 may now send data to Node # 2 Transport Layer

  32. Node # 1 Node # 1 Node # 1 Node # 1 SpaceWire Network SpaceWire Network SpaceWire Network SpaceWire Network Node # 3 Node # 3 Node # 3 Node # 3 Node # 2 Node # 2 Node # 2 Node # 2 Node # 1 Node # 1 SpaceWire Network SpaceWire Network Node # 3 Node # 3 Node # 2 Node # 2 Foreign Channel Setup - Full Open (two way) • Channel set-up for data transfer from Node # 1 to Node # 2 • Channel set-up for data transfer from Node # 2 to Node # 1 Transport Layer

  33. TX Sequence Allocation Example • Sequence processing for allocation: • If a sequence number is in the TX window and free it can be used and is marked IN_USE otherwise sequence is unavailable. • Sequence processing for acknowledge packets: • If a ACK packet is received for a packet in the TX window that is IN_USE it is marked ACK Received. • If the start of the window is in the ACK Received state change to the FREE state and move the Window one position forward. • The Max window length is 8 to avoid overlap in RX sequence interpretation and simplify logic Tx window (max 8 packets) F = Free I = In Use A = Acknowledged 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 F F F I A A A I I I F F F F F F Forward Window Start Transport Layer

  34. RX Sequence Processing and Data Reordering Example Rx window (max 8 packets) Incoming packet process • If seq outside of window then • Discard • Else • if state = free then • Store packet and set state to received • else • Discard (as this is a duplicate packet) F = Free R = Received D = Delivered 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 F R F F R R F F Forward Window Start Packet delivery & window advancement process • if window start state = received or delivered then • if window start state = received then • Deliver packet • Set state to free • Increment window start • else if out-of-order delivery enabled then • Scan window for received packet • Deliver packet • Set state to delivered Transport Layer

  35. RX Sequence Processing and Data Reordering Example • Detecting duplicate data • If data is received at sequence number: seq, and Data Available(seq) == Y discard the data. Otherwise store the data and Set the State of Data Available(seq) to Y. • Delivering the data in order • If Data_available(Next to be delivered) == Y and Data_delivered(Next to be delivered) ==N, Deliver the data, Set Data_delivered (Next to be delivered) to Y. • Moving the RX window • While seq is outside the window: • Set Data_available(Window_start) = N, and Set Data_Delivered(Window_start) = N; Move window one position forward. • IE move the window forward resetting Data_available and Data_delivered until the received seq number is just inside the window. Rx window (max 8 packets) 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 Y = Yes N = No Data available Y Y N N Y Y N N Data delivered Y Y N N N N N N Forward Window start Next to be delivered Transport Layer

  36. Targeted Devices -Utilization & Speed • Link • 54SX32 • “Skinny” version • “Std” version 49 MHz • “C” cells - 59% • “S” cells - 93% • Total cells – 73% • Deluxe version does not fix • 54SX72 • “Deluxe” version • “std” version 100 MHz • “C” cells – 33% • “S” cells – 68% • Total cells – 45% • AX1000 • “Deluxe” version • “Std” version 127 MHz • “C” cells – 9% • “S” cells – 16% • Total cells – 12% • QL6325 • Waiting for routing software • 4 Port Router with 1 External Interface • AX1000-STD • 73 MHz • “C” cells – 58% • “R” cells – 95% • Total cells – 73% • RAM/FIFO – 11 out of 36 • Not Optimized Target Information

  37. SpaceWire Industry Collaboration • BAE has won a NASA Research Award in Space Communications Project • Implement SpaceWire on 0.25um Custom ASIC • Funded through Glen Research Center • ~ $1 M value • Point of contact Paul Kapcio BAE systems • Phone: 703-367-4657 • Email: paul.kapcio@baesystems.com • GSFC is working with BAE to implement SpaceWire design • 4 port router with 1 external interface • Implements NASA proposed transport layer BAE ASIC

  38. SpaceWire 4 Port Router with 1 External Interface stand alone point-to-point link Non-Blocking Cross-Bar Switch BAE ASIC Link DS Link External Interface (Parallel)

More Related