Michael and friends...
I've been a fan of Kamaelia for a couple years now and when I needed
to come up with a componentized, flow-based development environment I
modeled it after Axon for two reasons:
1. The excellent level of tutorial documentation
2. The straightforward architectural approach used by Axon.
I actually just followed the "write your own axon" tutorial and
implemented it in D. Of course, implementing an axon-like subsystem
in a statically typed language was, well, challenging.
I now have MicroProcess, MicroScheduler, Inbox, Outbox and Component
working. It's pretty simple right now, but I've run a basic test that
creates three components (an even integer producer, an odd integer
producer and an integer printer consumer), links them up and cycles
the scheduler through about 1000 yield events.
It works like a charm and it's incredibly fast.
This was all done using free tools (SciTE editor, llvm ldc d compiler,
D language and the Tango Foundation Class Library).
Yields in D are implemented using the Tango "Fiber" class. I believe
the assembler created generates setjmp/longjmps.
I don't think I could have done it easily in other languages static OO
languages. One of the reasons I used D was that it compiles all the
way down to the metal and its support for generic programming using D
templates are second to none. Some of it's introspection features
were inspired by Python, Scheme and Lua.
Here's the current simple definition of Component:
class Component : MicroProcess
{
Inbox!(SIGNAL) controlBox;
LinkedList!(IntrFace) inboxes;
LinkedList!(IntrFace) outboxes;
this(char[] _name) {
super(_name);
inboxes = new LinkedList!(IntrFace);
outboxes = new LinkedList!(IntrFace);
controlBox = new Inbox!(SIGNAL);
inboxes.append(controlBox);
}
// same as in parent
void run() {
Fiber.yield();
}
}
Just thought you might like to know. Hopefully I can get it to alpha
release quality in the near future. If I can make it relatively
compatible with Axon, it may be straightforward to port Kamaelia
components. Eventually I hope to integrate it with GTK.
If you have any questions, feel free to email me.
have a good one,
erisian
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"kamaelia" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/kamaelia?hl=en
-~----------~----~----~----~------~----~------~--~---