Archive for April, 2002

Apr 29 2002

Scope… always scope…

Published by matt under Uncategorized

I realized this evening that the problem I’m facing in my Scheme->Forth

compiler is one of lexical scope. Forth doesn’t have a notion of scope at the word (procedure) level.

UIL (Universal Intermediate Language) does.

Either I need to

  1. CPS UIL (not so tragic, really)

  2. Jump out of the compiler to Forth at a lower level (closer to assembly) when scoping issues have been resolved.

The former is particularly Schemely, and shouldn’t be too hard at this point (UIL is fairly simple overall).

There are probably other solutions I can implement as well, although they would probably (effectively) result in #2.

Bailing later would be guaranteed to work, especially if I dumped into Forth after register allocation.

This would, effectively, guarantee success.

I’ll have to reread the chapters on CPS in Essentials of Programming Languages before going to bed, and

invoke my continuation on this tomorrow morning…

One response so far

Apr 26 2002

Too much raquetball?

Published by matt under Uncategorized

hyper150.gif

3 1/2 hours on the court yesterday. Most all of me is sore.

It felt good, but I’m sore. The most annoying thing right now is that I have been introduced

to a proper swing–I have not drilled this, but I know what I should be doing.

Knowing in your mind is very different than knowing with your body (Note to self:

similar sentiment lies at heart of using manipulatives in the classroom), and as a result

I spent more time early in the evening aggrivated myself while trying to swing “correctly” (and missing) than just playing

my game.

Once I managed to flush notions of a “correct” swing from my mind, and went back to my normal

hack play, I played quite well for the rest of the evening.

I think there is a lesson in the design process here as well. Students will write hack code

before they’ll plan one line of it if the net result is they don’t have to flex any mental muscles or

relearn any old, bad habits. While I want to become a better raquetball player, my students

are not necessarily striving to become better programmers–they just want to learn language

X. Or get an A. Or more likely, get their homework done so they can go play video games/go drinking with their friends/watch TV/do whatever they do for fun.

Argh. What an evil circle. The question is, how do you consistently motivate students to excellence?

Comments Off

Apr 23 2002

HowTos

Published by matt under Uncategorized

Documentation is a bore.

I’ve added a “HowTos” section to the site, which will eventually include all documentation pertaining to this site, both from a user and administrative point-of-view. For the moment, it covers posting to blogs and creating new blogs, although I have a quick Perl script to write before the latter is done.

There is enough there that someone could start using the blogs, though. I need to install the Wiki soon.

Comments Off

Apr 22 2002

Research focus?

Published by matt under Uncategorized

As a result of making progress n the Scheme->Forth compiler (for the LEGO Mindstorm), an interesting possible focus came up. The initial event-based interface we’ve devised is na?ve; this was known from the outset, but it wasn’t until one of my students put a good problem to me that we realized the ease with which student programs could fall into race conditions. Semaphores, locks, or some other mechanism would be necessary for them to get predictable behavior from their bots.

I talked with Bryce about this, and in particular how they did systems control at Cummins in the diesel engines. Typically, they’d work off the clock, and have an executor that would manage all their event handling. This single point of control, tied to the clock, eliminates a lot of problems and allows for profiling of code and other forms of analysis that are valuable to someone writing code that interfaces with hardware.

line-follow-state-machine.jpg

From talking with Felix about the same, I learned more about his Masters work,

which involved a state-machine representation of autonomous robots.

While I still need to read his thesis, I thought about this some.

Motors and other stateful aspects of the robot would be at the nodes,

and conditions on sensors would be on the edges; then, in each state,

I would simply “poll” each of the edges until one of them was true—then,

you transition.

While all this is very cool, the point is that there are several reasonable ways to program the bot, all easily implemented, and all run into good, meaty CS/systems topics. With some more thought about the pedagogy, this could be something that I can narrow down to a tight topic, do a few small-scale experiments on, and have a nice dissertation at the end of the process. Put another way, it narrows both the CS content and the scope of the pedagogy involved, and therefore seems to be a worthwhile avenue for further thought.

Comments Off

Apr 22 2002

More updates

Published by matt under Uncategorized

I can now grab arbitrary pages from around the WWW and include them into the site at the time a page is published. This is handy, and will make things like research statements and whatnot easy to have individuals maintain in their own WWW accessible space.

I need to clean up/improve the Resources rendering code, so that outlines can be grabbed from anywhere. That’s on the to-do list.

Things look better than they did Friday, though, so that is good.

Comments Off

Apr 20 2002

Resources

Published by matt under Uncategorized

I don’t like the name “Resources” as part of the CS-ED site; it seems overbroad. For the moment, though, it will have to do.

The nice things about the resources portion of the site is I have put together some Scheme and Perl scripts to turn OPML documents (outlines) into a DMOZ style directory; this will eventually be implemented (shortly) so that separate OPML files can be used for parts of the tree. This way, I can let many people contribute by publishing OPML documents to HTTP-accessible locations, and include them when the directory gets rendered.

I realized that _now_ is the time that I should start a “Docs” portion of the site RE: the site itself. Someone else may, someday, need to take over management of this site. If I don’t, I’ll become indespensible…

Comments Off

Apr 19 2002

Default Templates

Published by matt under Uncategorized

I have completed the default templates for cs-ed.org. Now, new blogs will all come in looking and behaving the same. This, I think, is a good thing.

Also, all the blogs should render just fine under older browsers; editing them under old browsers will still be painful, but I’m not about to go hacking on the application itself.

The blog portion of the site is open for business!

Update 21:17:

Pete’s blog went in without a hitch, as far as I can tell; apparently, the default templates worked exactly the way they should.

Comments Off

Apr 18 2002

From Netscape 4.79

Published by matt under Uncategorized

From Netscape 4.79 (Solaris) the interface for adding entries is rough, but manageable. I’d really recommend *all* posting take place by writing in some other editor (vi, Emacs, anything), and then copy-paste into the browser.

And, for some reason, under Netscape6, the text doesn’t wrap. So in editing this post, everything just shows up on one (unscrollable) line. And if I force line-breaks, then the breaks show up on the WWW page, too… that is annoying. So, Netscape 6 under Solaris is not a good way to actually write entries…

Of course, when hard-pressed, or just making generally short posts (which most of our posts will be), the browser should work just fine.

That’s it for comprehensive testing; the site mostly works.

Comments Off

Apr 18 2002

CSS-free templates

Published by matt under Uncategorized

I managed to build a master template yesterday that is template-free. It renders nicely on IE5.5 Mac (OSX) as well as Netscape 4.7 (Solaris). That checks two extremes of the browser spectrum; it should render cleanly everywhere.

I need to remake a few other templates to get this completely CSS-free; I’m not sure about all the editor pages (where entries are created, etc.); I’ll have to test that later.

The good thing about this is that I can integrate the dynamic stuff (”Most recently updated, etc.”) directly into the master template; every new weblog on the site will be consistent and ready-to-roll. Furthermore I can easily keep the master blog templates consistent with the main site template. This will probably drift in the future, but for now I can keep fairly tight integration.

Comments Off

Apr 17 2002

Current Events

Published by matt under Uncategorized

Currently, a few things are up and about:

  • cs-ed.org is a brainstorm between myself, Pete, and LisaK. Fifty bucks and some politicking, and you end up with more work. I’m glad we’re rolling on this, and am excited about the possibilities.

  • The LEGO->Mindstorms compiler is coming along, but docs need to be posted. That will be the subject of later posts.

  • The semester is ending in a week; much to do in closing things out.

Comments Off