Download presentation
Presentation is loading. Please wait.
1
Copyright © 2001Page 1 11-6-2015 Real-Time Java Fact-no-fiction Java in technical automation Paul Wijntjes Consultant Turnkiek Technical Systems
2
11-6-2015 Copyright © 2001Page 2 Contents Introduction Java in embedded Real Time Java Demonstrator
3
11-6-2015 Copyright © 2001Page 3 Offices in: Amersfoort Delft Eindhoven
4
11-6-2015 Copyright © 2001Page 4 nEarly adopter nQuality solutions nCost effective and future aimed nIn technical industrial & scientific market nReliable and valued partner Give the customer peace of mind Commitment = commitment Small things matter Treat and respect people as people Mission statement: Inproduct sw V&S systemen Prod. Autom. Network Comp R &D Traffic & Transport Productie Bdr. Defense Advanced machines Utilities Telecom Java Embedded Microsoft Unix /Linux Platforms Service areas. Market segments
5
11-6-2015 Copyright © 2001Page 5 Contents Introduction Java in embedded Real Time Java Demonstrator
6
11-6-2015 Copyright © 2001Page 6 Not only people YEAR 2010 Number of subscribers/units (millions) People Automobiles Bicycle Portable PCs Motorcycles, Boats, Vending Machines etc Pets (dogs and cats etc) Total 120 100 60 50 10 20 360 Forecast by DoCoMo based on “Trends in Household Consumption” by Economic Planning Agency, and published materials by Japan Pet Food Manufacturer’s Association etc
7
11-6-2015 Copyright © 2001Page 7 Pro File Pro File JavaTM 2 Platform Hardware / Operating System Java Virtual Machine J2EE APIs J2SE APIs J2ME APIs Pro File Pro File Pro File Pro File Pro File Pro File Pro File Pro File Pro File Pro File Pro File Pro File Pro File Pro File Pro File Pro File Profiles Configu- rations ??? Thanks to Chris Laffra, OTI
8
11-6-2015 Copyright © 2001Page 8 Why Java in Embedded ? More reliable More productive - O bject oriented - High level - C omponent model Inherent networking Less porting effort (if any) Machine code skills deteriorating Descartes
9
11-6-2015 Copyright © 2001Page 9 Evolution -> Revolution SE EE ME -2 y now +2 y
10
11-6-2015 Copyright © 2001Page 10 Contents Introduction Java in embedded Real Time Java Demonstrator
11
11-6-2015 Copyright © 2001Page 11 Yes, but…… What about Real-Time?
12
11-6-2015 Copyright © 2001Page 12 Specification J-Consortium, RTJWG - NewMonics, HP, Microsoft, Aonix,... JCP, JSR-0000001 - Specs - Reference implementation - Test suite - Expected Q4-2001
13
11-6-2015 Copyright © 2001Page 13 Guiding Principles Applicability to particular Java environments Backward compatibility Write once, run anywhere Current practice versus advanced future features Predictable execution No syntactic extension
14
11-6-2015 Copyright © 2001Page 14 RTSJ: 8 modified areas 1. Thread scheduling and dispatching 2. Memory management 3. Synchronization and resource sharing 4. Physical memory access 5. Asynchronous event handling 6. Asynchronous transfer of control 7. Asynchronous thread termination 8. Exceptions
15
11-6-2015 Copyright © 2001Page 15 1. Thread scheduling and dispatching Introduction of class RealTimeThread Predictable execution Unanticipated scheduling algorithms can be used Preemptive, Priority-based, FIFO within priority with at least 28 unique priority levels
16
11-6-2015 Copyright © 2001Page 16 How does it work? Rt-thread Time Priority Java thread GC Rt-thread Pipe
17
11-6-2015 Copyright © 2001Page 17 2. Memory management Garbage collection Basic memory areas - Scoped memory - Physical memory - Immortal memory - Heap memory
18
11-6-2015 Copyright © 2001Page 18 3. Synchronisation and resource sharing Prevent priority inversion Monitor behavior policy can be set per object. Determinisme
19
11-6-2015 Copyright © 2001Page 19 Priority inheritance Object Thread 1 Thread 2 Lock Unlock Lock Priority Time
20
11-6-2015 Copyright © 2001Page 20 4. Physical memory access Byte-level access to physical memory Construction of objects in physical memory
21
11-6-2015 Copyright © 2001Page 21 5. Asynchronous event handling Two classes AsyncEvent AsynchEventHandler Implemented scheduler for execution
22
11-6-2015 Copyright © 2001Page 22 AsyncEvent (how it works) AsyncEvent bindTo() abstract class AsyncEventHandler: run() // final handleAsyncEvent() getAndDecrementPendingFireCount() addHandler() Handler implements Schedulable and Runnable interfaces. Real world event
23
11-6-2015 Copyright © 2001Page 23 6. Asynchronous transfer of control (ATC) Execution transfer Time bound ATC and asynchronous event handling can be combined.
24
11-6-2015 Copyright © 2001Page 24 7. Asynchronous thread termination Safely transfer of control New mechanism for stopping threads
25
11-6-2015 Copyright © 2001Page 25 8. Exceptions New several exceptions New treatment of exceptions asynchronous transfer of control memory allocation
26
11-6-2015 Copyright © 2001Page 26 Implementations TimeSys, reference implementation JSR-1 OTI/IBM J9 Esmertec, JBed Insignia Solutions, Jeode aJile Systems
27
11-6-2015 Copyright © 2001Page 27 Contents Introduction Java in embedded Real Time Java Demonstrator
28
11-6-2015 Copyright © 2001Page 28 Real time demonstrator
29
11-6-2015 Copyright © 2001Page 29 PC 104 board QNX Neutrino OTI’s J9 + Real-Time Extensions Application Drivers motorcontrolers Architecture
30
11-6-2015 Copyright © 2001Page 30 Visual Age Micro Edition After running 3 threads “simultaneously” Trace analyzerMemory analyzer
31
11-6-2015 Copyright © 2001Page 31 Lessons learned Real-Time Java is Really Real-Time Implementation of specs not complete OTI’s J9 and VAME work very well
32
11-6-2015 Copyright © 2001Page 32 Summary Expected exponential growth in J2ME applications Real-Time Java nearly final It’s time to make plans to use Real Time Java
33
11-6-2015 Copyright © 2001Page 33 More information java.sun.com www.rtj.org www.drtsj.org www.embedded.oti.com www.turnkiek.nl wijntjes@turnkiek.nl
34
11-6-2015 Copyright © 2001Page 34 Thank you For your time and attention
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.