Become a fan of Slashdot on Facebook

 



Forgot your password?
typodupeerror
×
User Journal

Journal Journal: Followup - Linux for a 3.5 yr old 3

A while ago I asked for opinions about building a Linux laptop for my son. This is a follow up to that, some notes for my future reference.

After looking around, I decided to go with the Edubuntu, an education related distribution of Ubuntu. Ubuntu had just released their 6.10 "Edgy Eft" release. Ubunutu has a great reputation for usability as a desktop OS. The Edubuntu release has lots of the games and tools that I would like for my son pre-installed.

I downloaded and burned the Edubuntu install CD, and used it to perform an initial install on the laptop I had chosen for this project - an IBM ThinkPad 600E. Thinkpads are so durable, they make great computers for kids. The install went fairly smooth. My PCMCIA ethernet card was identified properly, the video configured itself reasonably, and the system was very functional. The software included Tux Paint, Potato Guy, and a host of other games and activities that should appeal to a youngster. My one complaint was that the sound did not configure itself properly.

Apparently configuring the sound on the Thinkpad 600E is well known as a tricky operation. I tried a bunch of remedies. I disabled fastboot in the bios. (The bios is entered by pressing F1 during the boot process.) I added the kernel parameters pnpbios=off and acpi=off to the grub configuration. Nothing seemed to work.

After futzing around for a while, I decided to start from scratch. I rebuilt the machine with fastboot disabled and the pnpbios=off and acpi=off parameters during the install process, hoping that this would allow the install to discover the sound settings. It still didn't work.

After further poking around, I discovered that IBM provides a config utility called PS2 which can be used to, among other things, view and alter the configuration of the sound card. The utility only runs under DOS. The hibernate function of the Thinkpad 600E also requires a FAT16 partition to host the hibernate file. I decided to build a small DOS utility partition to host the hibernate file and the PS2 utility.

My CD burner software - CDBurnerXP Pro 3 - contains a utility to make a bootable cd. The boot process actually loads a minimal DR-DOS environment and maps it as "A:", and the contents of the CD are available as "D:". Not being certain that the IBM PS2 facility would run under DR-DOS, I found a Win98 boot diskette image and made its contents available on the CD as well as the IBM utilities.

Once I booted with the CD, I used the Win98 fdisk utility to create a 500 MB bootable DOS partition at the start of the drive. Then I formated it and transfered the Win98 system files, the PS2 utility, and some other drivers needed to mount the CD rom, etc. I attempted to reboot, but couldn't because the MBR still had grub on it.

I rebooted with the CD, then used the DR-DOS fdisk to overwrite the MBR. I rebooted without the CD and everything came up fine. I attempted to make a hibernate file with the PS2 utility, but that failed. The Win98 tools had built for me a FAT12 partition. I needed a FAT16.

I rebooted with the DR-DOS disk, partitioned and formated with the DR-DOS FDISK and FORMAT utilities, then loaded the Win98 system files and copied everything else over there. I removed the CD, rebooted, and was able to use the PS2 utility to create the hibernate file and check the parameters for the audio subsystem.

Now, I rebooted with the Edubuntu install disk and reinstalled on the remaining 5.5 GB. The grub config did locate the DOS partiton and correctly made an entyr for it. Sound still did not work. A little searching led me to this page. That successfully fixed my sound issues.

The default kernel was an i386 build, backward compatible to lots of older processors. The other "flavor" available to me was the i686 flavor, which can be used with Pentium II or better. I used the Synaptic Package Manager to de-select the linux-386 package and select the linux-686 package.

Finally, some of the web sites my son might want to visit use flash. I found these directions, which worked pretty much perfectly.

Finally, I created a user account for my son, and moved some links to things he might want onto his desktop.

Still to do, I want to reduce the number of services running. No need to run bluetooth, for instance.

One last thing. Like lots of older laptops, the battery was shot. I was able to trade the battery for a replacement at http://www.batteryrefill.com/. They take aged battery packs and replace the LiIon cells. The control circuitry is usually fine, even though the cells have failed due to age. The refurbished battery for a Thinkpad 600 series is $35 with a trade in of a non-working battery.

User Journal

Journal Journal: My son, the artist 2

So Joe has been pounding away on OpenOffice Writer lately. He mostly likes to take things from around the house and copy the words in. Today, however, he made up a new game.

OOo Writer has a "paragraph background" feature that allows one to set the background color for that paragraph. Today, he made several blank lines and started setting the color for each. Starting from the top, he made a band of light blue, a band of bright yellow, about 5 more bands of light blue, then a band of green.

