Archive for the ‘Uncategorized’ Category

Making a perfect Media Centre….

September 11, 2005

Aside from the basic hardware that you need to run a Windows Media Centre machine there’s a big of a hardware and software learning curve to get the setup working sweetly. For different people the list will differ but I’ll share some things I’ve found….

Hardware
The biggest thing that I’d change with my initial setup is the fans ! The one on the video card is pretty noisy – and initial attempts to fit a Zalman VGA Cooler to it created a monster about 5mm too tall to close the case ! Knowing what I know now, I’d probably have put in a slightly faster processor (not that this one is a problem, just thinking ahead) and maybe gone for an even larger hard drive….

The biggest area however that you can tweak and personalise the solution is…
Software

WebGuide

Allows you to connect to your machine and schedule recordings from the other side of the world

SlySoft AnyDVD

If, like me, you often get DVDs from friends overseas this allows you to play them without region protecting getting in the way.

DVD Shrink
Sometimes you just want to backup your DVDs to the hard drive. It makes for easy access and stops the kids using them as a coaster. This app lets you make a personal use backup (with and without various levels of compression) of any DVD you own.

MyMovies

The ultimate way to manage DVD and Videos within your MCE. Browse your movie collection by titles, actors, directors or genres – all with covers and images. You can also password restrict certain movies by MPAA rating, build a multizone movie index and much more!

BladeRunner Pro
Here in Australia we don’t yet have a working EPG (Boo Hiss to the networks who copyright the data) so there are some work-arounds. BRP is pretty much the easiest and most comprehensive free solution.

FrontView
If you have a VFD or LCD display on your case, why not make it earn its keep when MCE is running

mceWeather
Sometimes it’s nice to get a bit more information than just looking out of the window. This utility grabs data from The Weather Channel to give you up to a weeks forecast

mControl

If you have an X10 installation, this allows you to control it from your MCE

Without a doubt a community forum such as XPMediaCentre (AU) is going to be your best source for support, advice and handy applications….

Trusted Computing….

September 11, 2005

I’d love to trust my computer.
Trust it to be reliable.
Trust it to be virus free.
Trust it to reject malware.
The Trusted Computing Platform Alliance (TCPA) promise us all that….
Or do they ?
Find out what Trusted Computing is really about, and then read some more about it at www.AgainstTCPA.com.

Pzizz – software to send you to sleep ;)

September 10, 2005

It’s not often I discover a bit of software that, quite literally, is a life changer. Pzizz however seems to be just that.

Using a combination of soothing sound-scapes and hypnotic speech (with NLP – Neuro Linguistic Programming – overtones) Pzizz helps lull the user into a sleep state and can be used to either encourage deep restful sleep, or guide them through an energizing powernap.

While not a miracle cure for insomnia (mileage will vary, especially depending on how open the user is to hypnotic techniques) it’s a great, non medicating, therapy for poor sleep patterns, or people just wanting a bit of a tonic in the afternoon (finally… I have a reason for falling asleep in meetings !)

I want more Bluetooth !

September 7, 2005

Actually, what I want is a decent Bluetooth headset (ideally mono but can convert to stereo with a clip on or second ‘dumb’ earpiece wired the first) that I can use intelligently (and that’s the optimal word) with my cellphone (currently SE T610), my iPod (I’ll even put up with a small dongle until Apple pull their finger out and build it in) and my PC (for Skype or just listening without wires).

It can’t be too much to ask for can it ?

There are already BT iPod dongles with dedicated headsets, BT cellphone headsets with MP3 players and BT Skype headsets for the PC…. it can’t be too much of leap for someone to combine these in an intelligent way.

Okay, so there probably isn’t a decent remote control standard for MP3 players yet (including the iPod in that as it’s just a music player), and all the cellphones have their own quirks, and the WinXP SP2 BT stack isn’t that clever yet (heck I can use my very average Nokia HDW-2 headset with my Powerbook just by turning them on !)

Even devices that would make sense to have bluetooth – for wireless headsets or synchronisation – don’t always get them. I had great hopes for the new iPod Nano, but I’m out of luck there I fear.

Where is the world without wires ? Somewhere behind the paperless office I fear !

