Re: [NTLK] Lego Mindstorm Newton SDK Idea: Now with free Bluetooth wish! ;=}

From: Sean Luke (sean_at_cs.gmu.edu)
Date: Mon Feb 20 2006 - 17:27:38 PST


On Feb 20, 2006, at 3:16 AM, DJ Vollkasko wrote:

>> Unfortunately, Waba for the Newton doesn't have serial working
>> right, so that's a non-starter.
>
> Sean, you're breaking my heart, you really do. Why doesn't nWaba do
> the serial?

Short reason: because NewtonScript's serial mechanism borders on the
pathological, and Paul's C++-level serial code approach didn't quite
work right before he had to work on something else. :-(

The technical reason. Recall that to do many things (like draw on
the screen), Waba typically must make requests of the NewtonScript
system. If Waba was accessing serial using C++ code, then it'd be a
fairly easy chunk to write. But instead Waba must ask NewtonScript
to do it, and NewtonScript's approach to doing serial is EXTREMELY
weird. NewtonScript has callbacks and other junk because it's not a
multithreaded language. In turn Waba's code would need callbacks
etc., which breaks the standard Java/C++ approach for reading serial
ports (blocking streams). It's just too much of a mess to translate
that one.

Instead, Paul tried whipping up some C++ code for me which directly
accessed the serial port in a C++/Java style, and that should have
worked peachy. But if I recall correctly -- and it was years ago --
the code had bugs. I was not able to get it to be stable, nor was I
able to show Paul (who's on another continent) replicable examples of
the bugs.

>
>> Sure wish I had the NTK
>> runnable on my machine.
>
> I sure wish so, too! ;=}
>
> Anything we could do to help?

I'm still mulling over what to do...

Sean

-- 
This is the NewtonTalk list - http://www.newtontalk.net/ for all inquiries
Official Newton FAQ: http://www.chuma.org/newton/faq/
WikiWikiNewt for all kinds of articles: http://tools.unna.org/wikiwikinewt/


This archive was generated by hypermail 2.1.5 : Mon Feb 20 2006 - 20:30:03 PST