Then he called me over and said, "Look. I made the world. Here is the grass, the sky, and the Sun." I was shocked. It was very 20th century abstract art. Very cool.

User Journal

Journal Journal: Ask Slashdot - Linux for a 3.5yr old 7

I'm admittedly biased, but my son Joe is really bright. He is currently three and a half. A few weeks ago he asked if he could make letters on the computer. I opened up a word processing program and let him pound on the keyboard a bit. He's been doing this regularly.

About a week ago, I walked in and found this on the screen...

IBM

I asked him about it, and he said that he copied the letters from the label. (This is an old IBM ThinkPad) A few days later my wife walked in a found this...

Google

When asked, he said he saw it written on mommy's laptop screen and typed it in from memory. Today, he typed in "Milk Duds" by copying the box from some Halloween candy. And right now he is going around the house finding objects with writing on them and typing in the writing.

My wife and I decided that Santa is going to bring him his own laptop. I have an old ThinkPad 600 that should be perfect, especially if I get a new battery for it.

He's currently playing on a laptop with CentOS running (a free derivative of RedHat Enterprise Linux). Is there any distribution particularly appropriate for young kids or should I build his machine with CentOS as well? Does anyone want to recommend a word processor for him? OpenOffice is a little heavy weight, and while he has been using vim successfully, that might not work well when he gets a little more independent.

Also, any recommendations for puzzle games? He likes playing snood, so similar games might be fun for him.

User Journal

Journal Journal: Super Karate Monkey Death Car 2

"The original title of this book was 'Jimmy James, Capitalist Lion Tamer' but I see now that it's... 'Jimmy James, Macho Business Donkey Wrestler'... you know what it is... I had the book translated in to Japanese then back in again into English. Macho Business Donkey Wrestler... well there you go... it's got kind of a ring to it don't it? Anyway, I wanted to read from chapter three... which is the story of my first rise to financial prominence... I had a small house of brokerage on Wall Street... many days no business come to my hut... my hut... but Jimmy has fear? A thousand times no. I never doubted myself for a minute for I knew that my monkey strong bowels were girded with strength like the loins of a dragon ribboned with fat and the opulence of buffalo... dung. ...Glorious sunset of my heart was fading. Soon the super karate monkey death car would park in my space. But Jimmy has fancy plans... and pants to match. The monkey clown horrible karate round and yummy like cute small baby chick would beat the donkey."
User Journal

Journal Journal: The Death of the BCS? 3

Is this the year that we finally witness the death of the BCS?

After Rutgers beat formerly undefeated Louisville last night the natural order of Div-I college football is at risk. The national championship should have been decided when an undefeated Louisville was faced the undefeated winner of the Michigan-Ohio State game. Louisville now has their first loss, and now six or seven teams can argue that, at one loss, they should be the challenger for the title.

But Rutgers is undefeated. Going into last night they were ranked 13, and if they finish out their last three games with wins, including a win against West Virginia, they'll probably be ranked in the top 8 or 6.

How can a highly ranked, undefeated team, a team who defeated the number 3 team late in the season, not have the opportunity to play for the championship?

Maybe next year we'll have a tournament.

User Journal

Journal Journal: 10 Kilotons on longbeach port

Saw a technical analysis of the aftereffeects of a 10KT (small by nuke standards) detonation in the Port of Long Beach - wiping it and Port of Los Angelese both out. Container form North Korea and Iran on a ship is detonated in the port facility just before unloading. The port, its facilities and most importnatly, 60,000 people woudl die either immediately or within hours formthe initial radiation, blast and heat.

Fallout would be quite harsh due to the shallow draft, and the abundance of water in which radioactive material would be carried by the superheated steam. Initiall there are the heat and overpressure effects - followed by the probability of 500 sq miles of contaminated area that would cause the evacuation of 5 million people. On top of that the loss of most of the refining capacity, and a large number of industries in the area (entertainment, eletronics, etc).

The losses would exceed 3 trillion dollars (for comparison, 9/11 was mayb 50 to 100 billion - less than 5% of that impact fiscally).

Truly scary stuff. And unlike the Soviets who truly loved thier children too, the guy in North Korea and his Apocalyptic friend in Iran would use such things with no regard to anything other than thier wierd cult of personality (Kim Jong Il and his potemkin world) and the violent apocalytpic Koran version that the Iranians use.

Scary to have so many lives riding on such thin reeds of irrationality.

The potential cost of inaction is very very high - millions of Americans depend on this - and probablytens of millions of Iranians and North Koreans as well (who would die in US retaliatory strikes).

Many would have shot Hitler and Tojo before WW2 had they know the horrors those 2 were to unleash on the world.

