Slashdot Mirror


Fun with LEGO Mindstorms Programming

rhempel wrote to us about an interesting LEGO Mindstorms programming tool he's created called pbForth. Click below to learn more about it - but let's talk about Mindstorms programming in general. What else is everyone using? What's the coolest thing you've done with them?

I've developed pbForth, a port of a rather archaic programming language, for the LEGO Mindstorms brick. The cool thing about it is that with a dumb terminal emulator that does ASCII uploads and can handle XMODEM (checksum) transfers, you can compile applications right on the brick! Yes, on the brick! When you are done, you blast S records back to your PC using XMODEM and then you can reload the app anytime using one of the standard firmware uploaders.

Check out pbForth for LEGO Mindstorms

pbForth got a whole chapter in the O'Reilly book, and it is getting more and more momentum as replacement firmware that busts the 32 variable barrier, and allows total cross-platform development without screwing around with building ecgs.

OK, I'm biased - I wrote it - but I think it's cool. Maybe some of you LEGO gearheads out there would like to try programming in something other than the native tongue. Learning Forth can make you a better C programmer. No, I'm not a Forth evangelist - I write embedded systems in C all day long.

183 comments

  1. Re:star wars by NastardATT · · Score: 0

    first post? and i just KNOW its gonna get moderated down. sorry :/

  2. Hmmm. by Signal+11 · · Score: 1
    Isn't Fourth the only other language besides Fortran where you can redefine the value of four?

    1. Re:Hmmm. by Anonymous Coward · · Score: 0

      The Fourth Language is a subset of Fortran.

    2. Re:Hmmm. by ucblockhead · · Score: 2

      (Forth, you mean)

      You can also set your output to base 3, or 9, or 37!

      (You can even set it to base 1, but don't expect to get an answer real soon...)

      --
      The cake is a pie
    3. Re:Hmmm. by auntfloyd · · Score: 2


      Yes, but that's a feature, remember. They designed it so that all programs could be forwards compatible if the value of 4 ever changes (which is good, since the ISO is now working on the Number89 standard, which is characteristically several years late (C9X, anyone?))
      ~~~~~~~~~
      auntfloyd

    4. Re:Hmmm. by Trepalium · · Score: 1

      This is a really important feature. You never know when the apocalypse will strike and the number 4 will simply cease to exist! Or if 8 and 9 suddenly vanished, and we were all forced to change the entire world to octal!

      --
      I used up all my sick days, so I'm calling in dead.
    5. Re:Hmmm. by gergo · · Score: 1

      C99 was ratified a couple of months ago (November, I think), and some posters on comp.lang.c say it was published a few weeks ago.

    6. Re:Hmmm. by Anonymous Coward · · Score: 0
      aren't people who complain about karma whores the only thing in the world more irritating than karma whores?

      Money__ is irritating, true, but he at least has a purpose: to filter the obvious in such a way that it looks like he found something interesting or insightful to anyone who hasn't followed the link at the top of the article. But since so much of the /. population never, ever follows the links attatched to the articles, Money__ is almost neccicary as a summarizer for those who just skip to the comments. Slashdot should have him do it on every article and pay him a salary, or something. I dunno.

      The grits/portman people are irritating-- Segfault should have considered when they shut off their comments that their posters would just migrate elsewhere-- but at least they have some kind of nihilistic dadaist artistic integrity. You can almost forgive them.

      But you, mr. a.c.. mr. whore to the karma whores.. you serve no purpose. You have no integrity. You are nothing more than signal noise. You contribute nothing, you do not perform any useful function, you get in the way of us trying to discuss, you take up space. go find something meaningful to do with your time..

      -bmmckhk
      i feel cowardly

    7. Re:Hmmm. by mayoff · · Score: 1

      Was that a troll? In case it wasn't: Forth is not a subset of Fortran, nor a superset. Fortran is a second-generation language. Forth was intended to be (and perhaps is) a fourth-generation language (hence its name). They have essentially no common ancestry and are completely different syntactically.

    8. Re:Hmmm. by Anonymous Coward · · Score: 1

      Perhaps, but can you redefine 1900 to be 2000??? ;)

      Tom

    9. Re:Hmmm. by linuxaus · · Score: 1

      The verb, the spelling and the claim are only errors if you define them to be. In Forth can define our own language. Nerds may prefer Lego, Geeks prefer virtual Lego ;o}

  3. Just Forth? by DrPsycho · · Score: 3
    If Forth (or in this case pbForth) can be adapted to program the LEGO Mindstorm bricks, what about other programming languages?

    I for one would love to see Perl for LEG0. Do any such extensions for Perl exist, or are they in the works? Could other languages be adapted for LEGO? Forth is admittedly rather archaic, and few people program in it any more. Might open the appeal of the Mindstorm to a greater community.

    Oh. Who am I kidding. Every geek wants LEGO. :^)

    --

    -DrPsycho - Coping with reality since 1975

    1. Re:Just Forth? by dlakelan · · Score: 1

      Scheme (a dialect of Lisp) is a great language for Lego Mindstorm. The syntax is simple, it could be byte-code compiled easily. There are tons of implementations to start with. It's often used to teach introductory programming, and some of the best CS texts are written towards Scheme.

      "Structure and Interpretation of Computer Programs" and "Scheme and the Art of Programming" for example.

      The biggest problem would be the garbage collector, but that problem is not a huge one as incremental real time garbage collectors exist, and the interrupt handlers would all be written in something lower level anyway.

      Anyone want to take a stab at making "Mindthtorm" (lego LISP)??

      --
      ((lambda (x) (x x)) (lambda (x) (x x))) http://www.endpointcomputing.com a scientific approach to custom computing.
    2. Re:Just Forth? by cobra1729 · · Score: 1

      Hi DrPsycho, 1. About PERL...you can use LegOS..this is coool, since it replaces the firmware just like PbFORTH..but...it can be used in EITHER Linux or Windows. Personally, I want to use Linux..but I havent properly installed the cross-compiler in my laptop..I have to do it. Anyway, LegOS requires PERL..although the language used is C. Just go to Yahoo and search for LegOS for a whole bunch of websites. In addition, there are some web based cross-compilers. If u want to use PERL..suggest u download the code for LegOS for linux and modify it yourself to include PERL. But the default C language environment is AMAAAAAZING!!!!!! 2. There are other environments too...like NQC (Not Quite C), but they have some limitations. I suggest that if u really want to have fun, use LEGOS. 3. I am writing this because I am interested in robotics..trust me, LEGO MINDSTORMS IS AWEEEESOME..and it is really cool for robotics..other than buying a microcontroller board and building the robot from ground up. You are going to understand the Hitachi controller anyway if u want to do some really cool stuff. I suggest that u buy the kit (or the RCX at least) and try it out....have fun....its really cool to tell a robot to go and open ur refrigerator for you!!!!

    3. Re:Just Forth? by postphix · · Score: 1

      Actually, you can also use VB. This semester myself and another student built a robotic arm and programmed it using the pBrick interface from LEGO. LEGO's tech support was stumped every time we called them for a little clarification on the VB/pBrick interface, but the VB code is easy enough to allow someone to mess around with the brick and not damage too much by the way of gears and such. This robotic arm was then trained to respond to voice commands handled by Dragon Point & Speak. We currently have plans to interface it [the arm] with the web, but we need a little more time to get that taken care of. If you'd like to know more, email me.

      --
      Remember, it's all fun and games until someone loses a chromosome...
    4. Re:Just Forth? by nickm · · Score: 1

      Forth is actually a runtime environment. pbForth is more of an OS for the mindstorms than anything else. Forth is a stack-based language that does everything in postfix notation.

      FORTH is very extensible and often FORTH programs tend to be smaller than their procedurally-written assembly counterparts.

      FORTH uses a dictionary to store the built-in and user-defined functions, and the definitions of words (think functions) can be treated as a stack of definitions as well! So a program can redefine a word several times, and then pop definitions off the dictionary until you get back to the original.

      My friend George Perry (who is a member of the Silicon Valley FIG) often tells me that FORTH lets you shoot yourself in the gun. I once accidentally redefined the number 12. I believe it.
      --
      I noticed

      --

      --
      I noticed

      It's getting about time to leave everywhere

  4. Hmmm... by Signal+11 · · Score: 2
    An X Windows terminal made out of legos... hmmmm. Well, the Etch-a-sketch models worked real well when we deployed them into Sales... =)

  5. NQC by Khan · · Score: 1

    While I'm still new to the LEGO Mindstorms field (just got it for Christmas) I have found that NQC is a really good for programming that lil "brick". So far, I've only been toying with the ones that come with the book. But, I'd certainly like to make a few fighting robots. I love to watch the pieces fly off ;)

    --

    "Klaatu, verada, necktie!" -Ash

    1. Re:NQC by [Marvin] · · Score: 1

      Funny thing, LEGO said they'd never make 'war' toys :o)

      (offtopic: what about all those new product lines
      where there's one 'house'/ 'clan' / whatever fighting against the vile Bogons over some mineral ?)

      Anyway, isn't there some limitation on that brick thing? I can't remember ever seeing it do more than one thing at a time...

    2. Re:NQC by AndyL · · Score: 1

      They can only have 3 inputs and 3 outputs per brick. I suppose if you had to RCX bricks you could use the IR to link 'em together and then you'd have 6 outputs and 6 inputs. Has anyone tryed this?

  6. Give your old bricks new life by Wizard+of+OS · · Score: 1

    I've always loved LEGO (since I was 5 or so) and when if first heard about Mindstorms I almost went insane. I've bought that they-say-it's-programmable-but-in-fact-it-isn't control station but when I first started programming (when I was 12) that just didn't attract me any more.
    After all, I'me glad I started programming C, but lego still has a 'special place in my heart'. This slashdot article brought the entire feeling back. It makes me want to run to the nearest toy-store and buy that Mindstorms set. (too bad it's sunday and 0:34 Am ;).
    Can anyone tell me how far this Mindstorms-programming thing goes? Might it actually be possible to create your own Aibo?? ;)) (those things are neat!! :)

    --

    --
    If code was hard to write, it should be hard to read
    1. Re:Give your old bricks new life by giberti · · Score: 4

      As with any great toy, there are limitations, but here is the low down for thoes who dont know about this little toy yet...

      Out of the box its a PLC type system with three in's and three out's... It comes with two motors, two on/off "touch" sensors and one ir sensor... It also has (but not talked about) its own built in IR sensor which it can use but requires using some slightly more advanced programming languages than the one included.

      There are all types of Visual Basic programs available, but thats all I have seen so far. The lego site talks briefly about it I belive.

      There are also add ons available for it... a heat sensor, a rotational sensor and of course more motors.

      The toy is pretty nice, but really requires some patience engineering the remaining bricks to do what you want, and as always, if you dont have some legos already, you will want to go and get a few kits, because you will be limited despite the large quantity of bricks included.

      Hope this helps clear some stuff up.

      --

      AF-Design, web development.
    2. Re:Give your old bricks new life by Anonymous Coward · · Score: 0

      Something that most people don't know, is that once you have your IR tower to program your RCX, you can also program the mid-range set (the Scout brick). This brick can then be used to program the one in the Droid Developers kit. :)

      Read on....
      http://www.legomindstorms.co m/products/rds/hackers.asp

    3. Re:Give your old bricks new life by Anonymous Coward · · Score: 0

      I've had one since they first came out, so I think I can say I'm a veteran. The programming varies. The one you get in the set is like a Pinto with no reverse gear. NQC (or RCXCC) is like a reliable car and pbForth and LegOS are like hot-rods. If you're into programming go all out and use pbForth and LegOS, but be warned...it takes some setting up. And someone has built a Lego "dog". It takes 7 RCX bricks to control it's various points of movement. Not sure about the programming heirarchy though. But I've seen people with everything to an M&M sorter (by color) to a VCR (that plays little Lego tapes you also make) to a scanner. It's unreal what some people can make.

  7. question(slightly OT) by NastardATT · · Score: 1

    i remember the story about the expensive robot maids, etc, and someone saying that these guys are just as useful. i havent had a chance to check them out, but im wondering exactly what they are capable of. the backs of the display boxes are pretty lax on information.

    i would gladly spend a hundred bucks for something that can retrieve the remote control for me.

    1. Re:question(slightly OT) by Anonymous Coward · · Score: 0

      So you want a remote control to get the remote control for you? How about a remote to fetch that one too?

  8. Perl for Legos? by Signal+11 · · Score: 2

    I, for one, do not want to see perl on legos. While the string handling is really great, it's a write-only language. I mean, with the standard legos you can take them apart and reassemble them in chunks... but with perl, once you assembled it the nanobots would come out of the controller box and glue everything together. Write-only legos... oi.

    1. Re:Perl for Legos? by kuro5hin · · Score: 1
      Perl is only write-only if you don't know how to read perl.

      By the same logic, no one should use the cyrillic alphabet because I don't know it.

      I'm rather sick of hearing "perl is a write-only blah blah blah." Is my annoyance apparent yet?

      "Moderation is good, in theory."
      -Larry Wall

      --
      There is no K5 cabal.
      I am not the real rusty.
    2. Re:Perl for Legos? by Anonymous Coward · · Score: 0
      I suppose that my grandmother can read Java code? What? She can't? Oh.

      Let's try Python on her. Damn. That failed too. Ok, maybe you're right. It's FUD.

    3. Re:Perl for Legos? by Anonymous Coward · · Score: 0

      I have myself started using perl quite a bit to program things ehre and there, however once thing I think us perl programmers still have to concede is the fact that perl is a much more write-only language than others. Part of the problem is in its own design, who cares if you have 10 different awy to do an if. No one needs 10 different ways to do the same if statement. This just leads to obscurity and decreases legibility. In C, the syntax is if ( condition ) { statements }, in perl you can do if ( condition ) { statements }, statement if ( condition ), unless ( !condition ) { statements }, statement unless (condition) . 3 ore ways to do a simple if statement is not beneficial. Its detrimental. This might sound like a cool thing to have at first, but when you are wokring on large projects with quite a few people, having to parse each programmers idiosyncracies SUCKS.

    4. Re:Perl for Legos? by Anonymous Coward · · Score: 0
      You never write unless (!condition). You've misunderstood the purpose of unless. It's there to make things easier to read, not harder. It's too avoid having to write the confusing "if not".

      And don't be so sure that C has "only one way". It doesn't. You can write f() && g() or if (f()) g(); or if (f()) { g(); }

      I agree that bad Perl code is hard to read. I hope you agree that bad C code, bad Pascal code, bad FORTRAN code, and bad BASIC code are also hard to read.

    5. Re:Perl for Legos? by uh · · Score: 1

      Yes I agree all Bad code is hard to read. However, perl is more prone to bad coding practices since it is much more loose in its syntax.

    6. Re:Perl for Legos? by Anonymous Coward · · Score: 0

      Give me a break! Adding an additional condition does not change the sytax of the if statement! You've show us one additional variant by leaving out the braces... Guess that means Perl has 6 ways eh?

    7. Re:Perl for Legos? by kuro5hin · · Score: 1
      It is also better suited to some tasks than languages that enforce good coding practices when they aren't needed and would be detrimental to the program at hand.

      "Moderation is good, in theory."
      -Larry Wall

      --
      There is no K5 cabal.
      I am not the real rusty.
  9. Hmmm. by Anonymous Coward · · Score: 0

    Isn't Signal 11 the only other poster besides Money_ who's only purpose is to be an absolute karma whore?

  10. Variables by stuyman · · Score: 2

    The reason tools like this are so important are of course variables. I mean what programming language is complete without something as basic as variables? Unfortunately, the default mindstorms "language" doesn't really have variables, and we had to pull off some rather absurd tricks in my high school robotics class to emulate them. It was unfortunate that the teacher wouldn't let us use something different like pbForth. I don't know what his problem was :(, then again he also loved NT.

    I think I'm going to try and convince him to use pbForth for future classes, anyone know of other schools (highschools in particular) doing such a thing now? Our problem is that the classes primarily contain normal students with no programming knowledge, so this might sharply increase the learning curve. Any ideas on how to make programming simpler to the non-geek/techie?

    --
    Q:Doctor, how many autopsies have you performed on dead people?
    A:All my autopsies have been performed on dead peop
    1. Re:Variables by Bitsy+Boffin · · Score: 1
      I mean what programming language is complete without something as basic as variables?

      Languages of the `(pure) functional' class do not have variables of any kind. They are still very complete and useful work can easily be performed with them. See for example HUGS although IIRC HUGS (and Haskell) is not a strict/pure functional language.

      --
      NZ Electronics Enthusiasts: Check out my Trade Me Listings
    2. Re:Variables by WorldMaker · · Score: 1

      My only guess on a way to make pbForth easier for non-Geeks would be to create an IDE similar to Lego's that comes with MindStorms, but make it teach pbForth as it went, as well as give you a choice to switch between "Code" views and "Graphic" views... Anyone interested in outdoing Lego's IDE for pbForth?
      WorldMaker

  11. LEGO programming languages by NastardATT · · Score: 1

    im waiting for LEGO QBasic

  12. Forth! by billsf · · Score: 1

    That is my first programming language. Very cool and very extensible. I am very happy to see it still alive.

  13. NQC (Not Quite C) by mafried · · Score: 1
    My little brother has been playing around with Lego Mindstorms for quite a while, and he just got the Official and the Unofficial (O'reilly) books on the little robots. One of the books came with a CD containing a compiler called NQC, or 'Not Quite C'. As a linux hacker (not cracker), this caught my eye. Apparently it comes with a small compiler that is capable of compiling C code (or at least stuff that looks like C), and then sending it to the RCX (central part of robot) for use.

    I would like to know just what the capabilities of this little compiler are. Has anyone used it? Does it come with a fully functional set of libraries? If so, this might be a rather useful (or at least fun).

    1. Re:NQC (Not Quite C) by Ethan · · Score: 1

      My little brother also got a MindStorms set for X-mas, and the first thing I did when I found out about it is dl'd NQC and packaged up a nice RPM for him...

      It actually seems to be very capable and easy to use. It lets you use the multitasking capabilities of the RCX in a simple fashion (although I can't find semaphores or mutexes anywhere :-P), but it has LOTS of power. Certainly more than the provided tools.

      It also has variables, as an above poster lamented about the provided programming tools. ;-)

    2. Re:NQC (Not Quite C) by Anonymous Coward · · Score: 0

      As far as I know, there isn't anything (or maybe only a few things) you can't do with NQC that you could with a straight ASM bytecode compiler. The fact that you can use NQC to send straight bytecodes helps. ;) I'm fairly certain you can't do anything with the native PBX language from Lego that you can't do with NQC. --Aaron Plattner

  14. Perl is *LIKE* Legos by SheldonYoung · · Score: 2

    Perl is much like Lego... you can put almost anything almost anywhere. Just instead of innies and outties Perl has lots of punctation and even more context.

    1. Re:Perl is *LIKE* Legos by Anonymous Coward · · Score: 0

      Perl has punctuation to make it easier to read.

  15. Re:star wars by Anonymous Coward · · Score: 0

    What a dumb-ass. If you /reply/ to a message, do you really think you're going to get first post?

  16. No perl by morven2 · · Score: 4

    Perl is NOT suited to embedded programming. Perl is huge. A Forth interpreter is tiny, and Forth bytecode is tiny. Forth was written for embedded systems.

    Perl is best suited to larger systems, as a good method of tying together the extensive resources available on such a machine. It's just not suited to a tiny system.

    1. Re:No perl by seaportcasino · · Score: 0

      It would be cool if it was possible to run a web site from a lego brick :)

    2. Re:No perl by Anonymous Coward · · Score: 0

      Apache uses Perl as its embedded programming language.

    3. Re:No perl by Anonymous Coward · · Score: 0

      So does vim.

    4. Re:No perl by Anonymous Coward · · Score: 0

      Anything else clever to add to that?

    5. Re:No perl by Anonymous Coward · · Score: 0

      1) We're talking about a different kind of "embedded" here. Embedding a programming language means to put the interpreter into a second program so that it can make use of the interpreter. For instance, there is a scheme interpreter embedded in the Gimp, so that you can use Scheme to script plugins.

      2) Apache *can* use Perl as an embedded language, but that doesn't mean that it necessarily does. By default it does not. You can also get Apache modules for Tcl, Python, Ruby etc etc etc...

    6. Re:No perl by SEWilco · · Score: 2

      Nope, as I don't have Text::Clever installed.

    7. Re:No perl by PhiRatE · · Score: 2

      Bah. Comparing Forth and perl is like comparing Assembler with C, Forth may be tiny, but it also has a fraction of the functionality. Not to mention the fact that people writing Forth directly are .like this talking up end to liable

      I think the current processor architecture of assembler->C/Forth->Pascal/Lisp/Perl is an effective one, which suggests that mindstorms should exec an assembler variant.

      On the other hand, it is worth noting that as stated, Forth lends itself heavily to small interpretor size. Stack languages are trivial to implement, and one can always compile from another language down to the forth interpretor.

      Personally, I'd go for asm if possible, multiple registers and all that. But if that isn't an option for some reason, Forth plus a good compile-down language would be fine :)

      --
      You can't win a fight.
    8. Re:No perl by Anonymous Coward · · Score: 0

      Clearly you are not familiar with Forth if you think it has limited functionality. It is an elegant and expressive language which can be used at any level of abstraction you desire; no less powerful than C, and there are those who consider it far more powerful in terms of programmer productivity.

    9. Re:No perl by Anonymous Coward · · Score: 0

      Body::Brain???

    10. Re:No perl by PhiRatE · · Score: 2

      If you read my message, you'll note that I put C and Forth on the same level. However neither C nor Forth offer the functionality provided by perl, so it is an invalid comparison. Perl, as with Python, and many other languages, offer considerable built-in functionality not directly supported by systems languages. Built in regex, garbage collection, high level data structures etc. Forth, at least at its current ANS state as defined in http://www.forth.org/dpans/dpans.html, does not support the majority of the higher level features.

      --
      You can't win a fight.
    11. Re:No perl by dcs · · Score: 1

      Forth offers all functionality needed to PROVIDE the features you mention. You can extend the language until it reads Perl code, if you want. The other way around is not possible, though...

      So, which is the higher level language?

      --
      (8-DCS)
    12. Re:No perl by PhiRatE · · Score: 2

      According to classic computer science terminology (http://www.magicnet.net/~emil/technol/compsoft.ht ml) perl is high level, forth is mid level.

      --
      You can't win a fight.
  17. Not Quite C by LordStrange · · Score: 2
    For my money I pick NQC! There's ports for Linux, Mac, and Windoze.

    If you use windows try Mark Overmar's RCX control center. It's a keen IDE with a bunch of other kewl features like remote control, var watches, and more!

    --

    License: By reading this you are agreeing that you agree with me.

  18. Your Lucky... by Anonymous Coward · · Score: 1

    Your lucky to have a high school computer teacher who even knows anything about computers. Ours is constantly stoned and preached karel++ all day long. Ugh!

    1. Re:Your Lucky... by Wakkow · · Score: 1

      Closest we have to computer teachers are the new teachers that teach typing and QBasic.. Yes, QBasic... *shrug* Oh! And our AP Physics teacher doesn't like physics.. He majored in Zoology in college..

      Daniel

    2. Re:Your Lucky... by Anonymous Coward · · Score: 0

      One of my high school computer teachers didn't know jack squat about computers, and was a fungus major in college. Jeez, the pain I went through in that class.... It never ceases to amaze me how stupid some people can be.

    3. Re:Your Lucky... by Anonymous Coward · · Score: 0

      Don't worry, they're all like that. My programming teacher taught karel++ the first half of the class (this was the advanced class-no TI-basic) and then let us screw around with C++ the rest of the time because he was a complete slacker.

    4. Re:Your Lucky... by Anonymous Coward · · Score: 0

      You evidently didn't have English teachers as well (or didn't pay much attention to them)

  19. Mindstorms by dallas · · Score: 1

    I want to get Lego Mindstorms, but over a $100 for
    Legos just doesn't seem right to me. Can anyone
    (Who owns them) tell me if they are worth $100?
    What can you do with them? If they would go down
    in price I would buy them right now. I fell anyone
    that spends over $100 for legos, needs to check
    their priorities. Sure they are neat but you could
    get stuf for your computerwith that money. For
    that much money you could get more RAM, a burner,
    speakers, zip drive...etc..

    1. Re:Mindstorms by giberti · · Score: 2

      But when you have all the computer toys you want, and the ones you dont cost far more than a few hundred dollars, is it not worth it?

      --

      AF-Design, web development.
    2. Re:Mindstorms by xianzombie · · Score: 2

      granted, that for over 100 it was kinda high priced...i just bought mine saturday. It was actually over 200 for the full mother load set, and then for 6 AA batteries and a 9 volt. As with some other ppl, i havent touched legos for several years and have been working basically out of the book for the models for now, however they are fun to play with, i have yet to make anything productive with them, though i do feel that over time its possible (just make sure you have some old parts to through in if u want to get creative... They're expensive, but there fun lil toys

    3. Re:Mindstorms by Our+Man+In+Redmond · · Score: 3

      You're not paying $100 (or $200 or whatever) for the Legos. You're paying for a really cool, really small computer that happens to come with a bunch of Lego bricks and other accessories (sensors, motors, and the like).

      I don't know just how cool it is yet, though. I got a set for my son for Christmas and he hasn't yet let me near it.
      --

      --
      Someone you trust is one of us.
    4. Re:Mindstorms by TomlinXS · · Score: 2

      In simple math, yes it's well worth it. I usually spend between 45 and 50 for most PC games and can finish most of them in under two days. Some longer more involved games may take me 4 or 5 days but you get the idea. When I got my Mindstorms I played with them for 18 hours straight but now I'm down to 4-5 hours/day. If I were to add up all of the time I've spent with the Lego's it would cost me about $700 to get the same amount of "rec time" from games. Since I've gotten them I've worked through all of the "book models" and all of the challenges and then started making my own stuff. The two coolest was one that launched the a vehicles driver from the drivers seat when it ran into an object (moustrap not included) and a rotating mount for my web cam (got that for christmas) that rotates about 10 deg every 20 seconds. It covers about a 120 deg arc and reverses direction at each end.

  20. (Not funny) Re:Hmmm... by Anonymous Coward · · Score: 0

    Thank you for this stupid Dilbert rip-off. It might be funny if it was Original, but It is not.

    As usual, Sig*11 is whoring for points.

    1. Re:(Not funny) Re:Hmmm... by Anonymous Coward · · Score: 0

      Poor AC, why are your undies in a twist? Humor is rarely (big-O) original, and neither is your incessant whining. Why don't you do something positive, like maybe think of something funny that you can write on slashdot? That would probably make you feel better than ripping on others to build yourself up, but you won't know until you try it. Go ahead, give it a shot! :-)

  21. Re:star wars by ODiV · · Score: 0

    I love seeing people call others stupid when they have no idea what they're talking about. Good show, you've made my night. :)

  22. WOW! by Anonymous Coward · · Score: 0

    This is fabulously compulsive! i recognize that it is off-topic, but the parts (each stanza) are modular, not unlike legos. Throw the man a bone for having a little chutzpah, folks!

    1. Re:WOW! by Anonymous Coward · · Score: 0

      I love haiku. I love Natalie Portman. Good job.

      -WtC

    2. Re:WOW! by Anonymous Coward · · Score: 0

      and I love you.
      marry me, my dearest!

  23. WebCam mount, NQC, legOS by Fastolfe · · Score: 5

    Firstly, legOS is a really cool project. They've totally re-written the firmware for the RCX and built a fully pre-emptive multitasking environment running programs you can write in C or C++ and compile with a gcc cross-compiler. Very cool stuff, though the networking support (IR) doesn't seem very usable just yet.

    NQC uses the standard firmware I believe, and is a bit more solidified. You write programs in a pseudo-C language and compile/upload it using the NQC utility. It also has some good IR message passing abilities.

    Information about both of these can be found at LUGNET in the robotics section.

    I experimented with LegOS a while back but ended up using NQC and a bunch of server-side Perl to build myself a telerobotic camera mount for my webcam.

    There are definitely tools available out there for some extremely flexible Mindstorms programming.

    1. Re:WebCam mount, NQC, legOS by Hrunting · · Score: 4

      I live in the same apartment as this webcam and actually built the camera-holding assembly. Being the humble dood that Fastolfe is, he fails to go on about some of the actual features in this webcam.

      The assembly is built solely from the parts that I received in my Mindstorms kit a year ago (no add-ons, no extra sets). One motor runs the manages the rotation in the horizontal direction (spin) and the other manages rotation in the vertical direction (tilt). The whole thing sits about 8 inches high and the RCX unit does not form part of the base (we have it slightly separated since the IR signal comes from another computer across the room).

      The program keeps track of spin and tilt so that users can't spin it all the way around (tangling up the cord in the process) nor can they tilt more than 90 degrees in any one direction. The program also allows a certain point to 'marked' as the initial starting point for the tracking, and there's a handy reset feature (not available outside the internal network). He also wrote the telecam daemon that resides on my Linux box that handles the actual control of the webcam (the web stuff is on a different server).

      Streaming is handled by (*gasp*) a Windows program, Webcam32, that actually came with the Java code necessary to the streaming. It was a nice little package. Fastolfe is currently in the process of writing his own program for Linux that will use bttv or something similar to do the same thing, but for right now, it's working pretty dandy.

      Setting this thing up isn't very difficult. Of course, with the post to Slashdot, it's getting hit pretty hard, but the great thing is, that we've gotten more feedback about potential problems (as Fastolfe said, "Finally, someone who knows how to open their Java console") in the past five minutes than we've received since we put the thing up.

    2. Re:WebCam mount, NQC, legOS by Anonymous Coward · · Score: 0

      Hey dude, I went to your web cam and and my sister saw it and she thinks you're really cute. seriously

  24. The Robotics Constructor Set by smartin · · Score: 1

    Has any one got this? I saw it at future shop before christmas and it was about half the price of the main mindstorms set. Is it usable stand-alone or do you need the base set. Can it be programed?

    --
    The difference between Canada and the USA is that in Canada healthcare is a right and gun ownership is a privilege.
  25. Re:star wars by NastardATT · · Score: 0

    not trying to start a flame war here, but i was replying to my first post. which was first post.

    sorry for any confusion

  26. Re:Same old same old. by BigMike · · Score: 1

    Or, maybe it's just playing, with toys?

  27. Re:Same old same old. by large · · Score: 1

    Aren't you being a bit hypocritical, hanging out here on slashdot? You're basically espousing the idea that any kind of technological advancement is bad (because it's all creative, after all). So why are you on a computer?

    Or perhaps you could look at it the other way - that by creating things, we're honoring the Creator (imitation being the sincerest form of flattery and all that).

  28. PRC by miahrogers · · Score: 5

    I was in the Penninsula Robotics Competition here in south eastern Virginia. We(my school's team) had to build a robot that would drive around a rectangular course and collect small white wiffle balls.

    Programming for the Mindstorms robots isn't very hard. However there are many other problems with them.

    For one you are only allowed to have three engines on a given mindstorms robot. I guess i should more accuratly say that you are only given 3 power terminals to plug your engines into, you may plug in more than three engines, but then two of them must go in the same direction.

    Another problem with the mindstorms robots is that they don't allow much room for a "smart" robot, as you are only given 3 sensors (like the engines above you can plug in more than three sensors but then two of them must respond to the same stimulus).

    Also the strength of legos in general is much worse when you try to put legos and a moving vehicle into one. Your building style will have to be entirely reformed if you plan on keeping your mindstorm alive for more than 10 minutes. The technic legos help with this a little, because they are longer and contain those neat axle shafts which we used liberally. But overall if you decide to change anything on the robot it will have to be entirely rebuilt for strengh/durability reasons.

    The last major problem with mindstorms robots is that they cost way too much. For a kit including three engines, a bunch of legos, and one cpu unit(basically the bare minimum you can get by on if you want a robot that moves), it was > 500$.

    1. Re:PRC by Poppa · · Score: 2

      That price quote is out of line. Unless that is the educator's special ..

      The standard system costs $200 in the US, with over 700 pieces including the CPU (RCX). Only two motors are in the kit, another motor costs about $20.

      Robotics are expensive, Legos are expensive, but this isn't that bad a deal.

    2. Re:PRC by miahrogers · · Score: 1

      that price quote was what it cost for those legos about a year ago. I was told the legos cost about $530. I wasn't aware the price has changed that much, i stand corrected.

    3. Re:PRC by Anonymous Coward · · Score: 0

      Actually, I priced them when they were released and the set was about $200.00 then too...

    4. Re:PRC by miahrogers · · Score: 1

      i'll emphasize again: that's what i was TOLD, i am sorry if it was wrong. Maybe they added extra legos to the set or something... geez

    5. Re:PRC by Anonymous Coward · · Score: 0

      First, the $500 set is probably the educational version. The consumer version does not come with three motors (don't call them engines).

      If you configure your sensor inputs for raw mode, you can hook up two (or sometimes more) sensors to each port. Configure them for raw mode and use the view button to see the values.

      You can also use more than three motors, but that requires some additional hardware, soldering, and other non-Lego things.

    6. Re:PRC by starman97 · · Score: 2

      I bought my two Robotics Invention Sets from toysmart with a 30% off and free shipping net 'coupon' for a total cost of $280, not bad
      for two complete kits. Now my Partner and I can build our own machines and not have to fight over the RCX or other parts. Also, get one of the big Plano fishing tackleboxes, lots of nice little compartments for little Lego bits, and room in the bottom for your robot and the IR box.

      Pitsco has extra prats and the Robolab (LabView) software for $25, that makes 5 different environments for programming the RCX.

      Lego's RIS 1.5 graphical
      National Instruments RoboLab graphical
      NQC C to RCX firmware bytecode compiler
      PbForth to Forth bytecode firmware interpreter
      LegOS H8 RealTimeOS
      Not bad for a 'toy' , if only all consumer electronics could be programmed by the end user,
      I'd love to change the onscreen menu's on a lot of my A/V equipment... I'd go out of my way to buy 'open' electronics, manufacturer's are you listening?

      --
      Starman97@Gmail.com (bring it on spammers)
    7. Re:PRC by tm2b · · Score: 2

      you are only given 3 power terminals to plug your engines into, you may plug in more than three engines, but then two of them must go in the same direction.


      Actually, you've got 3 bits there. With some (very) clever cam design, you can get up to 8 different locomotion modes going. Don't think about motors - think about shafts and cams.

      --
      "It is our blasphemy which has made us great, and will sustain us, and which the gods secretly admire in us." - Zelazny
    8. Re:PRC by Anonymous Coward · · Score: 0

      I don't know where you could have gotten that price from. No extra legos were added to the set, and the price was WAY below...kidding! Just kidding!

    9. Re:PRC by twitter · · Score: 1
      This may be off topic, and it's a little late for your project but...

      You might want to try out the Basic Stamp by Parallax. look here . It has more inputs and outputs, is programable in basic and comes with great documentation to help you figure out how to drive 59 cent Radio Shack Motors, or standard input devices and serrial communications.

      --

      Friends don't help friends install M$ junk.

  29. Re:legos are just the next step to... by Anonymous Coward · · Score: 0

    WOW! someone moderated this up to Funny!
    Jeepers! My trolling seems to be much better today!

  30. Linux distro for Lego by PraveenS · · Score: 1

    Next thing you know, they'll create a cheap linux distro for Lego, and have an IPO. Viva linuxone!

  31. Re:Same old same old. by Anonymous Coward · · Score: 0

    Hey.. Did you ever consider that if God made us in His own image, then we are like Him - and as such we have the desire to create also. As for setting ourselves up like God, Psalms say we were made a little lower than Elohim (hebrew for God). Only a little lower than God, and a cool reflection of His creativity. I for one love to create things and ask God what he thinks of them. He is one of the persons I know who can understand my code! Jesus said he didnt come to condemn people - you are doing Him no favours if you start now. As long as people don't start worshipping their lego and ascribing some supernatural significance to it then it is fine. J - close friend of the big guy upstairs.

  32. Re:Same old same old. by d4emon · · Score: 1

    Don't feed the Trolls kids!!!

    --
    _____________ Blah, blah, this is my sig, yackyty shmakity
  33. like Brecht... by Anonymous Coward · · Score: 0
    this is fascinatingly weird-- even weirder and more fascinating than the lego-haiku-statuesque-natalie-portman guy below.

    Ever notice how salshdot is like a Brecht play, with the occasional character coing in our of nowhere, singing a song and then leaving?

    wonderful! beautiful! further!

    1. Re:like Brecht... by Anonymous Coward · · Score: 0

      Beautiful, AC. Thank you for that comment.

  34. And yet here you are, using a computer and posting by morven2 · · Score: 1

    Sounds rather hypocritical to me, Mr Flamebait.

  35. Re:Same old same old. by Anonymous Coward · · Score: 0

    one word...prozac

  36. Re:dear hemos... by d4emon · · Score: 0

    Heh... :)

    A bizaro open letter to Hemos... fun read... I wonder if there is a better way to get in touch with someone, then an off-topic post in reply to a news item on a public forum message board....

    ::shrug::

    --
    _____________ Blah, blah, this is my sig, yackyty shmakity
  37. alternate plans by Anonymous Coward · · Score: 0

    ...instead of playing with legos, why not build sculptures using HOT GRITS? Say hello to Rastus the Chef (TM) for me!

  38. Re:LEGOS ARE FOR FIVE YEAR OLDS!!! by Anonymous Coward · · Score: 0

    I'm not absolutly sure about this! Look, i am a 30 years old engineerer an i bought the whole star-wars lego-collection, last year :-)

  39. Whatever happened to TC-LOGO for Lego? by koa · · Score: 1

    When I was in highschool, we had a lego robotics course that used Apple II's with a language that resembled BASIC and C rolled into one, TC/LOGO/LEGO, I made automatic weapons in that class, those short axles have good trajectory ;>

    --
    ....move along....nothing to see here....
  40. Cool! by Anonymous Coward · · Score: 0

    That kicks ass, I see that your on /. , wave your hand in front of the camera if you are reading this right now. :) Well Done.

  41. I prefer NQC... by nitin · · Score: 2

    I got my mindstorms kit a while back but i havent played with it a lot recently. I know 300 bucks (canadian ;) is a lot to spend but i think it was completely worth it since i have quite an investment in a lot of other technics lego kits. Now i am able to use all those pieces to make tonnes of stuff!

    I tried using the RCX software which came with it (under emulation on my mac) but it was deplorable.. not just slow, i found it icky to use. I tried using RoboLab (the software used in the educational market from Dacta) but that was graphical too! I finally chose NQC and so far have found it the most useful. Theres just something about whipping out a bunch of code and compiling it ;) rather than dragging a bunch of icons together and hitting 'SEND' (imho).

    the last thing i remember making is a garbage dump truck which used sensors to pickup and empty a garbage container, then drive away.. (wasnt my idea, i saw it on the web) but it was my implementation. The next thing i want to make is a wicked sports car with a rack & pinion steering and a gear box. Check out Ben's Lego Creations for ideas. He has some really neat designs.

    i also recommend the new david baum book (he made NQC) for general programming and lego design issues. I love this book. Check out his site.

    cheers,
    nitin

  42. pbFORTH, mindstorms, and alternatives. by olmy · · Score: 2

    My congratulations to Ralph on pbFORTH. It appears
    to be a great alternative to the Lego firmware
    in providing more granular control of the RCX and
    in its functionality. I especially enjoyed the
    ability to try out commands on the fly via a terminal (without having to compile or write a
    whole program first).

    At this time, however, I find I'm spending more of
    my time in NQC. It's a fantastic tool -- very C
    like and feature-rich. I find I haven't really
    run into a situation yet where pbFORTH's extra
    functionality has been required (and consequently
    the installation of a firmware different from that
    which came with the RIS).

    Ultimately, I'm not sure I need to spend the time learning FORTH, just to play with legos.

    Last, I have no opinion of legOS, since I haven't
    tried it yet. It looks very cool, though.

    It's probably worth mentioning that most of these
    alternatives are due to the reverse engineering
    of the RCX done by Kekoa Proudfoot:

    http://graphics.stanford.edu/~kekoa/rcx/


  43. Stop posting by Anonymous Coward · · Score: 0

    You're an idiot.

  44. God is the LEGO master what are you talking about? by Anonymous Coward · · Score: 0
    God made us in his image.

    Thus, we make computers/robots in our own.

    Aside from Lego (I do love the stuff) Robotics in general is not an attempt to 'out-do' God's handiwork but if anything, to admire it.

    Check out Honda's Biped and read the extensive research into human walking (about 10 years) and tell me that those engineers do not appreciate the complexity of life.


    iRobot

  45. Java console? by Anonymous Coward · · Score: 0

    How do you open your Java Console?

    1. Re:Java console? by Hrunting · · Score: 2

      In my Netscape, it's under 'Communicator | Tools | Java Console'. Under my IE4, it's under 'Internet Options | Advanced'. Setting that setting there will enable it in the 'Tools' menu.

  46. robotics by lonely_philosopher · · Score: 1

    I wanted to buy the mindstorms kit for prototyping purposes but there were too little acutator an sensors that could be fixed on the RCX.

    I was thinking a system in which multiple sensors/motors were linked via a bus would be more useful - I wonder if the RCX can be programmed to do that.

    By the way, has anyone managed to build a lego based laser guided bomb yet?

    --
    Ewww... there's some icky thing moving in my keyboard.
  47. Re:anyone who thinks he's serious.(someone had to) by porkchicken · · Score: 1

    Haha! The fundament in human anatomy is the lower part of the body; the butt-cheeks. In ornithology the fundament is also called 'the vent...' Kind of a double entendre I suppose...

  48. Fun Fun by SuperJ · · Score: 1

    I like to make Beowulf clusters out of 'em!

    --

    Sheepdot: Open Source good, Closed Source baaaaaaad!

  49. Re:Same old same old. by Anonymous Coward · · Score: 0

    Man, you have been reading Dune too much....

  50. Mindstorms™ is sort of limiting by Ptolemy+Too · · Score: 4
    I have a bit of a bias, here: as a programmer and a homeschooling dad, I've long wanted to write a good Intro To Programming book. I thought Mindstorms(TM) might be a good medium for that. But it's not: Doing anything with Mindstorms(TM) is as much (or more!) mechanical engineering as programming.

    At first I thought, oh, that's OK. That still involves problem solving and working with constraints, yes?

    But what constraints! Forget any notion of building Rodney Brooks-like robots: You get three sensor inputs. Even if you were willing to spring for lots of extra-cost sensors, and used some clever multiplexing schemes, you'd be hard pressed to build an insect that could even know whether its legs were up or down, forward or back.

    And seemingly simple robots have a way of using up the parts that come in the standard set. Once you've built a track following robot, what do you do with it? You've used up both motors. Similarly, once you've built an arm that can raise/lower open/close its claw, you've used both motors, both touch sensors, and most of the gears and structural pieces.

    I'm afraid that I lost interest pretty quickly.

    1. Re:Mindstorms™ is sort of limiting by tlhIngan · · Score: 3

      Here's a way to imitate more sensors/motors, assuming we can do it with a mindstorm (I don't have one, so this is just hypothetical).

      For less verbosity, I'll call the motor controls A, B, and C, and sensors 1, 2, and 3.

      Additionally, I'm assuming the motor outputs are tri-state (forward, off, reverse), but sensors are binary (shorted, open).

      [Method 1]

      Leave A for motor control, and multiplex it via a serial output from say, B. Leave sensors 1, 2 for direct use, and make 3 a multiplexed one. Contol the sensor multiplexor from C.

      [Method 2]

      Use A, B for motor control. Use C to control multiplexors for both motors and sensors. Again, sensor input 3 is multiplexed.

      [Method 2.1]

      Control motors by using a positive-going multiplexing scheme, and sensors by a negative going (reverse) scheme.

      [Method 3]

      Again, A is for multiplexed motor control.
      Again, 3 is for multiplexed sensor control, 1, 2 are regular sensor inputs.
      Use B as a clock, and C as data to control a shift-register, whose outputs connect A or 3 (as appropriate) to inputs.

      I'm not saying that the constraints aren't limiting, just be imaginative and try to think of something. I don't know if these ideas work or not, but they're ideas for people to try, perhaps mess around with, which can lead to more ideas. Perhaps try various constrained microcontrollers (very little RAM (from bytes to countable kbytes), low clock, constrained instruction set, low program memory count [there are processors that separate program instructions from RAM]), like Basic STAMPs, PICs, to more "expansive" processors like a HC11.

      The challenge is to make things work given a constraint (usually cost) >G. Perhaps you'll make an "MindStorm Expansion Brick" that hooks up to the RCX unit and offers a lot of sensors/motor control, at the expense of software complexity.

    2. Re:Mindstorms™ is sort of limiting by anatoli · · Score: 2
      [Method 4]

      Multiplex everything via sensor output. (Yes, you can program the sensor port to do output). And you can still use this port for passive input I believe.

      [Method 5]

      Just add another RCX, make 'em talk via built-in IR.

      Moderate this down (-1, Silly)
      --

      --
      Industrial space for lease in Flatlandia.
    3. Re:Mindstorms™ is sort of limiting by rhempel · · Score: 2

      Well, as Markus Noga, author of legOS said during our "Extreme Mindstoms" panel discussion at MindFest 1999, "Form is liberating"

      What he meant was that within the bounds of a fixed set of parts and capabilities, the challenge is to do some thing useful with the exisiting parts, not to wish for parts to build bigger things.

      Just about every LEGO enthusiast goes through a bulk acquisition mode, where the goal is to get as many parts as possible. The resulting time spent sorting severely limits building time :-)

      Check out my pbForth MazeWalker for a bot you can build with just the parts in RIS 1.0 - well I added two rotation sensors and two micromotors, but you could also use touch sensors as shown in Mario Ferrari's TicTacToe Robot

      Have fun...

  51. Yes Perl! by Aighearach · · Score: 1

    I would also like to see perl available for LEGO, however it would need to be compiled perl. The idea, for me at least, would be to be able to use the language, not to be able use the interpreter. As in Perl, not perl. Clearly, running the interpreter on the brick would be as silly as running gcc on the brick.

  52. How about Assembly? by Taco+Cowboy · · Score: 1




    Forth is tiny, but assembly can be even more tinier, be made even more compact, and reach a higher benchmark in execution than Forth or any other language.

    Is there a LEGO-assembler? Any geek out here want to invent one if there isn't one already?


    --
    Muchas Gracias, Señor Edward Snowden !
    1. Re:How about Assembly? by micahjd · · Score: 2

      I got a lego mindstorms set for christmas, and haven't had as much time to experiment with it as i would have liked, but I think legOS is the coolest and most powerful environment for legos so far. It supports C or assembler, or anything else that will generate code that is compatible with the lego CPU. Best of all, it gives you 32 kilobytes, not 32 variables! I have heard that it is very cumbersome to download programs to it, but the dynamic loader in version 0.2 appears to have solved that nicely.

      I still think NQC is great for quick hacks, though :)

      --
      -- 2 + 2 = 5, for very large values of 2
  53. wootchu talkin' 'bout willis? by Anonymous Coward · · Score: 0

    umm, i think we're all wondering what this post is actually about.. can the person who posted it maybe explain it?

    1. Re:wootchu talkin' 'bout willis? by auntfloyd · · Score: 1

      Alright you bastards, it was me. Yes, auntfloyd trolls occasionally, but only when I feel the need to share something with the world. Needless to say, the material was reworked a little to make it more on topic, but it is otherwise preserved. I won't tell you the secret, though, except that it was originally about religion (windows vs. linux is really pagans vs. xtians). The two seem so close to many of us, so I hope you'll understand.

      I wonder if Hemos has read it?

      ~~~~~~~~~
      auntfloyd

  54. Legos. Yum by Magus311X · · Score: 3

    I personally use NQC becuase personally its much easier for me to deal with than the drag-and-drop interface provided with the application on the kit's CD-ROM, and IMHO I find it more flexible.

    Mark Miller has made modifications to allow each sensor input on the RCX to handle four different sensors per input (for a total of twelve sensors per RCX unit). He has also provided example code in NQC to show how to handle the situation. Here's the link: http://www.eagle-software.com/MindFest.h tm. This is a great solution for those of you who would like to use more than 3 input devices on a single brick.

    What am I doing with mine? Currently I'm trying (honest!) to create an ATV that can map out its immediate surroundings (using proximity detection [http://www.mop.no/~simen/legoproxi.htm], and input from touch sensors) so that if it gets stuck it can quickly figure out how to leave the area. I just purchased my second set and a myriad of sensors too. Joy! =)
    --

  55. Re:Same old same old. by Anonymous Coward · · Score: 0

    I have good news and bad news. The good news is that God did make Man in His image. The bad news is that we're the 2.0 version, and that velociraptors--the other featherless bibeds--were the 1.0 release, and were even closer to God's image. Yes, that means there's going to be some very scary company in Heaven. --Dave Barry

  56. My coolest thing (in NQC) by victim · · Score: 2

    Well, I wouldn't mention it, I've already been slashdotted into the ground once and that was just a quickie fu, but you asked...

    The Public 8-Ball is a robotic magic 8-ball driven by Lego bricks, RCX, and a radioshack motor (it's burnt up all my lego motors and they are just too expensive.) Hit it with Netscape and see your destiny in real time.

    And please, if anyone has a Java applet to display a stream of JPEG frames let me know, then IE users can see the 8 ball too.

    I may be slashdot resistant now. After a dozen or so people are queued for 8 ball shaking I start deflecting.

  57. Re:Same old same old. by Anonymous Coward · · Score: 0

    I hope your notion of "literal truth" recognizes the many uses of metaphor, allegory, and symbolism in Scripture. And I hope that you haven't fallen into the inerrancy heresy. Become a Bible translator for a bit and you'll lose that quickly.

  58. Legos that petrify! by Anonymous Coward · · Score: 0

    What better use than...

    LEGOS THAT MAKE NAKED AND PETRIFIED GIRLS!

    and

    LEGOS THAT AUTOMAGICALLY POUR HOT GRITS DOWN MY PANTS!

  59. Mindstorms + X10 = useful? by CausticPuppy · · Score: 1

    I just had a thought-- does anybody know of a way to get X10 remote functionality into the mindstorms computer? I have the free X10 kit they gave away a while back, as well as the MP3Anywhere wireless A/V transmitter. Building a robot that could control the lights might actually be useful, somehow, although I don't exactly know HOW useful yet.
    One way to do it would be to use the X10 serial port dongle which is a remote transmitter for any X10 device, and rig up a 9-pin port on the Lego brick, perhaps with its own power supply.

    --
    -CausticPuppy "Of all the people I know, you're certainly one of them." -Somebody I don't know
  60. librcx by coaxial · · Score: 1

    I'm using librcx and a cross-compiling gcc. I'd use legOS if I could get it to work, but using librcx and standard C is pretty good.

    I haven't done anything cool yet because I don't have enough sensors. Having a second brick would be nice too. Hmm

  61. Re:Did Bush really say that? by Anonymous Coward · · Score: 0

    What, that atheists couldn't be patriotic, or shouldn't be allowed to vote?

    The answer: YES. How else do you appeal to the xtian 'right' that runs the goddam country? Those republican bastards certainly don't 'turn the other cheek', do they?

  62. Re:Same old same old. by Anonymous Coward · · Score: 1

    Well, most of the bits about wrath are from the Hebrew Bible (aka Old Testament), which are a mish-mash of political manuevering (Deuteronomy: the laws were made to swerve the Hebrews into strict monotheism and cement the political power of a sect of priests (deuteronomites)) and ancient myths (ie, Adam and Eve comes from ancient Summeria). Prior to the Bible, the Hebrews were a few assorted Yaweh cults who also believed in many other gods, but only worshipped the big Y.

    IMNSHO, it is impossible to take the Bible literally. It would take a stunning amount of ignorance in the face of all we know about it do so. If you are going to use the Bible as a religious text, maybe study it's history and much of the pre-israelite matieral behind much of it.

  63. Re:Did Bush really say that? by Anonymous Coward · · Score: 0

    Please don't write `xtian'. It's very rude. Don't cross out Christ from our lives.

  64. I really hope someone will moderate this up. by GoRK · · Score: 4

    Here's a related topic to this whole Mindstorm business. I have a system that LEGO designed way way before the Mindstorms and even MIT's LEGO brick (which became the basis of the Mindstorms) called LEGO Technic TC. It consisted of a very simple 8-bit ISA card that connected to a black box with a ribbon cable. Basically it was a relay control card. The thing had 6 "output ports" that could either drive a motor forward and backward or operate a light. It also had two input ports for 1-bit touch sensors or optical sensors (or any other 1-bit sensor you could build for that matter).

    The whole system was programmed in a LOGO (Remember that one, geeks?) environment called LEGO TC LOGO. It ran under DOS. I have been unable to find any control programs for this thing except for the stupid worthless DOS based LOGO.

    Is anyone else still using this system? Is there anything for it under Linux?

    ~GoRK

  65. Re:Did Bush really say that? by Anonymous Coward · · Score: 0

    Only *you* can cross Christ out of *your* life.

  66. Re:Did Bush really say that? by Anonymous Coward · · Score: 0

    The X comes from the Rhi-Cho (or whatever), and has the same basic meaning as the fish symbol. In one of my other favourite sites, several of the Christians took to calling themselves 'Fishtians' and wishing each other 'merry Fishmas' after someone complained about the 'Xmas' thing.

    I guess the point is WWJD? I dunno

  67. Forth for the PalmPilot by Anonymous Coward · · Score: 1
    Hempel has done some nifty work with pbForth.

    I'd like to see an app for the Palm -- written using Quartus Forth for the Palm of course -- that would let you control and program the Lego brick directly from the Palm infrared port.

    Neal Bridges
    Quartus Handheld Software!

  68. Re: Write-only Perl (Off-Topic) by cjon · · Score: 1
    Perl is write-only because TIMTOWTDI means that oftentimes code not written by you will do things in ways that you never thought of and thus be completely incomprehensible.

    TIMTOWTDI is opposed to orthagonality. It makes it easy to learn how to do new things, but makes things harder to maintain.

    This isn't anything that can't be overcome with good comments and uniform coding style (ie: everyone in a group using the same methods), but it is a definite tendency in any language that gives you more than one way to do common tasks (this is true of C++ also).

    IMHO.
    YMMV.

    ps: my email address isn't real.

  69. You're Lucky by rnd() · · Score: 1

    You're lucky that your high school computer teacher went to college. At my high school, the computers were just used to teach typing. No programming (or anything other than typing) was taught. I'm still trying to figure out if I can take the district to court over this.

    --

    Amazing magic tricks

    1. Re:You're Lucky by Altanar · · Score: 1

      Same here. The only classes my high school offers are "Word Processing 1 & 2" Nothing like taking a class to learn how to use MS Word. Ug.

    2. Re:You're Lucky by gojix · · Score: 1

      If you want to be selfish instead of helpful maybe. But it doesn't make sense to me to sue a school district because it had limited resources to teach you with.

      Maybe voulenteering would be a better solution.

      BTW, I'm in the same boat. Typing was the only thing taught on computers in my high school.

  70. Re: Write-only Perl (Off-Topic) by Anonymous Coward · · Score: 0

    All programming languages offer more than one path to a solution. This is the nature of individual expressivity. You can't compare what a professional programmer produces with what your Aunt Maude can read.

  71. NQC at high school by mattdm · · Score: 2
    I convinced the teacher of my brother's high school robotics class that they should use NQC instead of the default software or Robolab which they could barely afford. (Small private school.) So they did. The teacher was really glad to hear that such options exist -- she had no idea. So telling teachers about this is a concrete thing you can do to improve schools.

    --

  72. Re:PRC *More than 3 motors* by Anonymous Coward · · Score: 0

    let me start off by stating that I have no experience whatsoever with the lego mindstorms, or robotics in general. However it seems to me that if you have three programmable power terminals that you could use a PAL or somesuch, along with an encoder, to run up to 8 motors independant of each other. Granted that requires a little more than being able to snap parts together, but is a robotics competition afterall, you cant really expect to win with legos alone eh?

  73. UML models running on Lego Brick by EmbedHead · · Score: 1

    I have built UML models and translated them into ANSI C, compiled with gcc (using rcx-tools) on Linux and run them on the Lego brick. [The UML modeling tool suite is BridgePoint/MC-3020 from Project Technology.]

    Actually, the H8 micro (inside the brick) is a pretty hot little micro. $200 is pretty cheap for an engineering prototyping system.

  74. Forth? hmm. by mcc · · Score: 1

    The macintosh boot mechanism-- called "open firmware"-- has a built-in Forth interpreter.

    I am of course talking out of my ass here, but i wonder if you could adapt this pbForth thing to run under Open Firmware.. and use the macintosh as a kind of replacement brain for the lego mindstorms.

    This would bring the number of things a macintosh can do without any kind of operating system to two-- the first being play Pong.

    Meaning we're two uses ahead of all you PC users. Ha! You think you're so great, with your "linux operating system".. but without Lilo, you're NOTHING!! MWAHAHAA!!

    -mcc-baka
    i got my head but my head is unravelling
    can't keep control, can't keep track of where it's travelling

  75. programming vs. robotics by mattdm · · Score: 2
    You're right in that robotics requires a lot more than just programming -- the things have to operate in the physical world, after all. I don't think that's a problem with Mindstorms but rather an issue with your expectations.

    That said, you're right that the lack of IO is constraining. You can use multiple RCXs linked via an infrared network, but that of course doubles your cost. It'd be nice if Lego would release an "RCX Pro", with something like eight inputs and eight outputs.

    (While I'm wishing, I'd also like to see a MiniRCX, about 1"x1"x2". It'd be supercool if that had a large number of IO ports, but I'd be happy as long as they were made to talk to each other easily -- you could fit quite a few in the space taken by a regular RCX, after all.)

    --

  76. Re:I prefer NQC... (Forth info) by Technik~ · · Score: 1

    I'm getting off topic, I suppose, but Legos aren't the only platform where FORTH is available and you are not going to waste your time learning it.

    Versions, free and commercial, exist for any Unix with GCC, DOS, OS/2, Macintosh, Windows, the Palm Pilot, and dozens of microcontrollers. Did you know that FORTH is part of the Open Firmware provided in the Sun and the PowerMac boot proms? (Note IEEE requires a subscription, so check out Sun's OpenFirmware page)

    The experience on one platform transfers well to another and there is lots to like about FORTH, especially when dealing with an environment with exceedingly limited resources in comparison to a PC.

    This list of FORTH implementations by platform is a little dated but should point in the right direction.

  77. sweet jesu have mercy on us all! by Anonymous Coward · · Score: 0

    chide molestas, ever' last one o' ya!

  78. Overcoming the limitations... by under_score · · Score: 1

    Well, I got to thinking pretty quickly that only two motors was a bit of a problem and even three doesn't really allow you to do too much. So, I implemented a mechanical trinary counter which allows one drive motor and one touch sensor to control an arbitrary number of drive shafts: forward, reverse and no power. The higher order drive shafts change state quite slowly, but the thing is pretty neet anyway. With this one can basically do anything as long as it doesn't require quick response times.

  79. In his Image? by Anonymous Coward · · Score: 0

    That certainly would explain man's aptitude and taste for petty cruelty and mass murder.

  80. Joystick sensor for Mindstorms by Xidus · · Score: 3

    A few days after getting my LEGO Mindstorms set, I hit upon the idea of using a joystick as an input sensor. I had an Atari 2600 in the closet with a few good controllers left, so I hacked together a method to use it with the RCX.

    Briefly, with any switch-based joystick, you can use different resistors between each direction wire and ground so that unique sensor values result which can be read by the RCX.

    When it's done, you have a 10-position switch that's very useful -- discrete values for joystick in the center, all 8 positions, and fire button pressed. (trigger RCX-mounted weaponry? Mmmm...)

    Complete info is available at http://xidus.xidus.net/joystick.html

    Have fun, and let me know if you do anything interesting with this sensor, or even if you manage to build one correctly.
    -
    $ more ~/.sig
    ******** .sig: Not a text file ********

    --
    $ more ~/.sig
    ******** .sig: Not a text file ********
  81. Re:PRC *More than 3 motors* by miahrogers · · Score: 1

    it was a strictly legos competiton. we had conciderd some sort of switch, but you still have to have some extra equipment for that.

  82. Logo by mattdm · · Score: 2
    On a related note -- the folks at MIT who did the original devel work for the RCX (they didn't have much input on the final product) are still using Logo -- they've got their own replacement firmware and development environment. Unfortunately, it's got a very restrictive license and isn't available to anyone outside of education.

    --

  83. My lego accomplishment by British · · Score: 1

    Okay, it's not Mindstorms related but...



    I finally solved a problem I've been working on for several years: a Technic four-speed transmission done my way. Sure, the SuperCar(the coolest Technic set ever) 8880 has it, but no reverse. Last friday I was really bored at work, so I laid out my (flawed) plan that has been sitting on graph paper for years, and finally ironed out the kinks. Now I just need to get drawing again and put the plans on my website, and look for a place on it(so the gears don't get in the way of each other) to implement reverse. It's tricky, but can be done.


    And after I finished that, I found an alternate way using universal joints to make odd, but nicely spaced gear combinations.

    1. Re:My lego accomplishment by Anonymous Coward · · Score: 0

      Congratulations. The 8448 that I got for Xmas has a 5 speed *with reverse* now if only it had a working clutch...

    2. Re:My lego accomplishment by British · · Score: 2

      Congratulations. The 8448 that I got for Xmas has a 5 speed *with reverse* now if only it had a working clutch...


      They did? OH great. They just launched the Sputnik of Lego transmissions. Now I gotta catch up with a 6 speed transmission. You see, that's my dream job, to actually design new Technic sets for a living. If there was a part I needed to have made, I could of just had a custom one(like filling in the gap of technic gears they have) made and introduced into the lego part family.

  84. How about PBasic? by 0rion · · Score: 1
    Greetings,

    I've read alot of hype about the Lego Mindstorm and while it looks fun I have found the Basic Stamp to be much more interesting. For those of you who don't know the Basic Stamp is a small microcontroller with a built in interpreter, and memory unit. The interpreter understands a version of Basic called PBasic (stands for Parallax Basic), and it's very simple to program. For those of you interested in Electronics and Embedded computing this is a great way to get started at a fraction of the cost (the stamp unit only costs around 35 bucks). I highly recommend these two books for starters:

    "Getting Started in Electronics" By Forest M. Mims III (Published by Radio Shack).

    "Programming, and Customizing the Basic Stamp Computer" By Scott Edwards.

    also Nuts and Volts magazine has a monthly column dedicated to the Basic Stamp. This is the ultimate in hacker toys =).

    www.parallaxinc.com has more info. Enjoy.

    1. Re:How about PBasic? by anatoli · · Score: 1
      Here is a BasicStamp FAQ. Below is my executive summary.

      The $35 version has 256 bytes of EEPROM (program memory), 7 word registers (data memory) and 8 I/O lines that can drive a LED (barely). The $59 version has 16K of EEPROM, 16 registers and 63 bytes scratchpad RAM. In order to drive a motor, you need extra circuitry. It is programmable with, well, BASIC.

      Mindstorms RCX brick has 16K EEPROM, 32K RAM, 3 outputs that can drive Lego motors directly, 3 I/O lines that can read sensors (some of them are active sensors, so there are I/O lines rather than just input lines), a built-in IR port, an LCD, a buzzer, and a couple of buttons. (And of course a Lego-compatible case.) It costs around $100. (The complete Mindstorms kit is about $200). RCX is programmable with any number of languages, including regular C and C++.

      The Handy Board has 32K RAM (upgradeable to 64K, and of course one can build a serially addressable memory too), 4 outputs that can drive DC motors, two servo outputs, 16x2 character LCD, two user-programmable buttons, one knob, piezo beeper, 7 analog and 9 digital sensor inputs, and an IR port. And, above and beyond everything, an open, documented design. It costs $200 to $300 built and tested, and is available from any number of manufacturers. PCBs are available too, cheaply. It runs Interactive C (a bytecode-interpreted C variant) and some varianto of Java.

      There is an expansion board for Handy Board too (10 analog inputs, 4 inputs for active Lego sensors, 9 digital outputs, 6 servo outputs, and general prototyping area).

      Moderate this down (-1, Obssessive)
      --

      --
      Industrial space for lease in Flatlandia.
  85. Good points, but... by Anonymous Coward · · Score: 1

    I'll agree about the grits/portman thing. Depending on my mood my reaction vaccilates between "dammit, those idiots AGAIN" to "Jesus those guys are hillarious".


    About Money__ -- people should be punished for not bothering to read articles (ie, the "-1 Redundant" moderation for posts that ask questions answered in the article), not rewarded for exploiting the lazy.


    Also, the Whores to the Karma Whores do serve ONE purpose: we OCCASIONALLY remind moderators that the post we are mocking were either off-topic nonsense or information simply filtered from the original article. This IMPROVES the signal/noise ratio (for people who sort by score; 0-5, which I believe is most of the slashdot community) because Singal11 and Money__'s mostly useless posts won't get their knee-jerk score of 5.


    Of course, some people are probably just doing it to be assholes. I apologize for those wankers.

  86. Check out Lego Robots Galore by richone · · Score: 2

    I run a small website for Lego Robot (and general robotics) fans. Check out www.marsrobot.com for many interesting examples of mindstorms fun. How many toys are there that can be hacked to the level that the mindstorms kit has been?

    --
    Play Well
  87. Ralph Hempel is a pretty cool guy... by CrezzyMan · · Score: 1
    ...I met him at the 3rd Annual Lego Get Together in Toronto, where he gave a pbForth demo. It looks extremely powerful, but so far I haven't run up into any of NQC's limitations for my bots, so I haven't used it yet.

    If you want to (possibly) meet Ralph, and see some cool LEGO bots in a competition, *and* you'll be in the Toronto area this weekend, check out the 4th Annual Toronto Lego Robotics Event, and look at my team's entry from last year. It's been totally redesigned, so watch out for it...

    --
    ->www.chuma.org, ranting and Newtons, what more could you want?
  88. LegOS for Linux!! by JayFlatland · · Score: 1

    LegOS rocks! For anyone unaware, it's an open source replacement for the firmware, allowing easy development of programs for the RCX in C. The programer(s) that wrote it really went off on this...it has a small 7segment font, and it's even multitasking!

    --
    Badgers? Badgers! We don't need no stinkin' Badgers!
  89. Rewriting the interpreter on the fly... by Anonymous Coward · · Score: 0
    Forth is pretty cool from the point of view that the interpreter and compiler are yours to rebuild on the fly - interactively!

    It is in fact considered good style to extend the compiler to deal with application specific data structures and the interpreter to create a app specific command line syntax.

    example interactive session with interpreter (output in bold, comments in brackets)


    4 3 * . ( put 4, then 3 on stack, multiply, convert to ascii using current number base and emit to terminal )
    12 ok
    : 4 11 ; ( redefine '4' as numerical value 11 )
    ok
    4 3 * .
    33 ok

    Changing the number base is also pretty easy:


    6 9 * .
    54 ok
    13 base ! ( change number base to 13 )
    6 9 * . ( for Douglas Adams fans )
    42 ok

    Forth has its down side, but for interactive embedded control systems it is hard to beat.

    cheers,

    dean

  90. Base 1 by Anonymous Coward · · Score: 0

    Bah, base 1 is legal (tally marks). Sounds like a programming/design bug in Forth's part to me...

    Tom

    1. Re:Base 1 by OpDecoder · · Score: 1

      So how is tally marks considered base 1? Is not tally marks binary, either there is a mark or there is not, 2 states therefore base 2.

    2. Re:Base 1 by ucblockhead · · Score: 1

      Remember, Forth is barely above assembly. The whole point is to have a (relatively) high-level operations in a language that really is at the bare metal. As such, there isn't much room for error checking. (Or wasn't. I haven't done anything with Forth in over a decade, so things may have changed.)

      Basically, the print command had a generic routine that took the base as input. You could set the base to any integer. There was no error checking. (As is the case in general for Forth). The routine divides by the base to extract the digits. Infinite loop time if the base is one.

      To those used to modern languages, this probably sounds hideous. But the beauty of Forth was that it fit in only a few k and performed pretty much as well as assembler.

      --
      The cake is a pie
    3. Re:Base 1 by ivan_13013 · · Score: 1

      In general, the value of a number "(D2)(D1)(D0)" where Dx is a digit and B is the base is:

      D2(B^2) + D1(B^1) + D0(B^0)

      This is the same with tally marks. Tally marks really are "unary" -- each digit that exists at all contains a tally mark (there are no "un-tallied" digits in a row of tally marks). What really makes "tally marks" a non-standard numbering system is that there is no "0" -- the only allowed digit is "1" and the "empty number" represents no tallies. Actually, the tally mark counting system was invented long before the number zero. Nowadays, the values of the digits in a numbering system range from 0 to (1-Base). Which means that general base-converson algorithms only work right for bases of 2 or more.

      Tally marks is not binary: The number 5 (decimal) is 101 in binary but it's 11111 in unary/tally.

    4. Re:Base 1 by ivan_13013 · · Score: 1

      > values of the digits in a numbering system
      > range from 0 to (1-Base).

      Except that's supposed to be 0 to (Base-1). (blush)

  91. ef the bad karma...this is good stuff! by FatSean · · Score: 0

    I like it...didn't realize that smileys had no syllabilic value though...

    --
    Blar.
  92. Aweswome! FORTH!!!!!! by farrellj · · Score: 1

    One of my Fav languages...but I have not had much use for it in a long time...I wonder if I still remember how to write in it...

    ttyl
    Farrell

    ...with memories of GraForth on the APPLE ][...

    --
    CAN-CON 2019 - Ottawa's only book oriented Science Fiction Convention! October 18-20, Sheraton Hotel, Ottawa, Canada h
  93. pbForth MazeWalker by rhempel · · Score: 1

    I've got a number of comments ranging from "what a stupid idea it is to eliminate cross-platform issues by compiling right on the brick" to "what a great idea it is to eliminate cross-platform issues by compiling right on the brick" Now I don't know what to think anymore...

    Here's a real pbForth application. It's a robot that navigates mazes drawn on paper. No, it's not on wheels, it's really a gantry crane, but it's something that the standard Mindstorms firmware can't do...

    pbForth MazeWalker

    Have fun...

  94. LegoBUS by redhog · · Score: 1

    Why couldn't they have produced a CPU unit that had some sort of bus, to which you could attach additional 'i/o units', each controling three input (sensors) and three output lines (motors)? That way, the basic unitwould not cost much more, but the expansion would be cheaper and easier... The märklin digital model train control-center implements this really good.

    --
    --The knowledge that you are an idiot, is what distinguishes you from one.
  95. How about Python by Anonymous Coward · · Score: 1

    Id like to see Python, or a fraction of it for LEGO Mindstorms. I know that Guido is working on making Python (or something like it) easier to learn and use for kids, and I think using it for programming Mindstorms would be interesting (not only for the kids...)

  96. Legos on mars :) by Lord+Bitman · · Score: 1

    you ever seen one of those display legos with all the peices glued together? They're light weight, and durable as hell.

    Let's send our mindstorms to mars! :)

    --
    -- 'The' Lord and Master Bitman On High, Master Of All
  97. Limits by Shimmer · · Score: 1

    It's true that there are only 3 input "ports", but it's possible to pile more than one sensor on a single port. For example, you can put a touch sensor and a light sensor on the same port and then use a little logic in the code to distinguish between the two. (I've never tried this, but that's the theory anyway.)

    --
    The most rabid believers in American Exceptionalism are the exact same people whose policies are destroying it.
  98. WWJD? He'd speak Aramaic, not Greek. by Anonymous Coward · · Score: 0


    The Chi-Rho thing came along later on, anyhow. The Greek influence came in with St. Paul, who didn't convert until after the Crucifixion.

    Of course, if ol' Jesus really was the Son of God, he could probably speak any damn language he pleased -- but if so, then it must have pleased him to speak Aramaic, 'cause that's what he spoke. If (as I suspect) he was just a random long-haired radical with some groovy ideas about renouncing violence and wealth, why then Aramaic and Hebrew were probably all he had to work with.

    And, yeah, Bush père really did state publically that he doubted "that an atheist could be considered a patriot, or even a citizen". I'm quoting from memory, but the sense is correct and the wording is at least close.


    --80md

  99. Meta Programable Mindstorms by flymolo · · Score: 1

    I've thought of something I been wanting to try ever since I saw the Lego brick sorter on the web.
    Write a program involveing the light sensor that reads lego bricks as instructions.
    Example red motorA blue motorB green motorC
    Yellow not
    then follow the instruction with a duration
    coded somehow(Binary in gray and black???)
    use white as an insturction cap that says you are done taking input start program

    It would be and interresting programming project at least, but I'm sure with more instructions it could be useful.

    --
    "Sometimes it's hard to tell the dancer from the dance." --Corwin Of Amber in CoC
  100. Mea culpa. by Anonymous Coward · · Score: 0


    "if jesus were", not "if jesus was". wtf was i thinking . . . senility, foax, it hits yunger an yunger ever yeer . . .


    --80md

  101. Programming is fine, what about construction by jonathansen · · Score: 1

    I got the RIS for Christmas (just like everybody else, it seems!) and it's great fun and all, but the programming is the least of my troubles. I mostly struggle with the actual construction of robots. Do any of the books out there cover the construction aspects well, or are they all about programming?
    --

    --
    "A dessert without cheese is like a beautiful woman who has lost an eye." -- Jean Anthelme Brillat-Savarin
  102. Pictures and Documentation by Fastolfe · · Score: 2

    We've taken some pictures, wrote up some text and released the software we're using:

    http://fastolfe.net/features/telecam/