1 / 16

Design of a Real-Time CORBA Event Service customized for the CAN Bus

Design of a Real-Time CORBA Event Service customized for the CAN Bus. Rainer Finocchiaro, Stefan Lankes, Andreas Jabs rainer@lfbs.rwth-aachen.de http://www.rofes.de. Agenda. Event Service CAN Bus CEBP (Protocol for distributing Events) Benchmarks. Application Example: Motor Vehicle.

kynan
Download Presentation

Design of a Real-Time CORBA Event Service customized for the CAN Bus

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. Design of a Real-Time CORBA Event Service customized for the CAN Bus Rainer Finocchiaro, Stefan Lankes, Andreas Jabs rainer@lfbs.rwth-aachen.de http://www.rofes.de

  2. Agenda • Event Service • CAN Bus • CEBP (Protocol for distributing Events) • Benchmarks WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

  3. Application Example: Motor Vehicle Lighting Control Engine Control Unit Antilock Breaking System Electronic Locking System CAN CAN CAN CAN Gateway C A N C A N CAN CAN CAN CAN CAN Gearbox Control Electrical Seat Adjustment Active Suspension Electrical Window Openers Airbag Drive Control System Passenger Compartment Net WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

  4. Event Service Data Sources (Suppliers) Data Sinks (Consumers) Consumer Supplier EC Consumer Supplier Consumer ... ... Dataflow • Suppliers do not know Consumers • Consumers do not know Suppliers • Decoupling of Suppliers and Consumers makes system more flexible WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

  5. Centralized Event Service Node 2 Node 3 Node 1 Supplier Supplier Supplier Consumer Consumer Consumer EC Event Event Network • Distributed Event Service Node 2 Node 3 Node 1 Supplier Supplier Supplier Consumer Consumer Consumer EC EC EC Event Event Network Centralized <-> DistributedEvent Service WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

  6. The Controller Area Network • Offers: • Real-time Bus-Arbitration scheme with Collision Avoidance – CSMA/CA(in contrast to Ethernet with Collision Detection) • Priorities for messages • Broadcasting as standard addressing scheme(as opposed to point-to-point with Ethernet) • But: • has a very limited transfer rate of 1 Mbit/s WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

  7. Node EC GW EC GW CAN Bus Handler Event Event CAN Bus CAN messages EC Event Channel GW CAN Gateway CAN Event Broadcast Protocol (CEBP) CEBP Protocol cares for: • Splitting of a data packet into CAN messages at the side of the sender • Rejoining CAN messages at the side of the receiver(Fragmentation/Reassembly) • Correct Byte-order(Little-/Big-Endian) • Detection of CAN message losses CEBP Protocolworks parallel to point-to-point protocol for IOP-conform CORBA communication (CANIOP) WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

  8. ECID Protocol Priority Node 2 bits 2 bits 4 bits 3 bits Structure of the CAN Identifier • The field Protocol is for distinguishing 4 protocols(currently: 012 for CEBP and 102 for CANIOP) • Priority distinguishes 4 different priority levels • Nodeallows for 16 transmitting nodes • ECID offers 8 different Event Channels • More priorities, nodes and Event Channels can be supported by CAN 2.0B (29-bit identifier) Data… WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

  9. Structure ofCAN Message Body • FP: First Packet • LE: Little Endian • TypeCode: 34 defined in CORBA 2.6 • Data length only needed for string data types • 7 of 8 Bytes used for carrying raw data Data Length / Data Data… FP LE TypeCode (6 bits) Byte 1 Byte 2 Byte 3-8 WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

  10. Priorities inside the Channel • Priority Queue (Event Queue) with Delivery-Threads Delivery to Consumers Event Channel static dynamic Event Queue Events Deliver-Threads • Additional decoupling between Suppliers and Consumers • Supplier can continue after the Event Channel has received the Event • Parallel delivery of Events to Consumers • Should a Consumer need very long it does not block the other Consumers from receiving Events WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

  11. Priorities from End to End • Real-time Event Channel + CAN Bus • Priority-based delivery from end to end Node 1 Node 2 Supplier Consumer EC EC Event CAN Bus WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

  12. Node 2 Node 1 Preliminary Benchmarks • Code size of the Event Service approximately 250kB (dynamically linked) • Setup for latency tests: • 2 Pentium II 400 MHz • CAN Controller CAN/PCI/331 from ESD GmbH • Benchmarks • Half roundtrip latency for a CORBA::Short • Half roundtrip latency for a CORBA::String with varying length CAN Bus WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

  13. Benchmark I • Transferring a CORBA::Short (2 bytes) inside one and between two nodes WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

  14. Benchmark II • Different data sizes transferred inside one node and between two nodes WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

  15. Conclusions and Future Work • In this talk, I have presented a CORBA Event Service, which: • supports asynchronous Communication between data producers and data consumers • is adapted to the particular features and drawbacks of the CAN Bus • in combination with ROFES (our RT-ORB) and the CAN Bus will allow for efficient operation in DRE-Systems • still needs some work concerning threading • needs more benchmarking and testing in general WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

  16. Thank you for your attention! • More information about ROFES and the Event Service at: • www.rofes.de WPDRTS04 – April 27, 2004 Lehrstuhl für Betriebssysteme

More Related