Should we be considering doing the same to Kim Jong Ill and the Iranian Mullahs?

How do we look into the abyss without the abyss looking into us? How to destroy our enemies without becoming like them?

No easy answers.

Yahoo!

Journal Journal: Sick and Tired of Political JEs 12

I'm sick and tired of all your politics Journal Entries. You all complain about the lying, cheating, negative campaigning, smearing, etc etc etc. And you all want to live in the town of Gum Drop Falls, near Chocolate Lake, and everyone is good and decent and honest.

AIN'T GONNA HAPPEN!!!

I'll let you in on a big secret. To some degree they are all crooks. And so are we.

We don't live in some utopia because the human animal is flawed. Sometimes only moderately flawed, sometimes downright evil, but flawed none-the-less.

And there is the brilliance of the American system!

Everyone is selfish, self-centered, egotistical, etc. So they fight, hurl mud, organize campaigns of misinformation, etc. And they fight each other. Meanwhile, every effort they make to fight each other is that much less attention they direct at us. We are more-or-less left alone. You need to get all the officials pulling in the same direction to get mass genocides and other such fun. But get them pulling in different directions and you get left alone.

So don't worry. They are all scoundrels, but they are scoundrels who can't work together for more than a moment or two. I'm less scared of disorganized scoundrels than an organized group of seemingly 'good men', because they are just scoundrels that hide it better.

User Journal

Journal Journal: I hate this season in election years

All the stupid positive ads of Candidate Bob with his wonderful family, soft lights and easy listening music (but devoid of positions and facts) are gone. replaced by stupid nasty attack ads full of innuendo, mischaracterization and lies and are equally devoid of positoons and facts.

And they are the same from BOTH sides.

If people wonder why we distrust our politicians, simply go check the negative ads run against the person who wins - plenty of reason to distrust the winner, and then check the negative ads they put against their opponents - even MORE reason to disrespect and distrust the winner (no matter who it is).

When will they give me someone to vote FOR instead of against?

Probably never.

User Journal

Journal Journal: Congrats, Tigers 2

Here is the rule that everyone should remember:

Unless there is a severe flaw in some other part of their game, the team that pitches better will win.

The Tigers have no flaws, and they simply pitched better. Wang and Mussina are a nice pair but I don't have anyone I feel good about 3 through 5 and I don't have any confidence in my relievers short of Rivera.

Good luck, Detroit. I hope you come back to NY for the World Series. On paper the Mets probably match up the best, although they've had some injuries lately and they are playing in Quadruple "A" rather than the major league. Your path look pretty clear from here on out.

User Journal

Journal Journal: [Baseball] Is there a better all-around player? 4

Mr. November showed up again tonight. He's a relatively quiet guy - such that it baffles the mind to think how the average spoiled star would behave with his numbers.

After ten years, it is time that we can appropriately ask "Is he the greatest of his generation? Is he on par with the greatest of all time?

  1. Hits for power
  2. Hits for average
  3. Hits situationally
  4. Hits in the clutch
  5. Hits to all fields
  6. Runs the bases well
  7. Fields his position exceptionally
  8. Positive clubhouse influence
  9. Good leader
  10. Good role model

There simply aren't any holes in his game.

Now there is a certain pitcher whom is a definite first ballot hall-of-famer, but he is a bit more difficult to measure against the all time greats. Pitchers have become so specialized that it is tough to measure a closer against the great starters of previous eras. You can't argue with a 0.81 post-season era over a very large body of work. You can't plausibly argue that there has been a better closer since the emergence of the modern closer, but would a Sandy Kofax have been even better if he was used in the same role? Who can say?

User Journal

Journal Journal: For StB: Some practical Java info... 1

Sam, the following are some things that I remember confusing lots of beginners and didn't seem to be covered very well it lots of books. I'd suggest trying to wrap your head around this as early as possible.

Packages

Imagine that I wrote a class called Log that handles log files. Now Blinder wrote a class called Log that provides a whole bunch of mathematical operations based on Logarithms. Finally, Fort Knox writes a class called Log that is part of the data model for a timber company. Now say you want to write an application that uses all three of our classes. How do you keep all three straight?

This problem comes up so often in the software world that Java provided a set of best practices on how to handle it right from the start: packages.

A package forms part of the name for a class. In that way, all three Log classes can have different names.

A set of rules and conventions are generally followed when naming packages. Here they are off the top of my head:

  1. package names are always in lower case, while class names start with case characters
  2. package names consist of one or more words with dots between them
  3. package names that start with java are part of the java language as defined by Sun
  4. package names that start with javax are optional parts or extensions to the java language as defined by sun
  5. everyone else uses reverse internet domains to distinguish packages

