Press "Enter" to skip to content

Posts tagged as “Development”

Synergy

centaur 0
Way back when I started work at the search engine that starts with a G, I tried a number of new programs including Synergy, a program to sync the mouse and keyboard of two computers.

The claimed magic was this: you set your laptop computer next to your desktop computer and plug into your network, take your mouse from your desktop and MOVE THE POINTER OVER ONTO YOUR LAPTOP SCREEN (!) and then just start typing. When you want the keyboard to move back to the desktop, you just move the mouse pointer back and when it leaves one computer screen and reappears on the other, magic, whoosh, you're back in control of your desktop.

Well, that was the claimed magic; it didn't work so well with the versions of Linux and Windows we were using at the time, or perhaps the release of Synergy that existed then is not as good as what exists now. Regardless, I never got it to work then, but a year later, with a new Linux distro and a brand spanking new Mac laptop, I got it running like a charm in just a few minutes.

The kindly folks who run the computers at the search engine that starts with a G preinstall synergy on our Linux desktops, so all that remains to do at work is download a Synergy client like
SynergyOSX or, even better, its recommended replacement SynergyKM, install it, and set up the configuration.

I liked this so much I wanted to try this at home - but there was only one snag. At home I work in primarily PC environment. Yes, yes, I know, I should make better use of my two Macs and my Linux desktop and my Palm Pilot and my Newton and my Apple IIc, but let's stay focused here people on what I do use every day, which is the nice Windows laptop and its big brother desktop with the 24-inch LCD screen.

However, I found on the PC, in some ways Synergy is even simpler except for a typical Windows snag. All you need to do is download one Synergy binary for Windows and install it on both machines. On the server, you get a nice desktop icon for Synergy, and clicking on it gives you the option to listen to another machine's mouse and keyboard or else to share this one's. Clicking on that enables a dialog box where you can list the names of your two machines and set up "links" between screens that the mouse pointer can travel on. (Note: these links did not appear to be symmetrical, so if you specify that your laptop is to the left of your desktop, you actually need to specify the vice versa link as well or your mouse may become trapped after it crosses the border.) On the client you do a similar procedure, specifying what machine name it should listen to as it server.

However, the snag is that these are machine names, not IP addresses. At work the kindly techfolks have set up the whole infrastructure for you to resolve names to IP addresses, which Synergy depends on; at home, on a simple router, you may need to set this up yourself. Trying to specify the IP addresses causes Synergy to throw errors and not work, and ignoring the problem just means your Synergy client won't be able to find your Synergy server.

A simple way around this problem is with a hosts file, which tells Windows how to map names to IP addresses on your local network. This enables you to specify a few lines that say (for example) that the IP address 192.168.1.2 maps to "desktop" and that 192.168.1.3 maps to "laptop". I added a pair of lines to the hosts file on both my desktop and my laptop to make sure both programs could talk to each other (note: all names confabulated to protect my innocent little computers):


192.168.1.3 desktop
192.168.1.4 laptop


This gives Windows enough information to map these names to their IPs. (Note that this assumes your router or cable modem IP assignments are stable; consult your documentation on how to set this up more reliably if you have problems.) With that information, Synergy can decode these names and the client can find the server and vice versa.

And with that, it works. I move my mouse over, stuff changes on my laptop, I move my mouse back, I finish typing this essay. Not even sexay-looking enough to take a screenshot, but radically useful and easy as pie. I wish I'd done it earlier.

-the Centaur

Cool Technical Talks

centaur 1
With the explosion of online video we now have a fountain of new information: free technical talk vidoes. I've found a few of these so far and had others recommended to me:



I've had a chance to see or attend a fair number of the first talks, but the others are new to me as of today. Anyone else have any suggestions? Add to the comments (or mail me and I'll post them here).

-the Centaur

The Wiki Is Dead Again…

centaur 0
... and I know why, though I haven't been able to fix it yet. Stay tuned, or keep checking the wiki for details...

When To Wiki Rather Than Blog

