This document discusses requirements for developing an embedded integrated development environment (IDE) using Eclipse technologies. It describes using Eclipse Modeling Framework (EMF) to model embedded projects. It also discusses using EMF validation, Graphical Modeling Framework (GMF) editors, Xpand for code generation, and the CDT and DLTK plugins for code editing. The IDE will integrate model and code editing with compilation, communication with targets via the Target Communication Framework (TCF) and Remote System Explorer (RSE). The goal is to leverage the Eclipse ecosystem to quickly create a complex IDE environment focused on embedded development.
Developer Data Modeling Mistakes: From Postgres to NoSQL
Build a Modern Embedded IDE with Eclipse Technologies
1. Developer Suite Use Eclipse technologiesto build a modern embedded IDE Benjamin CabéGaétan MoriceEclipseCon 2010 January 21, 2010 Sierra Wireless Proprietary and Confidential 1
3. Requirements Whatis M2M ? Definition : “M2M refers to data communication between machines.” API/Web Services Connectivity Network Asset Customer Application Communication Device
4.
5.
6. Requirements Users profiles Newbies Solution providers Multiple targets Sierra Wireless devices Embedded Linux …
10. Modeling EMF - Eclipse Modeling Framework The model is the pillar of the tool Used to model what an embeddedprojectis Benefitsfrom EMF Notifications Serialization Reflective API … all the incredible EMF tools (GMF, Validation, Xpand, Ecore Tools, …)
16. Navigator Project Explorer Displays model objects as the Project structure Based on Common Navigator Framework Extensible treeview Rathercomplex API But reallypowerful We use an internal model to define the structure (nodesonlyused to group or display informations) Extension Points:org.eclipse.ui.navigator.* Excellent tutorial: “Building a Common Navigator based viewer”
19. Model dition Forms editors Forms + EMF + databinding Create UI Bind UI to model privatevoidcreateContent(FormToolkittoolkit, Composite parent) { Composite composite = toolkit.createComposite(parent, SWT.NONE); GridDataFactory.fillDefaults().grab(true, false).applyTo(composite); GridLayoutFactory.fillDefaults().numColumns(2).applyTo(composite); toolkit.createLabel(composite, "Name:", SWT.NONE); _textName = toolkit.createText(composite, "", SWT.BORDER); GridDataFactory.fillDefaults().grab(true, false).applyTo(_textName); } privatevoidbind() { DataBindingContextbindingContext = newEMFDataBindingContext(); // -- Bind the Name bindingContext.bindValue(SWTObservables.observeText(_textName, SWT.FocusOut), EMFEditObservables.observeDetailValue(Realm.getDefault(), getEditingDomain(), _myEObject, M2MPackage.eINSTANCE.getINamedElement_Name())); }
20. Model edition Forms editors Result Available in PDE Incubator: EMF-FormsEditor to beused for next-generation PDE editors
21. Model edition Graphical Editor: GMF Uses GMF generator to bootstrap Heavy use of GMF Runtime Model GMF generation Generatededitor Customization Modified editor
22. Model edition Graphical Editor: GMF Otherfeatures Rotation Automatic port creation HTML Tooltips Extensible presentation Custom figures canbedefinedusing an extension point
25. Model validation EMF Validation Extensible (needed for specific-targetconstraints) Constraints are registeredusing an extension point We use only the batch mode Extension points: org.eclipse.emf.validation.* publicIStatusvalidate (EObject model, IProgressMonitor monitor) { IBatchValidatorbatchValidator = ModelValidationService.getInstance() .newValidator(EvaluationMode.BATCH); batchValidator.setIncludeLiveConstraints(true); batchValidator.setReportSuccesses(false); returnbatchValidator.validate(model, monitor); }
26. Model validation Integrated in a builder Transparent and automatic (on save) Uses Problem Markers Coupledwith quick fixes for a better user experience
35. Round-tripping Mandatory for a good user experience Be able to edit code or model indifferently Continuoussynchronization First study: EMF Compare Good candidate but toorich for ourneeds Solution: Direct modification of existingmodels
36. Round-tripping Solution Integrated in a builder Synchronize Model and AST From code to model: Code Based on existingparser AST Java transformation Model (extractfrom code) Model (previous version) Merge Model (new version)
38. Compilation CDT - ManagedBuild System (MBS) Declarative creation of custom tool chains Through MBS Extension point Direct integration in CDT builder and preference A bit complex Mechanism of scanner discovery profiles to find tools binaries Extension Point: org.eclipse.ui.managebuilder.core.buildDefinition Excellent tutorial: CDT Plug-in Developer Guide Extension Point: org.eclipse.cdt.make.core.ScannerConfigurationDisccoveryProfile
40. Compilation CDT - Dependencies management Dependencies management Difficult with CDT Configuration, build artefacts, libraries include, header include to manage No generic rule => have to be hand craft Use of CDT API to access projects description Managed by refactoring process
44. Target communication Objectives Make device’s services available Download Terminal … De-coupling of services and communication channel Extensible January 21, 2010 Sierra Wireless Proprietary and Confidential 44
45. Target communication Target Communication Framework - TCF Embedded agent Asynchronous Protocol based on Command, Result Event Launch Config TerminalView Download Service Terminal Service Channel TCF Connection Manager Embedded Agent
46. Features Editors Navigator Validation Model Editor Code Compilation Navigator Target Navigator Communication
47. Target navigator Remote System Explorer - RSE GUI framework Tree Explorer Match well with TCF
52. The benefits of a large ecosystem Allows to createreallycomplexenvironmentquickly Coversdifferentskinds of domains Offersreactive support with the community Allows to focus on real added value
53. January 21, 2010 Sierra Wireless Proprietary and Confidential 53 Questions?