The full name of the Map class provided by Sun is java.util.Map. When I write a class as part of professional services engagement for my company, I write com.mycompanyname.ps.projectname.other.descriptive.text.MyClass. This seems like a pain in the ass at first, but it quickly becomes second nature.

The packages normally translate into directories. So when I write the code for com.mycompanyname.ps.projectname.other.descriptive.text.MyClass I do it in a file named com/mycompanyname/ps/projectname/other/descriptive/text/MyClass.java. When that file is compiled, the output will go to com/mycompanyname/ps/projectname/other/descriptive/text/MyClass.class. Again, this seems like a pain in the ass, but it too will become second nature.

I can take a bunch of class files and put them into a zip file, then use that zip file as a "library". This zip file is usually a "jar" file, which stands for "Java ARchive", and has the extension "jar". The directory structure inside the jar will still contain com/mycompanyname/ps/projectname/other/....

For things like classwork, your email address is probably the good root for a package name. You'll probably want to put your work in packages like com.gmail.samthebutcher.schoolname.cs101.proj1...

Typing out the full name of a class every time you need to reference it can be very tedious. By using the keyword "import" at the top of java file, you can avoid having to type out the whole name every time you need to reference it. So I can use the command "import com.mycompanyname.ps.projectname.other.descriptive.text.MyClass;", then I can just use the short name MyClass within my code, and Java knows what I mean.

I can also import an entire package at once by typing "import com.mycompanyname.ps.projectname.other.descriptive.text.*;". Understand, however, that this only imports that specific package. If there is another package with a name that includes that name but then has another leve, like com.mycompanyname.ps.projectname.other.descriptive.text.anextralevel.MyClass, it is a totally seperate package and won't get included with the *.

The package java.lang is always imported automatically. String and java.lang.String are the same thing.

Jar Utility

As mentioned briefly above, Java has the capability to work with lots of class files bundled together in a zip format. While Java can use a plain old zip file, most of the time java uses a specialized zip file called a Java ARchive, with a jar extension. A jar contains an extra directory, META_INF, and an extra file META-INF/MANIFEST.MF. The manifest file is used to store metadat about the jar, and do some other things you don't need to know about right now.

Java provides a jar utility to make, update, and view jar files. The jar utility takes many of the same command line switches as the unix tar command, so it is pretty easy to use. BTW, the "M" switch suppresses the generation of the manifest, so the command "java cfM MyZip.zip ..." is a pretty good way to zip up a file or directory.

Ant nad your project structure

The Apache Foundation supplies lots of great Java utilities. One of which is Ant, available at http://ant.apache.org/. Ant is basically a build automation tool. A file, build.xml, resides in the base direcotyr of your project. Then you issue command like "ant compile" or "ant clean" and ant builds your project. Ant is, by far, the most widely used tool for doing this.

Typically, you'll give each project its own base dir. It might be ~/mycode/myproject, or it could be somewhere else. Under that base dir, you'll normally have your build.xml file a dir src/, and maybe a dir lib/. The lib directory will contain any third party libraries and jar files. You'll write your code under src, taking care to have the right subdirectories to tie in with your packages.

After you have written some source, you need to compile it. Here is where you start using ant. You'll issue the command "ant compile". First ant will notice that the compile task is dependent on a task nameed "init". "init" is responsible for building out the remainsing subdirectories that you need. I usually have init create a directory build/ for any generated files, build/classes/ for the class files that correspond to my code under src/, and dist/ for any jar files that I generate. After init runs, then the compile task runs, compiling each of the source files and placing them in a tree that corresponds to their package names under build/classes/.

Now, after going back and fixing some syntax errors, I want to try running my program. I use the command "ant run" and ant will set up the appropriate classpath, then execute my program. Finally, I want to bundle up my program in a jar file. I can issue the command "ant jar" and ant will build my jar file.

"ant -projecthelp" will list all the possible tasks that have been defined for this project.

Putting it Together

Here is a sample development environment demoing both packages and Ant. I'm not sure if slashdot will let me get away with uuencoding.