Upload and resize an image with ASP.NET (VB.NET)

September 7, 2005

A while ago I needed to create a function to allow a user to upload an image and have the system resize it to a thumbnail – preserving the aspect ratio, while at the same time ensuring that neither of the maximum constraints of the thumbnail width or height where breached – and then save it to the server.

The function had to be written for an ASP.NET server and ideally in VBScript to fit in with the rest of the project. To further complicate matters it was a hybrid project… a halfway house in a migration from Classic ASP to dot Net.

I did the usual trawl around Google looking for code fragments to base the function on and to my surprise almost every one of them ended up producing either terrible quality thumbnails (relying on the .net GetThumbnailImage function) or huge filesizes. It was only as a result of a lot more diligent searching that I was able to solve the latter problem and so I thought I’d share it.

You can either click to go to a working sample, with source online and in a zip file or just grab the source from here and play….

If you think this has saved you time, effort and storage space, maybe you’d like to

  1: <%@ Page Trace="False" Language="vb" aspcompat="false" debug="true" validateRequest="false"%>
2:
<%@ Import Namespace=System.Drawing %>
3:
<%@ Import Namespace=System.Drawing.Imaging %>
4:
<%@ Import Namespace=System %>
5:
<%@ Import Namespace=System.Web %>
6: <SCRIPT LANGUAGE="VBScript" runat="server">
7: const Lx = 200 ' max width for thumbnails
8: const Ly = 240 ' max height for thumbnails
9: const upload_dir = "/upload_resize_test/" ' directory to upload file
10: const upload_original = "sample" ' filename to save original as (suffix added by script)
11: const upload_thumb = "thumb" ' filename to save thumbnail as (suffix added by script)
12: const upload_max_size = 25 ' max size of the upload (KB) note: this doesn't override any server upload limits
13: dim fileExt ' used to store the file extension (saves finding it mulitple times)
14: dim newWidth, newHeight as integer ' new width/height for the thumbnail
15: dim l2 ' temp variable used when calculating new size
16: dim fileFld as HTTPPostedFile ' used to grab the file upload from the form
17: Dim originalimg As System.Drawing.Image ' used to hold the original image
18: dim msg ' display results
19: dim upload_ok as boolean ' did the upload work ?
20: </script>
21:
<%
22: randomize() ' used to help the cache-busting on the preview images
23:
upload_ok = false
24: if lcase(Request.ServerVariables("REQUEST_METHOD"))="post" then
25: fileFld = request.files(0) ' get the first file uploaded from the form (note:- you can use this to itterate through more than one image)
26:
if fileFld.ContentLength > upload_max_size * 1024 then
27: msg = "Sorry, the image must be less than " & upload_max_size & "Kb"
28: else
29: try
30: originalImg = System.Drawing.Image.FromStream(fileFld.InputStream)
31: ' work out the width/height for the thumbnail. Preserve aspect ratio and honour max width/height
32:
' Note: if the original is smaller than the thumbnail size it will be scaled up
33:
If (originalImg.Width/Lx) > (originalImg.Width/Ly) Then
34: L2 = originalImg.Width
35: newWidth = Lx
36: newHeight = originalImg.Height * (Lx / L2)
37: if newHeight > Ly then
38: newWidth = newWidth * (Ly / newHeight)
39: newHeight = Ly
40: end if
41: Else
42: L2 = originalImg.Height
43: newHeight = Ly
44: newWidth = originalImg.Width * (Ly / L2)
45: if newWidth > Lx then
46: newHeight = newHeight * (Lx / newWidth)
47: newWidth = Lx
48: end if
49: End If
50:
51: Dim thumb As New Bitmap(newWidth, newHeight)
52:
53: 'Create a graphics object
54:
Dim gr_dest As Graphics = Graphics.FromImage(thumb)
55:
56: ' just in case it's a transparent GIF force the bg to white
57:
dim sb = new SolidBrush(System.Drawing.Color.White)
58: gr_dest.FillRectangle(sb, 0, 0, thumb.Width, thumb.Height)
59:
60: 'Re-draw the image to the specified height and width
61:
gr_dest.DrawImage(originalImg, 0, 0, thumb.Width, thumb.Height)
62:
63: try
64: fileExt = System.IO.Path.GetExtension(fileFld.FileName).ToLower()
65: originalImg.save(Server.MapPath(upload_dir & upload_original & fileExt), originalImg.rawformat)
66: thumb.save(Server.MapPath(upload_dir & upload_thumb & fileExt), originalImg.rawformat)
67: msg = "Uploaded " & fileFld.FileName & " to " & Server.MapPath(upload_dir & upload_original & fileExt)
68: upload_ok = true
69: catch
70: msg = "Sorry, there was a problem saving the image."
71: end try
72: ' Housekeeping for the generated thumbnail
73:
if not thumb is nothing then
74: thumb.Dispose()
75: thumb = nothing
76: end if
77: catch
78: msg = "Sorry, that was not an image we could process."
79: end try
80: end if
81:
82: ' House Keeping !
83:
if not originalImg is nothing then
84: originalImg.Dispose()
85: originalImg = nothing
86: end if
87:
88: end if
89: %>
90: <html>
91: <head>
92: <title>ASP.NET File Upload and Resize Sample</title>
93: <META NAME="Description" CONTENT="ASP.NET File Upload and Resize Sample (Hybrid VB.NET)">
94: <META NAME="Keywords" CONTENT="ASP.NET, ASP, NET, VB, VBScript, Image, Upload, Resize, Thumbnail, Constrain, Filesize, File, Size, Free">
95: <META NAME="Copyright" CONTENT="Rufan-Redi Pty Ltd 2005">
96: <META NAME="Author" CONTENT="System developed by Jeremy at http://www.Rufan-Redi.com">
97: </head>
98: <body>
99:
100: <p><b>Hybrid ASP.NET File Upload and Resize Sample (VB.NET)</b>
101: <br>Upload and resize a GIP/JPG/PNG images, ensuring filesizes are optimum.</p>
102:
103: <form enctype="multipart/form-data" method="post" runat="server">
104: <table>
105: <tr><td>Select the file to upload:</td><td><input type="file" name="upload_file"></td></tr>
106: <tr><td colspan=2>Max upload size
<%=upload_max_size%>Kb, gif/jpg/png only</td></tr>
107: <tr><td colspan=2><input type="submit" value="Upload"></td></tr>
108: </table>
109: </form>
110:
111:
<%
112: if upload_ok then
113: %>
114: <table>
115: <tr>
116: <td valign=top><img src="
<%=upload_dir & upload_original & fileExt & "?" & rnd()%>"></td>
117: <td valign=top><img src="
<%=upload_dir & upload_thumb & fileExt & "?" & rnd()%>"></td>
118: </tr>
119: </table>
120:
<%
121: else
122: response.write(msg)
123: end if
124: %>
125: </body>
126: </html>