centaur 0
Recently at my writing group someone mentioned they were having a lot of difficulty translating their story notes into an outline and asked for help. As we started talking to him, we found out that he'd bought a beautiful, expensive notebook into which he planned to write his thoughts, as soon as his thoughts were together. The advice of the group coordinator could be summed up as: "Get rid of your pretty notebook that you're afraid to write in, because it's getting in the way. Buy a cheap yellow legal pad and WRITE."

SO, what I've found? As cheap and disposable as blog entries are, they're still aimed towards recording complete thoughts. If you can't finish a thought, or it needs to be refined, blogging (for me) gets in the way, because my thoughts drift backward into the distance and I never finish them.

THAT is why I've reinitialized the wiki over at dresan.net. A wiki's pages are automagically editable and suitable for recording incomplete, incoherent, half-completed thoughts that can be edited, updated, or reorganized as need be. My blog was becoming my pristine notebook; so time to whip out something sloppy that I can just write on, regardless of how well formed my thoughts are.

So, for example, when I'm trying to get SLIME working for XEmacs on Windows with CLISP running on Cygwin, and I haven't quite figured it out yet, I can just create a wiki entry on dresan.net about Slime which captures my current thoughts, crossreferenced with XEmacs and CLISP and Cygwin which I can edit and refine to my heart's content.

If there's an easy way to do that on a traditional blog, I don't know it yet. But I can make a wiki proxy a blog: see the updates page of dresan.net for a good example.

Not that I want to give up blogging in favor of futzing around on a wiki; there's something deeply satisfying about this blog and its interface. But I do miss my wiki features on the blog, and I hope that one day either Blogger adapts those features or else that I find a wiki/blog/bliki that does the job that I can port all my old data from.

Blog/Wiki developers, take note.
-the Centaur

dresan.net

centaur 0
Over on our sister site www.dresan.net, I've added a wiki, a blog, and some forums. For an explanation of why, check out Why Dresan.Net? over on the dresan.net blog.

The short story is that the Library of Dresan will remain my primary blog, but I've created dresan.net as a playground to experiment with new technologies. It's still a little rough, but I hope to beat it into shape over the next few weeks.

So enjoy!
-the Centaur

Scrolling through RSS

centaur 2
Once again, I am behind the technology curve. Google Reader provides a convenient interface to a whole bunch of RSS feeds with a much more convenient interface than my other RSS readers - plus it has a neat "scrolling down counts a message as read unless you tell me otherwise" feature which makes it easy to keep up with new articles just by scrolling through whatever's new every time you look at it. Like Google Bookmarks (available if you log in) and Google Notebook (available through the Google Labs page) all these "always-on" services are changing my view of the Web.

Except of course I still can't get internet at home, dag nab it, since I live on the surface of Mars, which does put a kink in the whole thing (hence my nickname "Internet Cafe Boy"). Oh well. I pray that state of affairs won't last forever.

-Anthony

Pacman … in Excel???

centaur 0
Mother of Mercy. I was digging through my old posts and found this unpublished, unfinished draft started on October 4, 2006 titled "pacman???". Apparently I stumbled across version of Pacman written in Excel and was so shocked that I could only write the outline of the post in a barely organized list of URLs.

Reading through those ... apparently my initial horror led me to look into a whole bunch of other things, including the Javascript Arcade with versions of classic games written in Javascript. Back then, people were looking at using a variety of DHTML tricks to do graphics in Javascript. In the days of Chrome Experiments, a few short years later, this no longer seems insane, though now you're more likely to want to do this in Flash ... and sure enough someone has done so.

Reading through the tiny notes and trying to reconstruct my thought process ... apparently the idea of using Excel to implement Pac Man, and the challenges of drawing lines in the DOM, took me back to the ideas of in Fundamentals of Interactive Computer Graphics, Jim Foley's text, the first book I learned graphics from. There have been many versions of that book since, but they'll all tell you how to create lines on a grid, whether you're doing it with low-level hardware or with cells in Excel ... shudder.

Apparently creating graphics on top of a windowing system and browser reminded me of the idea of virtual machines, a fundamental idea in computer science in which one computer system can be used as the "physical hardware" to create another computer system on top of it. Once you create one virtual machine, it can then be used to create another ... and another, and another. Another "seminal" book for me, Douglas Hofstadter's Godel Escher Bach, explores the consequences of layers of virtual machines in much creative detail.

