Category Archives: Platforms

The easy way to record any audio playback in Windows

People jump through all sorts of hoops trying to record audio direct from the source, which is particularly tricky when it’s a WMA or Real streaming cast.

But it’s actually dead simple to do this, at least for short periods: (Instructions for Windows XP)

Windows XP volume control1. Double-click on the Volume Control speaker in the taskbar. The full Volume Control will open up, with lots of different levels.

2. Click Options / Properties. Then in Adjust Volume For, choose Recording. Then make sure either Mono Mix or Stereo Mix are turned on. (Obviously Mono is sufficient for streaming of AM radio stations, for instance.) Then click OK.

3. The recording levels will then be displayed. Click on Select for the Mono or Stereo Mix option you’re going to use, and adjust the volume to something sensible. This will tell Windows which of the many “inputs” you wish to record audio from.

4. Leave the recording levels visible, and go and open Sound Recorder, as well as whatever sound source you want. When you click Record in Sound Recorder, you should find it successfully records whatever sounds are outputting from the computer at the time. Adjust the volume level to suit.

As many know, Sound Recorder will only record up to 60 seconds at a time. So it’s not perfect, but it is built-in to Windows, so everybody has it, so it’s a good quick’n’dirty solution for short recordings.

I’d assume that other recording tools that can record for longer periods would also use the Volume Control applet to choose which input they’re taking. At least I hope so.

Reboot now?

I’m sure I’m not the only one who has been busily tapping away at the keyboard when a dialogue pops up saying “Update installed! Would you like to reboot now?”, and before I can read it and register what it’s asking, a rogue Y, space or Enter keypress happens to tell it that Yes, it is okay to reboot the machine right now…

Setting up SFTP/SSH on Windows

I’ve been wrestling with OpenSSH for Windows to set up an SFTP server. I’m still ironing out some of the fine detail, but the basic steps are below.