Someone at Google needs to look at consistent implementations….

September 3, 2005

There are some great features in the Blogger posting interface. And there are some great features in the GMail interface (especially they way it handles spelling checks !). While it’s great to see them rushing to roll out new and innovative technologies (GMail has really shaken up the webmail market, and some clients as well !) and Gtalk has the potential for a shake-up in the IM world… but rushing ahead has the potential to let existing products lag behind.

Oh, and while I’m griping about Blogger why has it not got categories / tags or whatever you want to call them yet, or the ability to (easily) post colour coded code fragments or other BB style text ?!

Cat and I have recently added Moveable Type to a couple of sites and she suggested I add it to Rufan-Redi and it’s tempting… apart from the rekeying 😉

After a year here with Blogger who knows…..

I guess what I’m looking at is one combined service.. including Blog functionality, Flickr, Del.icio.us and IM and VoIP (and maybe even spam free email) all that I can use (in sync) from my PC, cellphone, PDA and internet cafe… and know it will support new services as they appear in an open way….. Of all the providers I think that while Microsoft have the resources and infrastrucutre Google are possibly the best placed (and certainly keen) to provide that (apart from the fact that MSN will be very reluctant to open MSN up to Google tools)

Update (12 Oct 2005) – looks like it might not be that far-fetched…. MSN and Yahoo! are apparently planning to open up their IM tools to talk to each other… is this the beginning of the opening… or just a short term attempt to create critical mass on non-Google platforms….