So the point being, the more advanced our computers become, the more likely it is that we'll be creating things like Pac Man in Excel.

I don't know whether to weep in joy or fear.

-the Centaur

A little better…

centaur 0
The feed is improving. Corrected ordering, titles, added escaped summaries, fixed date format and got a temp ID up, plus fixed some of my own Python problems. More in a bit...

-the Centaur

I know Atom Fu

centaur 0
Show me.

Seriously, Fanu Fiku now has a nascent Atom feed. The atom.xml feed produced by fiku.py has some validation errors but the feed seems to read fine in my first newsreader tets.

Hopefully before the next issue goes up I'll be able to correct the blog title issue and make the validation problems go away with the help of the Feed Validator and the Atom Standard.

Once I get it running, I'll post a bit more about what's going on under the hood in fiku.py to make this happen.

Till then, fellow fanu, remember to believe...

-the Centaur

Football vs Videogames: A good question

centaur 0
Alright, I'll bite: Why are we upset about videogame violence if regular sports also cause violence? Simply because videogames are new and different? Or, because they are the banner of a new generation, they are "safe" for an older generation of politicians to attack?

Clearly high school sports violence isn't something new, and few people would consider banning it. How do we educate our public and politicians about how to think properly about things that are new and different?

And by "properly" I don't mean "agreeing with me" --- reasonable people can disagree about the possible dangers of things like videogames and still remain reasonable --- instead I mean testing ideas against evidence, putting things in their proper context, and applying values formulated as universals, which means that in general you do NOT toss a call for ban or investigation onto the publicity trail of every pseudosensation that swims down the stream, but take a measured ... dare I say "conservative" ... attiude towards any call for government regulation.

-the Centaur

Wiki Hacked Again

centaur 0
Well, the wiki is down again. Some idiot with a spambot corrupted all the pages - and when I tried to correct them, it appeared like the pages changed back to spam as fast as I corrected them. So it's down. Up again soon, I hope. If only I'd written down all those cool things Bolot showed me ... oh, wait, I did :-)

-Anthony

Memories…

centaur 0
Wow. This set of screenshots on the evolution of Windows from 1.0 to Windows XP really brings back memories. I first started using Windows in college around version 2.0 - I remember seeing Windows 286 in stores but don't recall using it. Windows 3.0 was a big step forward for us early adopters - up until Windows 2000 I always managed to score a prerelease version (though as a point of pride I always went out and bought a real copy as soon as it hit the stores). I held off on Windows XP, though, as long as possible, waiting until I bought a machine with Windows preinstalled.

But, while I relish the memories, I'd never go back (though I may end up going forward to Mac OS X :-):





Here's an early 10th birthday to you, Windows.

-Anthony

Words of Wisdom … Not Just for Software

centaur 0
Erich Gamma, one of the software luminaries behind the Design Patterns book and now part of the Eclipse Project, had the following things to say about software ... that apply to a little more than just software:

Eclipse's Culture of Shipping: "In software, having cool ideas is nice, but shipping them is what counts. For us it only counts if you have shipped the thing. That's really the mindset we have. And given that you focus on shipping, we never want to be in a mode of always being two years away from shipping. You need to have a short-term deliverable. You also plan, decide and act with this mindset."


You know, all artists should probably learn this lesson. It's easy to plan the Great American Novel or the Next Great SF/Fantasy Trilogy, but in the meantime write some damn stories, paint some paintings, write a webcomic, and get your stuff out there.

-the Centaur

Bolot Kerimbaev, Technology Commando

centaur 1


SO many of you (where many is defined as N greater than or equal to one) may remember that the Wiki was down for "security reasons". Well, this wasn't that someone had hacked the site, trashed the data or even just spammed the comments pages: it was, more literally, a security issue with my web hosting provider, which tightened its security provisions on script hosting and killed OddMuse, the wiki engine I was using. Fortunately Bolot Kerimbaev, a friend from Taido class, uses the same wiki engine and the same service provider, and he told me that the use of semicolons rather than ampersands in the URLs was causing the problem. A simple fix, really.

Well, not so simple.

