Want to read Slashdot from your mobile device? Point it at m.slashdot.org and keep reading!

 



Forgot your password?
typodupeerror
×
Handhelds Hardware

Lego Mindstorms Controlled by Pilot Via JINI 135

Nobody writes "JavaSoft has a cool article on how they've used their JINI technology to allow a Palm Pilot to control a Lego Mindstorms brick. " The scary thing is that this is one of the more useful applications of Java I've seen...
This discussion has been archived. No new comments can be posted.

Lego Mindstorms Controlled by Pilot Via JINI

Comments Filter:
  • Tell me about it. I had to scrap my plans to create a fleet of killer Lego robots controlled by my Palm. It violated the licence agreement and they threatened to sue.
  • ... Legos were so much better when I was a child. There was rarely a moment of my childhood when I was not gnawing on those delicious and colorful blocks. They don't taste the same anymore. Did they change the recipe?

  • yeah...this is an interesting topic, i.e. doing distributed computing using ejb jini corba or some such vs. xmlrpc type stuff. ms might be on the winning side.

    there. happy?
  • I have some more photos which I took at JavaOne, on my home page. Check 'em out.

    http://www .white-mountain.org/jamie/news/1999_javaone_photos /mindstorms/ [white-mountain.org]
  • I was talking about the comments in general lines, and the feeling you get from slashdot when you come from a place like javalobby. Not about the CmdrTaco particular comment. :). (sorry for my pathetic english btw).
  • by Neville ( 88610 ) on Monday September 13, 1999 @08:14AM (#1684643)
    It's fine to be cynical of Sun's marketing of java, but it's silly to by cynical of the enterprise changes it's undergone over the past year. When will people talk about the actual apps, and not just lump all java stuff together because they're written in the same tongue?

    Anyway, java is highly useful for things like quickly developing complex object and service distribution. For example, encapsulating a service (like a printer in Bangkok, say, wrapped in a java object referenced as an interface), sticking it in a naming directory (could be iiop-based, could be rmi-based, could be something similar to ldap -- java can do it all in a very similar way), and then obtaining a reference to that object and calling its methods from ANY client (an embedded applet on a cellphone, for example) -- this is very cool stuff, and lumping it into the same category as tickertape applets just because they're both java is annoying and ignorant. Should we lump all C stuff together just because it's done in the same language?

    The primary advantage of doing all this in java is not platform independence as much as extremely rapid (thus less costly) development.

    All this is not to say that any of this will run across linux -- based on Gosling's comments here last week, java will run with these legos and on Palm Pilots better than any linux port for the foreseeable future.

  • Hallelujah!@

    We can herd the electrons this way and that. Use electromagnetism in so many ways. Yes those are versatile. Hell, to do anything usually that's how it's done. But back to my original point is that it's the device (the PalmPilot) that's special... versatile... extraodinary... and not the language (Java) it was programmed in.

    ---------
    James Crawford
    drachen@thepcmaster.com





  • Palm Pilot powered
    Tiny plastic bricks of joy
    The song of Lego





    .................
  • Why didn't they control the tanks directly from the PalmPilot infra-red ports?

    Because they needed a place to put the Jini Look-Up Service. Mindstorms don't have a JVM (Java Virtual Machine) on them and the Palm Pilot only has the KJVM on it which only has socket support, and not RMI (Remote Method Invocation) which Jini Requires. They were using Jini so that a single Palm could connect to a singe tank with no problems and no hassle; no worries that two people are trying to use the same tank at the same time.

    Were these PalmPilots the ones w/o infra-red ports, or did the infra-red ports not have enough range for the tanks to pick up?

    They were just regular Palm Vs (I think). The range on the Palm Pilots IR *is* really pitiful (something under 2 feet) but that wasn't the point of the demonstration.

    Actually, what was the point of having the Palmpilots in there in the first place, if the workstations were there anyway?

    This was the JavaOne conference! They wanted to show of as much cool tech as they could. The KJVM was the BIG this this year, after all, they were selling Palm Vs for $199 with the KJVM already on it for people to play with. Jini was also a hot item and a really good idea for this particular problem. I believe people used their own Palm Vs to control the Tanks. WAY TOO COOL... :) I get giddy every time I think about it.

  • yep, the palms are running through a Jini proxy as well. all of the source can be found at the link supplied.

    jakd
  • That java would make the *coolest* toys ever made that much cooler...I may have to sell a kidney and pick up as many Mindstorms systems and a Palm Pilot as I can...


    Dan "Don't step on the legos" Turk
  • Well, it doesn't sound that hard to do, but it sure sounds like fun. Turns your pilot into a small remote control!

    Now, just develop a similar app for a Firecracker unit, and freak the girlfriend and the cats by going around the house and not only controlling a robotic Lego set, but turning the lights on and off at will.

    Remote control: man's ultimate fantasy!

    "There is no surer way to ruin a good discussion than to contaminate it with the facts."

  • by hquin ( 63629 )
    In defense of java, I happen to find it very useful. In fact I'm researching a java telephony solution right now using JTAPI that seems pretty slick. Just because it isn't perl doesn't mean its' evil. :-]

  • Obviously not all the slashdot writers are up on the technology they report about.
  • I guess this is a useful technology if I can control my legos!
    Sorry, but I just don't get it and I work at Sun. Why the hell should anyone care about Jini? I hear all the propaganda at work but I just don't see a compeklling reason for the world to start using Jini. Of course, I may just be daft. This may be like Novell's NDS: really cool, useful and important but hard to explain until someone actually sees it or reaps its benefits.


    _damnit_
  • Well I needed an excuse for myself to go out and by some of these Legos, look's like I might have found one ...

    How come Legos weren't this good when I was a child ?

  • This is great. Two of the neatest technologies to come out in the last few years brought together. Quick, give them a prize, before Microsoft steals the idea, incorporates it into Win2K, and ruins it!

  • "The scary thing is that this is one of the more useful applications of Java I've seen..."

    That's really pathetic. We've written a robust distributed monitoring system completely in Java and integrated it into our website with Servlets. Creating a distributed system and controlling it via a servlet through RMI is insanely simple and performs suprising quickly...

    I'll grant you that this is one of coolest applications of Java... but useful? You people must not get out much... heck... I don't get out much either so that's not really an excuse. If someone would just get a stable, reliable, and fast Java 2 VM running on Linux some of you people will see what Java is capable of. It's really a shame. Sun's released HotSpot on NT and Solaris, mix the two together and you have x86 on UNIX, what's the problem here?

    Moe

  • This was a contrived example to showcase the Jini technology of Sun.

    IR was irrelevant to the example. You could have Palm VIIs controlling the tanks over the web through a wireless connection w/ out much more code.

    Also, the IR port on the Palm doesn't have a lot of range and is very directional, so you don't beam your app or business card to everyone with a Palm in the room, only the intended receiver.

    In a real world app you would want a small/cheap client, like a Palm V as opposed to buying a bunch of workstations.

    The idea of Jini is to put intelligence in smaller devices like a VCR, you would just plug it into a net and it would automatically be able to communicate with your camcorder, TV, satellite receiver, etc. Noble idea for the future but right now all I really just want is to be able to set one damn clock in my house and have them all sync.
  • You left out a step... it's my understanding that any code needed for the device to communicate (ie printer drivers) can be moved over the network and executed on the local VM. No more printer drivers. No more "wow that's a nice peripheral, when can I get drivers for BSD running on my fridge's StrongARM?"

    Discovery, connection, and mobile code that runs on any device.

    What's there not to see?

  • I'm really surprised that the rabid Lego fans who read Slashdot haven't gone nuts over everybody saying 'Legos' instead of 'Lego bricks'. It seems every time there is a Lego story, at least a hundred people get all freaked out over saying 'Legos' or 'Lego bricks' or some such thing. It's almost as bad as the Java people in this story complaining about the 'best use of Java' comment in the story post. Lighten up.

    And in case of oncoming flame, this was a joke. :)
  • OK, so this is a cool demo. But look under the covers, and you see problems with Sun's Java and JINI implementations. Palms have IR transceievers, so do the tanks - why do I need some workstation to mediate simple communication - wouldn't it be cooler to have the Palms speak directly to the tanks? The Palms are running KVM, which is nifty at first glance, but then you realize that it isn't really running Java(tm) - JINI is too big to fit in the multi-megabyte Palms. So, given that we have three computer systems in the demo (Palms, Tanks & workstations), and JINI is only running on one of them, how is this a good demo of JINI's networking prowess?
  • the other thing about jini that's cool that no one seems to realize is that it's a free distributed object platform. its not like it ONLY is useful for mobile devices, pretty much it implements the LINDA principles using java code and provide a nice starting point for people who want to use a nice simple distributed object framework for any number of applications.
  • I think you're underestimating the usefulness of Java network programming. I'd be interested in seeing someone get this same application up & running (with Jini-like useability) coded in C/C++.

    As someone who writes networked code in both, I can testify to the ease of Java's networking API. Also, the advantage of the Jini network (i.e. just plug the damn thing in to start it, unplug it to stop it -- no configuration on either side) is a huge plus....

    I'm not disagreeing with you though; my Palm V is one of the most useful things I own -- I just think you're missing the overall usefulness of Jini and Java.

    --Mid
  • by avdp ( 22065 )
    • An unstable C program only reflects on the skills (or lack of them) of the programmer, not the language. Same thing about how fast you can write it. I don't think that your poor C language skills (I am guessing they are poor based on what you said) means that C is a bad language or crash prone.

    • As far as reusability of C code, I frequently reuse large sections of codes (entire procedures, etc...). You can make your code quite modular if you apply yourself - yes, even in C. (Hmmm... what did I say about poor skills?)

    • Don't like perl? Don't use it! But for those that know how to use it (more people than you think), it is a great language, extremely powerful, and guess what? Definetely for you if you try to cut down on development time. By the way, slashdot is mostly written in perl as I understand it. Slashdot must be evil...

    • Now, let's talk about jaaaaaaavaaaaaaaa... I am not a performance freak, believe me! I do believe getting a better box (better CPU, etc) is often better than spending days obtimizing thousands of lines of C code. But I have yet to use a single java application or applet that wasn't desperately sluggish - even on the fastest CPUs, even just a "hello world" type of application. And believe me, I have (reluctantly) used many of them, some of them written by the masters at javasoft. So maybe it took less time to write it. Does Mr Joe-Shmoe-End-User care? nope. He doesn't care if it took you 9 hours or 30 mins, he is the one that has to put up with those crappy applications. I guess yor argument is only valid if the end user is only second in the list of the developer's priorities. You wouldn't be the first person/company to think that way. Not the last either, but that doesn't make you right.

  • yeah these mindstorm thingys are super cool. We got to use like 500 bucks worth of em to make a robot for a competiton. We won of coarse!! However it was because we had the most simplistic design, and that prevented us from getting strangled by automation. I would like to get this up and running, i would like to remote control a mindstorm via my palm. As i understand it they were un controlable before this, you just had to program them and hope it worked. A friend of mine rigged a setup in which one mindstorm IRed the other and told it where to move, but that was unsucessfull as we were only allowed to use one, and his method was superduper slow in a 2 minute competiton.. With this we could build our robot as complex as possible and not worry so much about that pesky postage stamp programming, which gets to be a real pain in the arsky after like 50 stamps. If only they'd give me a compiler and some libraries (like motorA(forward 5seconds) maybe??) that would be cool. The postage stamp coding may work for dummies but it gets really annoying if you're a lego dominatrix like me. Or we could just go hemo's route and make a perl script to do it. Would that get us the award for "first robot controlled via internet"?
    char *stupidsig = "this is my dumb sig";
  • The difference is that I know that's not the best application of Linux around so I feel little need to "defend" it.
  • largest drive = 500 megs probly. cheap.
    extra software for pilot = no. a simple serial port program will do it..available free.
    optimal model = a palm pro with an upgrade card. the upgrade has a more powerful LED than the standard palm iii or iv or whatever.
    MP3..look on freshmeat.lots available.
    yep. ive done something similar..i actually mounted a palmpilot as a linux drive off the irda port. IR comm issues = range..its not too far.
  • Somebody mentioned the X-10 system, but I didn't see anyone mention another relatively small, mobile device: AIBO. While undoubtedly pricier than the Mindstorm kits ^_^;;, this would be an interesting thing to see.

    I could see a lot of potential in an X-10/Jini/Palm crossover. Forget about a universal/learning remote, how about a context-sensitive remote? You just point your Palm at the TV and it automatically changes its controls to those of the television remote; point at the lamp and you get a switch, which sends a signal to your X-10 unit via the Jini proxy.
  • This could be fixed by making the tanks irda compliant with the palm and having a simple serial port i/o prog to do the control..but then it would loose its kewlness factor.
  • Just out of curiousity, what application server is that? I use a whole bunch of them at work and some are good, some are better and quite a few suck pretty bad. As a side note, even the sucky ones generally provide a more productive environment than anything else we've tried that was written in Perl or C. Kinda puts things in perspective, especially seeing Mr Malda's offhand and ignorant comment about the usefulness of Java. But anyways, care to share what application server you're talking about?
  • Seems there was too much time on them. :-)


    another example here [icepick.com]
  • I had a 486/66 w/ a 6.4 gig drive.. You can buy a $30 bios ISA card (I forgot where I got mine.. but off of the net) to allow you to do this.. Watch how you add up all these numbers tho if you are buying everything separately i.e. ird controller, cheap harddrive etc etc.. computers are so dirt cheap it is much better to just buy the cheapest new computer you can find (which will be a million times faster) than start plugging things into your old machine.. (which unfortunately at the time was how I went about it)
  • by avdp ( 22065 )
    I am not obtuse, I love to be proved wrong! Do give me the link where I can get this wondrous application, and I will try it.

    Once again, I can only tell what I have experienced, and I have experienced *lots* of java apps. I have also coded in java for quite some time, it is a fairly easy language no doubt about that, but aside from that I found very little redeeming values about it.

    Once again, just my opinion, no need to take it too personally, the java world will not end based on it.
  • theoretically anything can be done if enough time/effort goes into it. point is, the java.net package is available TODAY.
  • The scary thing is that this is one of the more useful applications of Java I've seen...

    Man, that one stung! Really.

    I don't know how much exposure there has been to Java applications that are actually useful, but damn!

    I'm currently working in a small group, in a large company, that is developing (the group) a DB (Oracle 8) centered, distributed (web) application for designing industrial and utility-scale boilers for electricity production. We're talking 1.21 GigaWatts here, Marty! It's my first project with this new group, and it's slick as snot.

    Some other notable Java apps: NetBeans and FreeBuilder (granted, they're devtools themselves, but they're java and they nifty), Lotus domino is available as a Java app.

    And then there's always Applixware Office Anywhere [applix.com] that is written purely in Java.

    Really, I'm surprised at the off-the-cuff derission against Java, Rob (old bean). :)
  • by Anonymous Coward
    www.togetherj.com
    get the webbased whiteboard edition, don't get the 2.0 version get the 3.0 version (you got 2 days left for the trial version;-).
    if you have NT and a 400Mhz I can guarantee you you won't think about the fact that it is in java anymore (i don't, and believe me I have been a swing doubter for the longest time, this app turned me around when I realized "holl* S*** I forgot it was swing"). You do have to be versed in the art of UML to truly appreciate the round trip engineering and the listener structure they have build in there. Check out the latest Dr Dobbs where they delve into the layering of GUIs in swing, a good high level introduction into the power of generalized event models and layering of listeners.

    Do let me know if you like it (btw it's much slower on Linux, due to the quality of the VM, but I expect that will change soon)

    ejboss@ejboss.org
  • How about the very powerfull sets of cross-platform software I helped write for my company to preform yeild analysis on the semiconductors we manufacture. It's ALL written in Java. Why? Because it greatly cut developement time. It had to work on Win, Solaris, HP-UX, VAX, and several other systems. The web deployment of the end-user clients allowed anybody to use it anywhere, including our customers, without any intervention by us. Plus distributing new versions is as easy as uploading a file. And speaking of customers, our main customer is HP. We happen to be the top manufaturer of HP inkjet heads (the small semiconductor on the head of the cartiage that spits the ink out). So next time you buy ink for your HP printer remeber that if it wasn't for supposedly worthless Java you would be paying much much more for it.

    And I would love to see someone try and implement a system like this in ANY other language in the same time/cost frame with the same flexability. I tell you it can't be done.
  • One more thing, as a end user I REALLY do NOT care about how fast you wrote the application

    You will care if it means that you can get the application delivered to you faster. This is especially important for in-house applications where people really care about getting the application they want quickly. Cross platform compatibility is a big plus as well.

  • Funny, the online registration system that I used Java servlets to write seems pretty darn useful.
    And because I wrote it in Java and used the Servlets specification, we'll one day be able to move it (not port it) to Linux.

    Yeah, we could do it in C++, but why? Speed? Hm, working fine, says we can scale to thousands more folks. Development time? Nope, came together quite quickly.

    Yeah, yeah, you can do OO in Perl if you try really hard. And you can write objects in Visual Basic too (or so they claim). Java makes it easy for you, and makes it harder (though not impossible) to do it the wrong way.

    Or was Rob bashing java servlets? What exactly do you want people to do? HTML "applications" aren't the way to do things. We want thin clients that run across many platforms, don't we? So to break up the MS stranglehold? But we bash people experimenting with the fledgling version of this technology? What is it that we want, anyway?

    I see servlets on webpages for data retrieval, traffic views, heck, even clothes shopping. It seems to work very, very well.

    Zipwow
  • You are correct- the lego side of things is not running Java. There is currently an attempt to write a JVM for the lego, but it has not (as far as I can tell) made any progress for months.
    ~luge
  • how stable is blackdown 1.2 jvm???
  • OK - this is just my (read: JUST MY) opinion on the whole Java vs C++/C issue.

    I'm a comp-eng student, and have learnt a decent amount of Java. I've also played around with it a fair bit (as an aside, does _anybody_ know a decent amount about the ImageProducer/ImageConsumer framework???). I'm also trying to teach myself C++ at home, with a decent amount of success.

    In NEITHER area am I ANYTHING close to expert - so please feel free to correct me about any of the details that follow.

    Java - the idea - is very cool. This is what most people tout when they say JINI is blahblah, or this does that, etc etc. The whole point of Java and all it's peripheral technologies is hugely distributable code. That's really cool.

    Java - the implementation - is very good in SOME ways, but fairly bad in others (AGAIN - MY OPINION ONLY! CALM YOURSELF!). For instance - a genetic algorithm program that I've written gets quite nice speeds running under the BlackDown port of JDK1.1.7 in Linux (haven't tested it anywhere else :-). There's no native methods in it, either.

    On the other hand - any AWT stuff that I've tried to do is almost pathetically slow, especially compared to the X-Windows stuff that I've tried to do. I also suspect (but aren't sure) that the Swing components are add-ons to the whole AWT idea, and not a fundamental re-organisation of the AWT event model (am I right???). The reason that I say this is because there's lots of things about the AWT event model that suck - for instance, only one thread for the entire AWT system (how do you implement sprites easily? You can't - you have to manually write code that updates each one in turn. With new AWT threads being spawned at will, you could just "spawn" a new sprite with internal timing signals, and everything would be fine and dandy).

    Look - XWindows was ALREADY a platform-independant and fast windowing toolkit (with networking capabilities too :-). Why didn't the Java guys just provide a set of wrappers for that??? Or at least provide a set of methods to interface with it?

    Also - C++ (ANSI) is extremely fast and fairly standard. Java is basically a subset of the C++ methods, along with a whole bunch of new code ("libraries") and some kewl new ideas about method/class organisation, all organised in such a fashion as to make it platform independant.

    So _WHY_ is it so slow? Sure, it's interpreted virtual machine code, not precompiled actualy machine codes (hence bytecodes and JVM, etc), but (for instance) VMWare runs an extremely tight virtual Intel processor that gets about 50-75% actual speed (by this I mean that if I run VMWare on my Intel processor I get about 50-75% of the actual processor speed as the speed of my virtaul processor)!

    So my opinion is that Java is an extremely good idea that was moderately badly implemented. Again, just my opinion.

    As a corollary, by the way, that means there's a market for good implementations of similar ideas. Because lets face it - the Java idea has so much to offer computing/programming.

    One final time, Just mY oPinIon

    -Shane Stephens
  • html seems to work very very well also.
  • I know this sounds pathetic, but there is a page in the www.lego.com domain where Lego specifically explains that it is company policy to refer to them only as Lego bricks. They specifically condemn the use of the phrase "legos" and, IIRC, directly exhort parents to correct their children when the kids use the plural and not the "proper" phrasing. That was one of the sicker examples of management-speak I've ever seen...
    ~luge
  • In NEITHER area am I ANYTHING close to expert - so please feel free to correct me about any of the details that follow.

    Not a prob. :)

    [kersnip]
    On the other hand - any AWT stuff that I've tried to do is almost pathetically slow, especially compared to the X-Windows stuff that I've tried to do. I also suspect (but aren't sure) that the Swing components are add-ons to the whole AWT idea, and not a fundamental re-organisation of the AWT event model (am I right???).

    Essentially, yes.
    The main difference between Swing and AWT is that every AWT widget has a native peer -- basically a hook into the windowing toolkit of the console's graphic environment. In Swing, every widget is "lightweight" -- it's drawn entirely through Java's neato rendering context APIs. This gives you a lot of flexibility and lets you do cool things like insta-double-buffering and translucent UI components with a minimum of effort. However, it is definitely slower.

    The event model is the same for both Swing and AWT.

    The reason that I say this is because there's lots of things about the AWT event model that suck - for instance, only one thread for the entire AWT system (how do you implement sprites easily? You can't - you have to manually write code that updates each one in turn. With new AWT threads being spawned at will, you could just "spawn" a new sprite with internal timing signals, and everything would be fine and dandy).

    Ummm... there's only one *event* thread in AWT. You can have as many threads as you like merrily drawing away to the Graphics object of your choice. The single-event-thread system only screws you if you're doing something like multi-modal input (which I am :().

    Look - XWindows was ALREADY a platform-independant and fast windowing toolkit (with networking capabilities too :-). Why didn't the Java guys just provide a set of wrappers for that???

    Ever use X over a modem? Or any connection that wasn't a LAN? It is VERY high bandwidth, and therefore not a good thing to tie your windowing toolkit into when you are a networking-oriented language. And if you can't use X in that manner, why use X at all?

    Wrapping X in a properly object-oriented fashion was probably more work than JS was willing to commit to.

    Or at least provide a set of methods to interface with it?

    We're using just such a toolkit in our next project to drive a wall-size display. No URL off the top of my head, unfortunately, but such things are out there.

    Also - C++ (ANSI) is extremely fast and fairly standard. Java is basically a subset of the C++ methods, along with a whole bunch of new code ("libraries") and some kewl new ideas about method/class organisation, all organised in such a fashion as to make it platform independant.

    OK, here's where I get pissed. :)
    C++ is a bastard hack. It is a crufty, inelegant glomming of some OOPy-sounding keywords onto a language that was NEVER designed to be used in an object-oriented fashion. The concept of OOP was around for a looong time before C++; Java is the first mainstream P/L to be architected from the ground-up with OOP in mind. THAT is why it has greatest programming language design in the history of computing (note my omission of the word "implementation" ;). The fact that Sun is harping this silly cross-platform angle is incidental.

    [kersnip] So my opinion is that Java is an extremely good idea that was moderately badly implemented.

    I think every real java programmer in the world would agree with you on that one. The fact that the Creator permits a virtual-platform networking-centric elegantly OOP language to be wholly owned by a traditional "big iron" computer corporation has contributed greatly to my cynicism and festering sense of misanthropy.

  • If you want a real programming language for the legos, check out legOS [www.noga.de]. Full C and C++ support for your legos.
    ~luge
  • by Anonymous Coward
    You are seeing this very very neat application that gets you drooling, and you ask the salesperson "i want one! what is it written in?". The salesperson then say, "well, it's java, sir!" and you automatically assume that java is the greatest thing in the world.

    I think you've read to far into his post. No where did he say that just because the software is done in Java that it's the greatest thing. All he was saying is that Java -can- do some really cool stuff.

    I know that there is no such jini-like API in C/C++/etc (at least that I know of).

    And wanna know what? You don't need one in C++! The great thing about Jini is that it doesn't require Java. You can use other languages and still enable your device for Jini by using proxies. In fact, if I'm not mistaken, you can even write the lookup and other services in another language such as C++!

    One more thing, as a end user I REALLY do NOT care about how fast you wrote the application!

    Then don't complain when software's release is delayed or due to insufficient amount of time the feature you really wanted was kept out. Those are just the tip of the iceberg - Development time does matter.

    I care about speed and reliability. Maybe java has that (I have seen otherwise, but I love to be proved wrong)

    The problem with all you Java nay-sayers is that your main exposure to Java is through the dinky applets spewn across the Web. Most of you are not seeing what is actually being done inside the Fortune 500 companies or some of the various academic / research projects. Nor in many cases have people who discount Java tried it themselves.. and I don't mean a little applet.

    Most "real" Java users have learned that Java can be quite reliable while cutting development costs and time spent. As for the speed issue, yeah, it's not as fast C or C++ (or asm for that matter), but it's not dog slow as people make out to be. Furthermore, Java has actually exceeded C/C++ speeds in some cases using Hot Spot.

    Hotspot vaporware? Nope!

    JavaTM 2 Software Development Kit, Standard Edition, v.1.3 Beta [sun.com]

    (Obviously, only available for Windows and Solaris at the moment..)
  • You just point your Palm at the TV and it automatically changes its controls to those of the television remote; point at the lamp and you get a switch, which sends a signal to your X-10 unit via the Jini proxy.

    Yes!

    This is exactly what I got about what was the "thing" with Jini - devices that can communicate with each other on the fly, dependent only on context.

    Other examples using the Palm (or some other handheld) with Jini-capable devices: programming the thermostat in the house, setting the vcr, collecting voice messages from the phone (for later playback). Or as ordinary as finally making the handheld's synchronization with the desktop a lot more seamless.

    Tons of possibilities...

  • Mindstorms brick has 16K ROM and 32K RAM. And it is priced at about $100.

    Here is the challenge. Develop an alternative hardware, with more sensible specs. Like 1M flash ROM and 1M RAM, or more. Also, has to be extensible (3 sensors and 3 motors are not enough). Has to fit into Mindstorms case. Alternatively, has to have its own Lego-compatible case with at least 6 motor ports and 6 sensor ports.

    This [uclinux.org] is probably a good place to start.

    If priced at $100 (heck, even at $200) I'll buy it.

    Then I'll consider to drive it with JINI. (I'll probably wont't do it anyway.)
    --

  • You are right but technically that is an RMI feature, not a Jini feature. Jini does not require the presence of an actual VM on all the devices but if one is present, it can be used for this.
  • While you are at it you'll also want to try netbeans www.netbeans.com/org (i'm not so sure)
  • You could do something similar to Jini as far as distributed lookup services in C++, but I would like to see you make the networked printer serve off drivers that are platform independant. Open Source has something rather close to this, called the source.tgz file. That is hardly automatic (and requires hacking for every platform, ESPECIALLY with device drivers which may hack hardware, use system APIs, or rely on byte order)
  • The correct use is "GNU/Legos", get it right

    :)
  • Mindstorms are great! I no longer need a degree in electronics or mechanical engineering! Now not only can I built a Mindstorms case that will dissassemble itself whenever I need to swap out hardware, I can built my next garage door with them, too. Perhaps a Mindstorms controlled tractor-mower? Sit in the shade and steer the mower around like a video game! An army of Mindstorm-enhanced appliances, from the ashtray that empties itself to the 'Fridge-buddy' that retrieves me another cool Guinness on demand; All controlled from the comfort of the Mindstorm chair.( complete with 21 inch monitor, self adjusting keyboard and autovariable cushion firmness!! )


  • by Anonymous Coward
    Hardly a new toy, they had this up and running months ago. I even got to drive one. The coolest bit was when I was watching the monitor, and somebody placed a new tank into the battlefield and it was auto-recognized. Highly cool.

    Miko gave his "courage under fire" award to the Lego team because, before their demo, they found out that the overhead lights screwed up the IR towers, and they figured out how to splice two towers together to get redundant coverage. Or sometihng like that. Pretty neat.

    And apparently it's not pure Java (I didn't read the entire article) - the mindstorms are merely running a jini proxy, which is presumably written in NQC. At least, when I asked the guy at JavaONE, that's what he said they used.

  • There is already a technology that does just that. It is called X-10. I have a friend that has it installed in his house and can control his entire house from a computer. The technology speaks to different items through power cables in the house. You can find the FAQ Here [scruz.net].
  • Even though the software was in Java, it's really the fact that the Palms can be used in such varying ways that is the coolest fact. I mean here we can control our TV's, print to IR printers, transfer files through air, unlock cars that use IR remotes, etc. This little device can do it all. The fact that the software was written in Java, IMO is of no consequence. The program to control the legos I'm sure could have just been written in another language. You've got to love how these companies tout their software by making is seem like something so revolutionary when it's not. C was revolutionary. Java is not.

    I sure love my PalmIIIx. Never leave home without it.

    ---------
    James Crawford
    drachen@thepcmaster.com

  • Cant wait for the first Java-controlled coffee machine. *rips the pun-alert siren off the wall*
  • hm...i wonder if all the app servers, distributed object systems etc. written in java might provide some proof that java's networking support is good
  • It's funny that you get so worked up over it!

    And, yes - that is kind of funny - in a sort of satirical way. The difference is that we don't need to defend Linux, nor do we feel the need to defend Linux.

    The fact that people get so worked up over Java makes me worry a little, though - what are you guys trying to hide???

    -Shane Stephens
  • I've tried to do a similar thing (w/out the Palm Pilot) and the 486dx4/100 was choking on the mp3. Now, this may have been caused by any # of things: low memory (20MB), slow HD. Of course, that was just my situation...
  • >But I have yet to use a single java application or applet that wasn't desperately sluggish - even on the fastest CPUs, even just a "hello world" type of application.

    On my dual-Celeron, running the latest Blackdown JDK, HotJava and Netscape seem to be about even. Mind you, Netscape is pretty sluggish itself. (Stability's about the same too, which is pretty sad.)
  • If you have skill enough you can probably pull it of in assembly. That's not the issue. What is the issue is that time and again casestudies show c program development to be far more expensive than Java development. This is the main reason companies are favoring Java development these days.

    Your way of reusing code is copy and paste. That in it self is a maintenance problem because as soon as you duplicate, you've got two pieces of code to maintain.

    About perl is a powerfull language (no argument about that). The resulting products suffer from the same maintainability problems as C and Cobol. I.e. you need a skilled programmer to understand and maintain the code. Unfortuantely these skilled programmers tend to move on and leave the companies they were working for with unmainable complicated code.

    I'm not saying Java doesn't have these problems. I'm only saying that with java these problems are not so big.

    Then the famous performance issue. Yawn, you've got some reading to do to upgrade your skills. There are programs out there that perform as good as C on a hotspot compiler.
  • Look on the LEGO Mindstorms page, one of the recent new contributors is this one Japanese guy who created his own AIBO from a few Mindstorms kits - called it MIBO. Uses a couple of RCX units, and is pretty complex. He goes by (may even be his name) Jinsato.

    Here is a link to his page:

    http://www.mi-ra-i.com/JinSato/MindStorms/index. html

    There is also stuff on the LEGO site...
  • yeah...this is an interesting topic, i.e. doing distributed computing using ejb jini corba or some such vs. lightweight xmlrpc type stuff. ms might be on the winning side.
  • I think in fact that is what they are trying to do. I have this discussion w/ friends all the time (I was using opengl/gtk he was using java) and the speed differences were embarrassing (I was doing full real time rendering). Since you can compile gtk and get Mesa for every machine under the sun, I would ask him what the point was.. i.e. why not pull a alpha type trick and recompile native or connect to native libraries... well anyway apparantly that is what some of the java things are going to do i.e check for quicktime then connect to that natively, check for opengl and connect to that natively.. I don't use Java at all personally so I am not sure if this is true.. but thats what he claimed..
  • The only thing I dont like about C is that it is difficult to get cross-platform memory debuggers.. (i.e. like efence etc..) I switched most of my C code to C++ basically still written C like and wrote templates for malloc() type routines. The bounds checking and memory leak code is #ifdeffed and shows *no* performance hit w/out the flags. (Actually the I did have to manually add all the inlines as well).. But anyway being able to do cool things w/ templates like this converted me over.. Actually the other vaguely cheesy nice thing about c++ is if you write 10 million subroutines you start losing track of their names.. but c++ cuts down on the number
    of gratuitous subroutine names which is nice when your code becomes too monstrous. Really you can use c++ to be c code w/ cpp on steroids tho :)
  • I don't know about the IR stuff, but I'll see what I can do about your other points.

    Harddrive: A machine of that age should have support LBA (aka translating BIOS), check your CMOS settings to be sure, so there isn't a limit on the hard drive size you can put in it.

    CLI MP3 player: Personally I swear by mpg123. The newer versions have jukebox support so they can be controlled from an external program (i.e. a perl script listening on your IR port)

    You may find problems with your machine not being able to play high bitrate MP3s without jumping. I had a 486 DX4/120 and that could cope with 128Kbps (so long as i didn't want to use it for anything else at the same time :) but jumped on 192. But YMMV.

    This would make a good topic for an Ask Slashdot (if it hasn't already been done).
  • by Kingpin ( 40003 ) on Monday September 13, 1999 @06:07PM (#1684740) Homepage

    What's up with the Java bashing?? I'd say one is ignorant if he cannot recognize the benefits of having more than one language. Perhaps some people think they're losing ground to 'this upstart OOP language!' - pfft. Try it, you might even understand and like it.

    I use both Perl, C and Java - your choice of language should depend on what you'd like to make. Not on the degree of your stubbornness. The must go as fast as possible all the time servers - well - code them in C, optimize it in your assembler, but why not make the clients in Java? Seems logical enough to me.

    Imagine all code being uncommented Perl - now wouldn't that be a riot! A true Tower of Babylon ;)

    Kingpin

  • Users should be able to moderate Robs posts, so that when he starts trolling about a language he obviously hasn't used recently, it doesn't start yet another java flame (YAJF). The people I feel sorry for are whoever at Andover.net is going to have to maintain those perl scripts, after Rob finally loses it...
  • :-) :-) :-) :-) :-)

    Thank you so much for a good reply!

    OK - enough of the sucking up. May I ask you a couple more questions?

    The thing about XWindows being extremely high bandwidth, etc. over a network environment - this is surely true of ANY program that tries to control windows. If not - then this means that an extension to XWindows would be possible that DID cut down on the bandwidth.

    Also, I'm still happy with the idea of transporting bytecode rather than images - I just think that XWindows is a faster way of displaying images than the AWT stuff is. And it has some neat-o features built in too.

    The point I was trying to make about C++ isn't that it's nice, because you're right, it's F**KING awful!

    But - it is fast. Very fast. And a lot of Java is based on C (syntax, etc) - a cut-down, partially redisgned version of C++ could look very similar to Java and be one heck_of_a_lot faster - even a Java-To-C++ translator that gave you C++ code to compile would probably end up faster than the native Java!

    Which, I suppose, is exactly what we're both saying about the nasty implementation...

    Oh well. Will nothing ever be done Right??? :-(

    0Shane Stephens0
  • I got my big box of Lego out of my parents' attic a year or so ago.. great fun.

    It *was* so much better in the old days.. you only had a few colors, and a few generic shapes, and you had to be inventive. Now, they just mould the toy in two big parts and construction consists of pushing the two parts together! That's not Proper Lego.
  • Firecracker and X-10 are one in the same (as I understand) I think that is what he was speaking of.. As far as I've seen the X-10 products do not as of yet have a univeral remote, which the original poster would like tosee implimented.



  • Maybe they could use it to control MIR?

    ---------------------------
    "I'm not gonna say anything inspirational, I'm just gonna fucking swear a lot"
  • Hmmm, if you combine this with the palm's ability to steal auto security codes [slashdot.org], maybe you could make a robot that goes around stealing cars! >:>

    Generic Man
  • Well, one of your visions seems to have found life:

    http://www.friendlymachines.com/

    D

    ----
  • Sure it would be faster but it would have taken three times as long to develop it, four times as long to debug it. It would randomly crash for no reason at all and you could forget about reusing any of the code.

    I'm exagerating a little (but only a little). I think the whole thing would be pretty limited if written in C.

    I'm glad you recognize perl is evil because it is. It's syntax is a nightmare and I have feeling all these nerdy scripts currently running many websites will cause a lot of maintenance problems in the future.

    Java may not be the most optimal language performance wise but Java code is highly maintainable. If you want performance, hack away in C. If you want to cut your development cost in half go for Java.

  • X-10 has, quite possibly, the most connected universal remote for something that doesn't kill your wallet. It does x-10 (requires a RF reciever like the Firecracker), has quite a lot of pre-programmed devs (up to 6 devices) in it. Best yet, some of the remotes (not the one I have) are learning remotes. I can walk around my house with one and pretty much control anything. And I've three of them :-)
    (thank goodness for X-10 freebies)

    what I'd like to do, though, is get a Firecracker rigged up w/ my palm pilot. I could do all sorts of neat scheduling things (yeah, there's the Comp Module, but that means you need access to your comp), from my pilot, or control things w/out carying a remote w/ me everywhere. hrm... there's a project...

  • Why did they have to go through the cradle/workstation/infrared-tower setup?

    Why didn't they control the tanks directly from the PalmPilot infra-red ports?

    Were these PalmPilots the ones w/o infra-red ports, or did the infra-red ports not have enough range for the tanks to pick up?

    Actually, what was the point of having the Palmpilots in there in the first place, if the workstations were there anyway?
  • by avdp ( 22065 )
    Oh, I see... So I guess the purpose of the excercice (java) is to eliminate the need for skilled developers. Please. As an end user, I am rather annoyed by the concept because as usual, the end user is the victim. As a programmer (and my language skills DOES include java, just for your information) I can't help but to laugh - no wonder my skills are so needed, if this is the kind of thinking the current comp sci grads are being put in their head by universities, all the sudden my job (that was very secured to begin with) seem to be even more secure every day.

    As far your *yawn*, that's great. Please do provide url to "these programs out there" that perform as well as C. I will try them, I promise you. I just tried a program that was recommended by another java advocate. I will admit, it was veeeery close, but not quite there.
  • Uh.. Kill me, I'm a heathen.
  • Yeah, but can a Palm control all those IR devices without having to wipe the memory and download a new program each time you want to control a new device (not to mention still have enough memory left over for basic PDA stuff)? (asked by a potential Palm customer) Even the HP-48G could be a TV remote, assuming you didn't need the extra memory for your Electronics 310 test formulas...
  • "Oh, I see..",

    I guess you still don't. Indeed it is true that it takes less experience to do a certain job in Java than in C. That does not mean that good programming skills are useless. Java rather allows skilled developers to focus on more relevant problems than fixing memory leaks. Which means they can be more productive.

    I don't think the end user is a victim here because he gets more functionality faster.

    "I can't help but to laugh", please share the joke and tell us why you are so valuable. Just don't forget that COBOL programmers are still wanted too. Nevertheless COBOL by now is a relic of the past. I'm not saying C/C++ (somehow I have a feeling you specialize in one of those) is going away anytime soon. Enough code has been produced during the past 20 or so years to keep guys like you busy maintaining it. You'll probably be paid well for it too since new students are not so eager to learn old languages.

    As for myself, I know about C, C++, Pascal and Java. I know they each have domains where they excel. I know Java's domain is becoming larger and is starting to overlap the other languages domains.

    As for my yawn, everytime Slashdot posts a story on Java, you get these people claiming Java is so slow. Usually a story follows that while loading an applet the browser crashed and that therefore Java won't get anywhere.
    I've posted in several threads explaining why they are wrong over the past few months and did not feel like repeating myself. As for the faster than C claim. I'll admit it's a bit a weak claim right now. I don't have any references readily available. But if you're interest is genuine, why don't you get yourself a copy of jdk 1.3 beta (I think the hotspot compiler is include) and write some simple programs to test its performance. I've been hearing some impressive stories about it (haven't verified them).
  • The thing about XWindows being extremely high bandwidth, etc. over a network environment - this is surely true of ANY program that tries to control windows. If not - then this means that an extension to XWindows would be possible that DID cut down on the bandwidth.

    mmm-hmmm. Here is one solution our company is hoping to use: Jazz [umd.edu].
    Jazz is a 2D scenegraph rendering API in java. If you've ever done any 3d work, you'll know that a scenegraph is basically a bunch of primitives (polygons, text, curves) organized in a tree structure with linear matrix transforms between nodes. This lets you scale, flip, stretch, etc. any portion of your scene simply by tweaking the values in a single transform node. More importantly, this lets you ship an arbitrarily complex user interface over the netwerk merely through specifying your initial scenegraph (with the addition of some serialized callback objects + wiring) followed by commands that mutate various nodes on the scenegraph.

    But - it is fast. Very fast. And a lot of Java is based on C (syntax, etc) - a cut-down, partially redisgned version of C++ could look very similar to Java and be one heck_of_a_lot faster - even a Java-To-C++ translator that gave you C++ code to compile would probably end up faster than the native Java!

    Well, the language design by itself isn't necessarily slow (although all the reflection APIs would definitely drag down any implementation). It really is the VM that makes Java annoyingly sludgy. There are a few competing efforts for a native Java compiler, the most prominent being GCJ [cygnus.com].

    Oh well. Will nothing ever be done Right??? :-(

    nope.

  • The correct use is "GNU/Legos", get it right

    Do you know of an ftp server where I can get GNU/Lego? Lego model quality has been going down hill for a while (the techniccal term is Town Juniorization), and it's too expensive, so if we can just convince some toy manufacturers to come out with high quality open source lego-compatible bricks, I'd be really jazzed. Mega-blocks are almost there, but not quite, and those Ramboesque Best blocks make me cringe.

    Until then, I'll have to stick with my propietary Lego ( I just counted 12 models in my office, geez).

    George
  • And people mocked the matrix...see, it's the way of the future...

    "Tank, I need a pilot program for an XXXX helicopter" and boom, there it is...analogy with Jini, simply connect to it, request, and receive...

    Ok, maybe not, but I'm tired, gimme a break...
  • Oh, lighten up. He said it was cool and he featured it, didn't he? I don't remember him saying anything about it being slow.

  • Even though it was implemented on a PalmPilot, I think it's the fact that the force of electro-magnetism can be used in so many ways that is the coolest fact. I mean you can microwave food, herd electrons into doing our work, see, etc. This force of nature can do it all. ENIAC was revolutionary, the PalmPilot is not. I sure love my electro-weak force. Never leave home without it. ;)
  • I have a 486 DX2 66 machine which I don't use anymore. I was thinking about what to do with it and then I realized that I could use it as an MP3 server connected to my stereo. There is nothing fancy about this but I would like to control it with a Palm Pilot via Infrared (IR). So I will be running Linux (no X stuff just CLI), attach an IR port to the PC. Run MP3 player. Control it with the Palm Pilot. Here are the questions that I have (I do not own a Palm Pilot yet so I am pretty ignorant about them):

    What is the largest harddrive 486 can handle and cost?

    Do I need extra software for the Palm Pilot?

    What is the optimal Palm Pilot model for this?

    What is the best MP3 software for CLI?

    What are the issues with the IR communication?

    And the most important one:

    Has anybody done this already?

  • You have to look through the propaganda (basic skill of a software engineer these days, if you can't your lost).

    Jini is something really simple. The concept goes like this you have a lot of devices all able to their particular thing. In order to do so they need other devices to their particular thing. Jini is all about providing a dynamic way to let these devices help each other.
    The process is really simple:
    - device registers itself at the lookup service upon connection
    - device asks for services it needs
    - the lookup service gives back a ref to a suitable device
    - two devices previously unknown to each other are now communicating

    There are plenty applications for this really simple technology (I'm abit tired so I won't bother listing them, I suppose you know the way to SUN's propaganda pages).

    So this is what you can do with Jini now to why should want to do it at all:

    Computers are becoming smarter smaller and cheaper. Computing power and networking is becoming dirtcheap. So cheap it can be put in any device. If it can be done it will be done. So there is a need for these devices to communicate. What would normally happen is that companies start making incompatible propietary protocols for the devices communication.
    But industry has learned that propietary protocols have their limitations so they want something more standard. So they sit together and try to come up with a protocol. At this point Jini comes in as an easy to use solution.

    It is now only a bit more than a year rumours about Jini started spreading (I recall an article on JavaSoft June/July '98) so it has come a long way in only a year. Of course there are not many products around at this time but a lot of companies are really interested in this stuff so I expect to see some products the coming years.

Put your Nose to the Grindstone! -- Amalgamated Plastic Surgeons and Toolmakers, Ltd.

Working...