My MCE Remote died today….

September 3, 2005

…. but luckily there was a solution….

it’s been a little erratic over the last couple of days… sometimes not lighting up on the first press of a button and so I suspected the batteries, but a quick checked showed they where still at 80%+ (I love these batteries with the new-fangled touch meter on the side… it’s a little thing but a great example or technology actually being helpful !)

but today when I went to watch a DVD nothing…. no lights, no activity, nada 😦

luckily you can reset the remote by taking out the batteries and leaving it a while. These guys recommend 30 mins, but about a minute pressing all the buttons did the trick for me.

Who’d have thunk it… even the Microsoft remotes need rebooting every now and then 🙂

How long since Windows last fell over ?

September 2, 2005

Thanks to the folks at Uptime Project it’s a question I’ll never wonder about the answer to again…..

UPTIME: offbeatmammal - http://www.uptime-project.net
My Vaio
UPTIME: offbeatmammal-MCE - http://www.uptime-project.net
My MCE machine

it’s only a shame that you can’t create multiple machines under once account (would make it easier to manage a profile) but I guess if I wanted to track the laptop, the MediaCentre and the office machine together I could set up three accounts and put them together in their own league.
Shame they don’t have an OSX client yet (they only have Windows and Linux options) – would help answer the question of which platform is most stable 😉

Of course, the real shame is that WinXP and OSX even after all these years of tweaking and architecting still require reboots after patching/upgrading and (even worse) installing/uninstalling programs. I can’t remember the last time I rebooted for the fun of it, but a couple of times in a day because of an installation and a WindowsUpdate session is just frustrating.

Bluetooth integration for a Sony Ericsson phone !

August 9, 2005

I have complained in the past about poor implementation of Bluetooth utilities under Windows when compared to OSX.
Well, BluePhoneElite may well be the creme da la creme on OSX but on Windows it now has a serious competitor in the form of FMA (floAT’s Mobile Agent) – a true example of how well Bluetooth can be implemented under Windows XP.

It features all the things that seem obvious, yet missing from the SE packages – ability to look up a contact and send them an SMS, archive old messages, perform actions based on proximity, manage your contacts and folders, provide information about battery status, signal strength and even the temperature of the phone, and… the best bit… it includes a very sophisticated sync capability with Outlook.

Sure, it’s not perfect yet, but then again… many apps take a while to evolve. What FMA has that sets it apart from anything else I’ve seen for integrating my SE T610 with WinXP is the expandability – scripts, an API and a powerful underlying engine.

If every SE phone came with this on the installation CD their competitors would weep. At least, those smart enough to realise that these days a phone isn’t just a fashion accessory !

Emerald isn’t here yet, and people are worried about Diamond !

August 2, 2005

I don’t get it. People are worrying about the next release of MCE – Diamond – when Emerald is what matters right now…

why ?

Because no matter what jam is promised tomorrow it’s the bread and butter we have today which will generate WAF and help people consider an MCE solution (very much a niche like the MS Tablet PC platform) over a set-top-box and PVR combo.

At the moment I can do out and get a dual-tuner STB/PVR solution and plug it into a Plasma/LCD and 5.1 (or better) speakers and have an "instant-on", 100% reliable, easy to use solution (especially if I happed to live in a country with an EPG) that doesn’t hang for random reasons or suffer all the other idiosyncrasies that sadly part of anything as sophisticated as a WinXP based solution (I wonder how much code there is in a typical MCE install that’s totally redundant)

If Emerald can’t tidy up the user experience for MCE (or at least go a long way to making it stable, slicker and smarter) then Diamond (no matter what bells’n’whistles and/or limitations it ‘offers’ in its new hardware hogging form) is going to have a much harder sell.

Here in Aus the problem certainly isn’t all at the feet of Microsoft – a lack of an EPG coupled with the very cavalier attitude towards actually adhering to schedules is enough to alienate a lot of users – driving them into the arms of BitTorrent to actually get the shows they want to see, when they want to see them….