I worked at it for a while, but found that other features were broken on my site as well ... because semicolons were EVERYWHERE in URLs in the OddMuse code. At first I tried changing them individually, then, as the problem got more complex, decided to try to abstract out the separator character into a $SEP variable that I could change and control. That worked well ... for a while ... but eventually the OddMuse instance I was working on became unstable, then stopped working entirely. Because I'd been futzing around with vi on a local directory and uploading the Perl script to my web site rather than using proper source control (for shame!), I couldn't even roll things back successfully without losing all of my changes.

SO I called Bolot for help, and we got together at Atlanta Bread Company at Perimieter Point to take care of the problem. This Atlanta Bread Company (one of their best stores) is right next to a Starbucks Coffee, which kindly provides T-Mobile Wi-Fi. So we logged in and tackled the problem, and after a few minutes showing Bolot what was going wrong, he took over the keyboard to fix it.

And a whole lot more.

First, rather than laboriously editing the files locally and uploading them with FTP, Bolot suggested we use SSH and edit the files in place so we could see the changes immediately. This point is so important I'm going to follow it up with a separate post, but that's another blog for another day. Now, apparently I got through thirteen and a half years of Georgia Tech without using SSH extensively (I almost always relied upon remote X Windows logins prior to my Windows/Cygwin days) so this option never occurred to me. Bolot, however, was able to do it almost instantly:

ssh -l username hostname

Moreover, we found that using the Cygwin instance on my laptop, we could not just SSH in to the site ... but could actually use VIM, the enhanced VI editor. And with a few quick commands, he had syntax highlighting and color schemes working - remotely, via SSH, in the bash window already set up in Cygwin on my machine. Other than the window title and the lack of a toolbar, it looked identical to the gVIM I frequently use on my machine.

vim
   :colors darkblue
   :set nu

(Note tab completion actually works on setting the colors!

After finding and fixing the first and most important of the problems, we then went to test. Bolot immediately became frustrated with my Internet Explorer installation and turned to my copy of Firefox instead, which was hopelessly out of date. Within moments, he showed me why people use Firefox: within moments he was able to painlessly install gesture support, web developer tools, a variety of search tools, flash blocking, ad blocking, and a host of other applications which made the Firefox experience almost palatable, despite the fact that its interface is still slower, clunkier and uglier than IE. Shortly thereafter, Bolot was able to find and eliminate the rest of the problems in OddMuse, realizing that the problem was not semicolons in URLs in general, but the presence of the string ";id" in the URL. By the time he was done, he had not just corrected the problems in OddMuse itself, but also other problems with my installation which were interfering with stylesheets.

SO: an improved browser, web site, method of connecting to the web site, and a whole host of other tools. All delivered straight to my brain in less than an hour.

Lessons learned: Be dogged with your tools. Find out all they have to offer you. Use them as they were best intended. And be dogged about eliminating problems in your way. Make it possible to get feedback on changes instantly, so you make many small changes safely and feel free to experiment. Then, you will be able to work far faster than you ever thought possible.

More thoughts on this later .... but, until then, hats off to you, Bolot Kerimbaev, Technology Commando.

-the Centaur

I am not alone

centaur 0
So at least Slava Pestov sees the rising tide of jargonitis that I do. (Of course, he's writing Factor, his own next-generation Forth (perhaps the only language as terse as APL ... almost), so you'd expect he'd be down on jargonitis).

But the point is, it ain't just me.

Clean up your act, folks. This will come back to bite ya.

-the Centaur

Trying to decipher line noise?

centaur 0
Try the Regex Coach --- this looks like a way cool way to figure out the comic-book cusswords that Perl, Awk and their friends use for regular expression matching (finding strings in longer strings).

I particularly like the tool's ability to translate what a regular expression means into human-readable language:



Check it out!
-the Centaur

Oh, and I just discovered RSS…

centaur 0
... so sue me. Or just subscribe to the Library of Dresan
RSS Feed.
Actually technically it's an Atom feed, but, hey, they're all the same to SharpReader.

Ok, so now I have to upgrade my Python webcomic script to produce an XML site feed, which I suppose means I have to add XML support to Sangreal for when I switch the script over to Sangreal. Rassen frassen ... yes, I *do* plan to join the 21st century, give me a break...