[Embedlets-dev] Re: [Hardware] Events and JAPL
Status: Alpha
Brought to you by:
tkosan
|
From: Ted K. <tk...@ya...> - 2003-02-11 03:40:35
|
Andrzej stated: > Thats the way I see it too. JAPL drivers are Embedlet Event producers. > Embedlets are Event consumers (though they can also produce events for > consumption further downstream). > > However, in order to keep the development of JAPL and Embedlets code > bases decoupled from each other, we might need to create a special "adapter" > that can take JAPL events and mangle them into Embedlet Events. After wresteling with this problem in the Elevator challenge for awhile I eventually arrived at the following: 1) Embedlets hold references to JAPL peripherals and are able to invoke methods on these peripherals in order to configure them, output data to them and also read data from them. 2) The events that JAPL peripherals generate are very simple 'interrupt' events with no further semantics embedded in them. This was done to minimize the JAPL peripheral event/Embedlet event impedanace matching work that needed to be done. 3) Embedlets would then treat JAPL interrupt events just like device drivers treat physical peripheral interrupts, by querying the device that generated the interrupt in order to determine what action needed to be taken. I do not know if this is the best solution or not but it seems to solve the problem reasonably well. Ted __________________________________________________ Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day http://shopping.yahoo.com |