begin 755 HelloWorld_src.zip
M4$L#!`H````(`&&>)#40OF:J[0$``'0&```)````8G5I;&0N>&ULC56Y;MPP
M$.T-^!]H(JW(I-^UBS1I`J1S$\#@BB.'NQ0E#*F%#^3?,Q0EKJ1HCXX<SKSW
MYI(V3V^U94=`;QJWY=_$5\Z>'N_O-BTV>R@#<ZJ&+?\!UC;/#5K-F89*=39L
M>=G4K;'`R?W^CK$8T@*&]R%FKU!4]"[BE;.CLMT,29`#9_)Q+=9C>3'V)3I\
MF#;%)P05_C"CLRQ16N5]M/)$(>/Y/V_LW-)S>`8+-;C`;%.JT%=GUQFK?_?>
MX+/T&6Y0^`ICU4H+RF5,38`!F#8X(,D12:ZY:.,#'RD2["J)<29DCOI`L1<I
M)AZW,HQ]ILZWX+1?<.[5497IS%@N)4*UUHK1C_K7:Q"23MFJP8<5\2.3[*FN
M"^X'*XN=C.F@%]E.>5@AFNJ(XY=J)+]\SF;Y[P@5RZF<J<@[6WJK"@'-KJ-6
M)D$_E7'%]TB29YE4B==:&2L0CK4Y@/"J;BU4#=)!3!=.SL$?BN(B6<]3_(K5
M'LF6&$5QRD`N4HA5QNLUIN4K8NO.#`4]GXHLSA=VMNC3PL);:3L]YI3:-$UC
MX=##G=XWD@1<3X*6__R@#*.=1CIOPHU-.U6;W@Y;'K"#B7&^)O-OT"24F!H'
MB`T."&S2MRCNIA2+^3[$VR)%,IT;]2N)K$A<^:+0-S+]3OK;/U!+`P0*````
M```IGB0U````````````````!````'-R8R]02P,$"@``````#IXD-0``````
M``````````@```!S<F,O8V]M+U!+`P0*```````.GB0U````````````````
M#@```'-R8R]C;VTO9VUA:6PO4$L#!`H```````Z>)#4````````````````6
M````<W)C+V-O;2]G;6%I;"]R979M:6ME+U!+`P0*``````!$GB0U````````
M````````(P```'-R8R]C;VTO9VUA:6PO<F5V;6EK92]S86UP;&5F;W)S86TO
M4$L#!`H````(`$*>)#5>S$WLA@```*D````R````<W)C+V-O;2]G;6%I;"]R
M979M:6ME+W-A;7!L969O<G-A;2](96QL;U=O<FQD+FIA=F$UC$T*PC`0A?>!
MW&'HJ@7)!7H!]UVX$!?3=`RADQ^2M"#BW1VK/AZ\@?GX,MH5'8%-P;B`GDVA
M/?B53,60F>ZIR#%JE;>9O07+6"N<B3E=4N$%GEJ!Y/>N#9O,GOP"8HO]U(J/
M[GH#+*X.?_J3Z5$;!9.V9K(PC6/?'=X3'.9N&+_P2ROI&U!+`0(4`PH````(
M`&&>)#40OF:J[0$``'0&```)``````````````"D@0````!B=6EL9"YX;6Q0
M2P$"%`,*```````IGB0U````````````````!````````````!``[4$4`@``
M<W)C+U!+`0(4`PH```````Z>)#4````````````````(````````````$`#M
M038"``!S<F,O8V]M+U!+`0(4`PH```````Z>)#4````````````````.````
M````````$`#M05P"``!S<F,O8V]M+V=M86EL+U!+`0(4`PH```````Z>)#4`
M```````````````6````````````$`#M08@"``!S<F,O8V]M+V=M86EL+W)E
M=FUI:V4O4$L!`A0#"@``````1)XD-0```````````````",````````````0
M`.U!O`(``'-R8R]C;VTO9VUA:6PO<F5V;6EK92]S86UP;&5F;W)S86TO4$L!
M`A0#"@````@`0IXD-5[,3>R&````J0```#(``````````````*2!_0(``'-R
M8R]C;VTO9VUA:6PO<F5V;6EK92]S86UP;&5F;W)S86TO2&5L;&]7;W)L9"YJ
9879A4$L%!@`````'``<`T`$``-,#````````
`
end

The uuencode almost works. Pull out the random spaces and everything should be ok.

User Journal

Journal Journal: Brother Sam... 3

how was school? Your first day of the new class was a few days ago, right?
User Journal

Journal Journal: An open letter to Tigers fans 3

I don't believe my team (NY Yankees) has a realistic chance right now, so I don't have a dog in this race...

Would you actually feel good about putting the ball in All Star starting pitcher Kenny Rogers' hands in a critical playoff situation, or do you sometimes wake up in the middle of the night in a cold sweat and an overwhelming feeling of dread?

If you do feel confident, please explain why, given his 0-3, 8.85 era in 9 playoff appearances record.

Slashdot Top Deals

Any circuit design must contain at least one part which is obsolete, two parts which are unobtainable, and three parts which are still under development.

Working...