This article covers the initial setup:

  • Install the software
  • If the FTP user doesn’t already exist in Windows, create it.
  • Open a command prompt in the c:\program files\openssh directory (assuming that’s where it’s installed)
  • Set up the group file: mkgroup -l >> etc\group
  • Set up the passwd file: mkpasswd -l -u username >> etc\passwd
    The -l means local user. If it’s a domain user, use -d. Type just mkpasswd for help.
  • Create the home directory for your user. If following the IIS standard, that would be c:\inetpub\ftproot\username — but it can be anywhere
  • Edit the passwd file to put the home directory in. Load it in Notepad or another text editor. As with all the files to do with OpenSSH, passwd is in Unix format, so you may do better to use an editor that knows Unix end-of-line characters. Anyhow, change the second last field to match the home directory. Cygdrive notation needs to be used, eg for the above /cygdrive/c/inetpub/ftproot/username
  • For domain users, you’ll have to make sure the Domain Users group is added to the groups file. This can be done by doing a mkgroup > textfile.txt and then extracting the line for Domain Users from the file and adding it manually to the etc\groups file.
    Also double-check that the group ID (the third field in the groups file, which is delimited by colons) matches the ID your user(s) in the passwd file (the fourth field).
  • Start the OpenSSH service (note that when adding additional users, you do not need to restart the service

Continue reading

Low impact installations

If only application installations were more like Java or Flash applets — low impact, with no permanent hooks into the host computer. Files that just sit in a directory, rather than installing themselves all over the filesystem, the registry, wherever-else.

Then maybe we wouldn’t be tempted to regularly rebuild operating systems, just to regain some of the lost performance, and removal of unused apps would be clean and painless.

Is it too much to ask?

No Vista clean install for you!

Counting on buying an upgrade version of Windows Vista, but wiping the machine first of the old version so it’s a clean install? Bad luck, Microsoft’s made changes that will prevent it, unless you install onto an empty partition. Never mind that it’ll make a periodic re-install a right pain in the arse. What were they thinking?

PS. Tuesday: Ed Bott pours cold water on this, not saying it’s untrue, but saying “wait and see…”

SFTP from scheduled tasks

I was asked to set up a daily SFTP job to push files off a Windows box.

Windows has FTP built-in. But SFTP? Well there’s the free (and open-source) Putty implementation which provides a number of SSH tools, including SFTP. Free is good. I like free.

Putty SFTP is fairly straightforward to use from the command line; pretty similar to any other ftp client. Basically chuck everything into a directory and you can run it directly. Under Windows it caches public keys into the Windows Registry in HKEY_CURRENT_USER, and will ask about this the first time.

For batch use, you can create a BAT file that calls it like this

psftp -l [user] -pw [password] [host] -P [port] -b [scriptfile]

…and just put your FTP commands into the script file.

For running it as a scheduled task, you’d preferably want to run it under a special user, as you wouldn’t want it under your own user account. It seems not to like asking about caching unless you’re the person logged in. Even running with RUNAS didn’t work for me — it flashed up something lightning-fast, but immediately failed.

The only way around it I could find was to log on interactively as the scheduled task user. As expected it asked the first time. Subsequent times it didn’t ask, and worked happily as a scheduled task.

(Also found recently: How to set up an SFTP server on a Windows machine. Or a prefab one like FreeFtpD is also an option.)

Train Simulator 2 arriving soon

For all the geek train nuts out there, it’s been confirmed that Microsoft is working on a second version of Train Simulator. The lead developer, Rick Selby has surfaced with a blog so people can track progress. (I wonder if he knows there’s a Puffing Billy station named after him?) In fact, the official site links to numerous developers’ blogs.

I’ve played both Train Simulator and its main opposition, Trainz… to my mind, Trainz is probably better, and they’ve kept working on their product over the past few years, as TS has been somewhat neglected (and I haven’t had it installed in quite some time partially because it won’t run without Admin privileges).

Windows Vista imperialism?

There’s some disquiet about the Windows Vista Games menu, highlighting the fact that use of parental controls will mean any game without an ESRB rating won’t appear. The ratings apparently cost US$2000-3000 to obtain, which means they’re effectively out of the range of independent games developers.

So I guess Snood and the like wouldn’t appear on the Vista games menu.

What I want to know is — are the North American ESRB ratings going to be forced onto every user the world over who wants to use the parental controls?

I’m not going to claim for a moment that the Australian government’s Office of Film and Literature Classification is perfect, but I do want to know if the Vista games menu when used by Australians will be showing Australian ratings (G, G8+, M, MA) rather than the unfamiliar North American ratings (C, E, T, M, A). And likewise for every other country.

We have enough troubles with products constantly defaulting to US English. We don’t need another North American standard rammed down our throats.

Apple iPhone

Apple has announced the iPhone — which at first glance looks like an iPod (with video) combined with a phone combined with an internet browser (a version of Safari).

Of course, most phones now have similar functionality. This looks like it’ll have a bigger screen (with a soft keyboard — byebye click wheel) and of course Apple’s nice design should mean it’s easier than most phones to use.

With past false-starts like WAP, and the constraints of most existing mobile phone internet browsers, and the cost and geekiness of PDAs, perhaps this will be the thing that brings mobile internet into the mainstream.

And if you’re wondering if it’ll work outside North America, well apparently it will be GSM quadband, so my guess is it’s only a matter of time before it’s widely available throughout the western world.

PS.: Apple’s press release mentions availability: iPhone will be available in the US in June 2007, Europe in late 2007, and Asia in 2008 …

Update Friday: Cisco’s Mark Chandler blogs about the trademark infringement suit

Attachment manager

You learn something new every day. Or maybe every week. This week I learnt about Attachment Manager.

Remember how we wailed when, back in 2000, Microsoft patched Outlook to block extensions from dozens of file types that were useful, but dangerous err powerful. Initially the extra security was optional, but it came built into later versions of Outlook.

Some of us resorted to hacks like Attachment Options to tell Outlook to STFU and give us the attachment.

From XP SP2 they’ve replaced it with the Attachment Manager (via David), which provides an extra prompt when you try and open/run the file. The file attribute even survives the file being moved around, provided it’s on NTFS. And it covers numerous applications, including Outlook, IE and MSN IM.

In some cases it simply won’t let you open/extract the file. For those you need to go into the Properties and Unblock it manually. Just another hoop to jump through.