Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
Using R4 in Vehicle
Embedded Systems
Siemens VDO
Automotive
Miguel Lopez, Software ArchitectMiguel Lopez, Software Archite...
AgendaAgenda
•• SubjectSubject
–– why we decided to use R4 in vehicle systemwhy we decided to use R4 in vehicle system
•• ...
Who Are We?Who Are We?
•• Siemens VDO &Siemens VDO & OSGiOSGi AllianceAlliance
–– Siemens VDO is involved inSiemens VDO is...
R4 Is a Major ReleaseR4 Is a Major Release
•• Important milestones achieved inImportant milestones achieved in OSGiOSGi Al...
R4 Has Been Significantly IncreasedR4 Has Been Significantly Increased
•• Specification DocumentsSpecification Documents
(...
R4 Is Adapted and SuitableR4 Is Adapted and Suitable
•• Is it suitable for vehicle system?Is it suitable for vehicle syste...
Use CasesUse Cases
•• Gradually Integrate new featuresGradually Integrate new features
•• Localize applicationsLocalize ap...
Gradually Integrate New FeaturesGradually Integrate New Features
•• Systems are rapidly becoming complex as theirSystems a...
Gradually Integrate New FeaturesGradually Integrate New Features
•• No way with R3. What about R4?No way with R3. What abo...
Gradually Integrate New Features With R4Gradually Integrate New Features With R4
Core Framework ModularityCore Framework M...
Localize ApplicationsLocalize Applications
•• What is localization?What is localization?
–– adapting an application to var...
Localize Applications With R4Localize Applications With R4
Fragment Bundle (Modularity Layer)Fragment Bundle (Modularity L...
Enhance Development of ApplicationsEnhance Development of Applications
•• OSGiOSGi technology defines a powerful servicete...
Service Programming Model With R3Service Programming Model With R3
METAMETA--INF/INF/Manifest.mfManifest.mf
BundleBundle--...
Service Programming Model With R4Service Programming Model With R4
Declarative ServicesDeclarative Services
•• Simplifies ...
Service Programming ModelService Programming Model –– R3 vs. R4R3 vs. R4
METAMETA--INF/INF/Manifest.mfManifest.mf
BundleBu...
Enhance Development of ApplicationsEnhance Development of Applications
•• Main AdvantagesMain Advantages
–– Better develop...
Help InterHelp Inter--Bundle CommunicationBundle Communication
•• Communication between bundles is essentialCommunication ...
Generic Event Mechanism With R4Generic Event Mechanism With R4
Event Admin ServiceEvent Admin Service
•• Based on PublishB...
Manage Power ChangesManage Power Changes
•• Systems must carefully manage power consumptionSystems must carefully manage p...
Power Management Service in VehiclePower Management Service in Vehicle
SpecificationSpecification
Power Manager ServicePow...
Diagnose SystemDiagnose System
•• Need to perform diagnosticsNeed to perform diagnostics
–– Configure, monitor and verify ...
Diagnostic Service in Vehicle SpecificationDiagnostic Service in Vehicle Specification
Diagnostic ServiceDiagnostic Servic...
ConclusionConclusion
•• R4 platform brings real added value in vehicleR4 platform brings real added value in vehicle
syste...
SAN DIEGO Is Our Reference ApplicationSAN DIEGO Is Our Reference Application
•• Visit our booth !Visit our booth !
Questions?Questions?
Miguel LopezMiguel Lopez
Software ArchitectSoftware Architect
Siemens VDO AutomotiveSiemens VDO Autom...
Using OSGi R4 Service Platform in Vehicle Embedded Systems - Miguel Lopez, Software Architect, Siemens VDO Automotive
Upcoming SlideShare
Loading in …5
×

Using OSGi R4 Service Platform in Vehicle Embedded Systems - Miguel Lopez, Software Architect, Siemens VDO Automotive

375 views

Published on

OSGi World Congress 2005 - Developer Forum Day 2

Published in: Technology
  • Be the first to comment

  • Be the first to like this

Using OSGi R4 Service Platform in Vehicle Embedded Systems - Miguel Lopez, Software Architect, Siemens VDO Automotive

  1. 1. Using R4 in Vehicle Embedded Systems Siemens VDO Automotive Miguel Lopez, Software ArchitectMiguel Lopez, Software Architect
  2. 2. AgendaAgenda •• SubjectSubject –– why we decided to use R4 in vehicle systemwhy we decided to use R4 in vehicle system •• IntroductionIntroduction –– Release 4 is a major stepRelease 4 is a major step •• How to use R4 in vehicle embedded systems?How to use R4 in vehicle embedded systems? –– Illustrated with concrete use casesIllustrated with concrete use cases •• ConclusionConclusion
  3. 3. Who Are We?Who Are We? •• Siemens VDO &Siemens VDO & OSGiOSGi AllianceAlliance –– Siemens VDO is involved inSiemens VDO is involved in OSGiOSGi Alliance since 2001Alliance since 2001 •• is the Siemens VDO Platformis the Siemens VDO Platform •• multimedia system based onmultimedia system based on OSGiOSGi Service PlatformService Platform •• used in BMW 1, 3, 5 and 6 Series, X3used in BMW 1, 3, 5 and 6 Series, X3 •• used in current developments for other Car makersused in current developments for other Car makers
  4. 4. R4 Is a Major ReleaseR4 Is a Major Release •• Important milestones achieved inImportant milestones achieved in OSGiOSGi AllianceAlliance –– R4 Core (including Compendium) SpecificationsR4 Core (including Compendium) Specifications -- releasedreleased –– R4 Vehicle and Mobile SpecificationsR4 Vehicle and Mobile Specifications –– soonsoon •• What are the changes/improvements?What are the changes/improvements? –– Comparison between R3 and R4: two metricsComparison between R3 and R4: two metrics •• Specification (number of pages)Specification (number of pages) •• API Changes (number of methods)API Changes (number of methods)
  5. 5. R4 Has Been Significantly IncreasedR4 Has Been Significantly Increased •• Specification DocumentsSpecification Documents (number of pages)(number of pages) –– twice as many pagestwice as many pages in R4 than R3in R4 than R3 •• API Changes (number ofAPI Changes (number of public methods)public methods) –– twice as many publictwice as many public methods in R4 than R3methods in R4 than R3 104 288 450 900 0 500 1000 R1 R2 R3 R4 151 353 661 1432 0 500 1000 1500
  6. 6. R4 Is Adapted and SuitableR4 Is Adapted and Suitable •• Is it suitable for vehicle system?Is it suitable for vehicle system? –– OSGiOSGi Service Platform originally targeted "smallService Platform originally targeted "small devices"devices" •• Now, R4 is applicable in many architecturesNow, R4 is applicable in many architectures –– add powerful new modularity capabilities to Javaadd powerful new modularity capabilities to Java –– improved encapsulation of software unitsimproved encapsulation of software units –– R4 plans to address a large device rangeR4 plans to address a large device range •• However, R4 is well adapted and suitable forHowever, R4 is well adapted and suitable for vehicle systemsvehicle systems –– Lets have a look at the use casesLets have a look at the use cases
  7. 7. Use CasesUse Cases •• Gradually Integrate new featuresGradually Integrate new features •• Localize applicationsLocalize applications •• Enhance the development of applicationsEnhance the development of applications •• Help interHelp inter--bundle communicationbundle communication •• Manage power changesManage power changes •• Diagnose the systemDiagnose the system
  8. 8. Gradually Integrate New FeaturesGradually Integrate New Features •• Systems are rapidly becoming complex as theirSystems are rapidly becoming complex as their capacities increasecapacities increase •• Critical step in the software process is integrationCritical step in the software process is integration –– integrate all modules/components/features within aintegrate all modules/components/features within a single platform and a given productsingle platform and a given product –– handle complex dependencieshandle complex dependencies •• Even worse... some are conflictingEven worse... some are conflicting –– Let look at a concrete exampleLet look at a concrete example
  9. 9. Gradually Integrate New FeaturesGradually Integrate New Features •• No way with R3. What about R4?No way with R3. What about R4? Navigation App 1.0 Foundation Library 1.0 version 1.0 OSGi Service Platform Integration Area Phone App 1.0 Foundation Library 2.0 version 2.0 Package Conflicts Phone Team Navigation Team Core Team
  10. 10. Gradually Integrate New Features With R4Gradually Integrate New Features With R4 Core Framework ModularityCore Framework Modularity •• Manages multi versions of the same packageManages multi versions of the same package •• Both modules can then coexistBoth modules can then coexist •• AdvantagesAdvantages –– Integrators have more flexibilityIntegrators have more flexibility –– Developers team can defer new baseline integrationDevelopers team can defer new baseline integration
  11. 11. Localize ApplicationsLocalize Applications •• What is localization?What is localization? –– adapting an application to various languages, culturesadapting an application to various languages, cultures and environmentsand environments •• textual elements are not hard codedtextual elements are not hard coded •• support for new languages without recompilationsupport for new languages without recompilation •• culturally dependent format for dates, currencies ...culturally dependent format for dates, currencies ... •• Java SE Platform already provides such featuresJava SE Platform already provides such features –– java.util.Localejava.util.Locale,, java.util.ResouceBundlejava.util.ResouceBundle, etc ..., etc ... •• Java SE Localization must be adapted toJava SE Localization must be adapted to OSGiOSGi –– Both use Java classBoth use Java class--loading capabilities for searchingloading capabilities for searching resources, classesresources, classes
  12. 12. Localize Applications With R4Localize Applications With R4 Fragment Bundle (Modularity Layer)Fragment Bundle (Modularity Layer) •• Fits Java SE Localization conceptsFits Java SE Localization concepts •• Ease to understand for Java DevelopersEase to understand for Java Developers •• Very FlexibleVery Flexible –– New languages may be added after deploymentNew languages may be added after deployment –– Good migration of legacy Java ApplicationsGood migration of legacy Java Applications
  13. 13. Enhance Development of ApplicationsEnhance Development of Applications •• OSGiOSGi technology defines a powerful servicetechnology defines a powerful service oriented architecture ... Howeveroriented architecture ... However –– Number of services grows quicklyNumber of services grows quickly •• Complex interComplex inter--service dependenciesservice dependencies –– Due to dynamic nature ofDue to dynamic nature of OSGiOSGi environmentenvironment –– Deal with specificDeal with specific OSGiOSGi APIsAPIs •• Developer may not prepare to deal with this modelDeveloper may not prepare to deal with this model •• It seems reasonable to solve in a single place allIt seems reasonable to solve in a single place all these issuesthese issues
  14. 14. Service Programming Model With R3Service Programming Model With R3 METAMETA--INF/INF/Manifest.mfManifest.mf BundleBundle--Activator:Activator: com.osgicongress.Hellocom.osgicongress.Hello com.osgicongress.Hello.javacom.osgicongress.Hello.java public class Hello implementspublic class Hello implements BundleActivatorBundleActivator {{ public voidpublic void start(BundleContextstart(BundleContext bcbc)) {{ ServiceTrackerServiceTracker tracker = newtracker = new ServiceTracker(bcServiceTracker(bc,, ""org.osgi.service.log.LogServiceorg.osgi.service.log.LogService", null);", null); tracker.opentracker.open();(); LogServiceLogService log = (log = (LogService)tracker.getServiceLogService)tracker.getService();(); if (log != null)if (log != null) {{ log.log(LogService.LOG_INFO,"Hellolog.log(LogService.LOG_INFO,"Hello OSGiOSGi Congress");Congress"); }} elseelse {{ // what to do here ...// what to do here ... }} }} public voidpublic void stop(BundleContextstop(BundleContext bcbc) {}) {} }} some extra tests ... some uncomfortable situations! R3 requires to keep track of services
  15. 15. Service Programming Model With R4Service Programming Model With R4 Declarative ServicesDeclarative Services •• Simplifies the service oriented programming modelSimplifies the service oriented programming model (XML description)(XML description) •• Assists bundle developers in their workAssists bundle developers in their work •• Handles the dynamic of the service objectsHandles the dynamic of the service objects
  16. 16. Service Programming ModelService Programming Model –– R3 vs. R4R3 vs. R4 METAMETA--INF/INF/Manifest.mfManifest.mf BundleBundle--Activator:Activator: com.osgicongress.Hellocom.osgicongress.Hello METAMETA--INF/INF/Manifest.mfManifest.mf ServiceService--Component: OSGIComponent: OSGI--INF/INF/activator.xmlactivator.xml OSGIOSGI--INF/INF/activator.xmlactivator.xml <?xml version ="1.0" encoding="UTF<?xml version ="1.0" encoding="UTF--8"?>8"?> <component name="<component name="example.Helloexample.Hello">"> <implementation class="<implementation class="com.osgicongress.Hellocom.osgicongress.Hello"/>"/> <reference name="LOG"<reference name="LOG" interface="interface="org.osgi.service.log.LogServiceorg.osgi.service.log.LogService"/>"/> </component></component> com.osgicongress.Hello.javacom.osgicongress.Hello.java public class Hellopublic class Hello {{ protected voidprotected void activate(ComponentContextactivate(ComponentContext cc)cc) {{ LogServiceLogService log = (log = (LogService)cc.locateService("LOGLogService)cc.locateService("LOG");"); log.log(LogService.LOG_INFO,"Hellolog.log(LogService.LOG_INFO,"Hello OSGiOSGi Congress");Congress"); }} }} com.osgicongress.Hello.javacom.osgicongress.Hello.java public class Hello implementspublic class Hello implements BundleActivatorBundleActivator {{ public voidpublic void start(BundleContextstart(BundleContext bcbc)) {{ ServiceTrackerServiceTracker tracker = newtracker = new ServiceTracker(bcServiceTracker(bc,, ""org.osgi.service.log.LogServiceorg.osgi.service.log.LogService", null);", null); tracker.opentracker.open();(); LogServiceLogService log = (log = (LogService)tracker.getServiceLogService)tracker.getService();(); if (log != null)if (log != null) {{ log.log(LogService.LOG_INFO,"Hellolog.log(LogService.LOG_INFO,"Hello OSGiOSGi Congress");Congress"); }} elseelse {{ // ??? what to do here// ??? what to do here }} }} public voidpublic void stop(BundleContextstop(BundleContext bcbc) {}) {} }} R3 Programming ModelR3 Programming Model R4 Programming ModelR4 Programming Model
  17. 17. Enhance Development of ApplicationsEnhance Development of Applications •• Main AdvantagesMain Advantages –– Better developer productivityBetter developer productivity –– Less error prone for developersLess error prone for developers –– Developers focus on business logicDevelopers focus on business logic –– May reduce memory footprint (lazy activation)May reduce memory footprint (lazy activation) •• Creation and activation of the component can be delayedCreation and activation of the component can be delayed
  18. 18. Help InterHelp Inter--Bundle CommunicationBundle Communication •• Communication between bundles is essentialCommunication between bundles is essential •• Almost, all bundles and applications must react on signalsAlmost, all bundles and applications must react on signals •• Several designs may be used to implement suchSeveral designs may be used to implement such communicationcommunication –– Popular Java Event/Listener pattern (Java Bean Model)Popular Java Event/Listener pattern (Java Bean Model) –– OSGiOSGi whiteboard approachwhiteboard approach •• Open Issues:Open Issues: –– Minimize proliferation of Event/Listener interfacesMinimize proliferation of Event/Listener interfaces –– Is there a way to find and promote a generic mechanism?Is there a way to find and promote a generic mechanism?
  19. 19. Generic Event Mechanism With R4Generic Event Mechanism With R4 Event Admin ServiceEvent Admin Service •• Based on PublishBased on Publish--Subscribe patternSubscribe pattern •• Easy system monitoringEasy system monitoring •• Core events: Framework/Service/Bundle/LogCore events: Framework/Service/Bundle/Log •• Vehicle events: Power ManagementVehicle events: Power Management •• Any event may be published through this simpleAny event may be published through this simple and flexible APIand flexible API
  20. 20. Manage Power ChangesManage Power Changes •• Systems must carefully manage power consumptionSystems must carefully manage power consumption •• Power Information from user, application, or hardwarePower Information from user, application, or hardware device must be collected to enable a better powerdevice must be collected to enable a better power management decision and executionmanagement decision and execution •• Applications must adjust their activitiesApplications must adjust their activities •• Some hardware devices may have their own powerSome hardware devices may have their own power managementmanagement •• Open Issues:Open Issues: –– How to organize and control the whole system to enable a betterHow to organize and control the whole system to enable a better power decision and execution?power decision and execution? –– No standardNo standard ²²modelmodel
  21. 21. Power Management Service in VehiclePower Management Service in Vehicle SpecificationSpecification Power Manager ServicePower Manager Service •• Provides a common approach for managing theProvides a common approach for managing the platform's energy consumptionplatform's energy consumption –– Coordinates and consistently maintains the system andCoordinates and consistently maintains the system and device power statesdevice power states –– Defines the power states transitionsDefines the power states transitions –– System and device power states notificationsSystem and device power states notifications –– Policy free in order to adapt as efficient as possible thePolicy free in order to adapt as efficient as possible the power strategypower strategy
  22. 22. Diagnose SystemDiagnose System •• Need to perform diagnosticsNeed to perform diagnostics –– Configure, monitor and verify the systemConfigure, monitor and verify the system •• Diagnostician requirements are:Diagnostician requirements are: –– Get device parametersGet device parameters –– Change device parametersChange device parameters –– Execute selfExecute self--teststests –– Monitor device dataMonitor device data •• Open Issues:Open Issues: –– Is there a common approach for discovery andIs there a common approach for discovery and invocation of diagnostic commandsinvocation of diagnostic commands –– Standard approach is requiredStandard approach is required
  23. 23. Diagnostic Service in Vehicle SpecificationDiagnostic Service in Vehicle Specification Diagnostic ServiceDiagnostic Service •• Full description of diagnostic commands usingFull description of diagnostic commands using Meta typing (e.g. XML file)Meta typing (e.g. XML file) •• Easy to publish diagnostic commands for newlyEasy to publish diagnostic commands for newly installed devicesinstalled devices •• Local and remote invocationsLocal and remote invocations
  24. 24. ConclusionConclusion •• R4 platform brings real added value in vehicleR4 platform brings real added value in vehicle systemssystems –– Core enhancementsCore enhancements –– New vehicle servicesNew vehicle services •• R4 solves significant vehicle platform use casesR4 solves significant vehicle platform use cases •• TLA is an excellent platform for using R4TLA is an excellent platform for using R4 Specifications in the next coming yearsSpecifications in the next coming years
  25. 25. SAN DIEGO Is Our Reference ApplicationSAN DIEGO Is Our Reference Application •• Visit our booth !Visit our booth !
  26. 26. Questions?Questions? Miguel LopezMiguel Lopez Software ArchitectSoftware Architect Siemens VDO AutomotiveSiemens VDO Automotive SophiaSophia--AntipolisAntipolis, France, France mailto:mailto: miguel.lopez@siemens.commiguel.lopez@siemens.com +33 (0) 492 381 151+33 (0) 492 381 151

×