Supporting Handheld Devices


Handheld devices such as the Palm and the Pocket PC are becoming increasingly popular. They allow their owners to have instant access to applications and stored data practically anywhere. By making your intranet available on handheld devices, you can make it possible for employees to work more productively, wherever they are.

Who Uses Handhelds?

Does your company have sales professionals who are frequently out of the office? Can they access product information, account details, service requests, and sales data while at a client site? Does your company have technicians or consultants who work on client sites? Can they access your organization's knowledge bases, bug databases, parts inventory, and technical information while with a client? Yes, it's possible to do this with a laptop rather than with a handheld, but there's a big difference between taking half a second to pull a handheld out of your pocket, and taking several minutes to take a laptop out of its case and boot it up. If the information isn't immediately available, then in many cases it might as well not be there. Having immediate access to information from your intranet could be very useful to these sales professionals. If these are useful to your employees then you have a strong case for including handheld support on the intranet.

In addition, many handheld owners use them to read newspapers or other news feeds using a system such as AvantGo (http://www.avantgo.com). As well as reading a newspaper, they could also be reading your organization's news, or keeping up to date with intranet discussion forums.

The examples so far have been about viewing intranet content on a handheld. It's equally useful to be able to synchronize your handheld's address book with your intranet address book so you always have access to phone numbers of your colleagues and your clients.

The good news is that it's neither particularly hard, nor expensive, to enable sections of your intranet to be read on a handheld device. However, it does take some setting up, both in terms of software on the handheld, and in terms of changes to the intranet in order to make it more usable on small-screen devices.

Note

According to a survey of handheld owners conducted by AvantGo, 68% of users believe that having access to their corporate portal or intranet via a PDA would improve their productivity, 47% think it would help them make better decisions, and 68% think that it's important or very important that they can access their intranet with their PDA. The intranet areas that they were most interested in accessing were personnel directories, training materials, and company news. There's more information at http://www.avantgo.com/news/press/press_archive/2002/release06_11_02.html.

If there are only a few people in your organization who require access to intranet information outside the office, then it might be more cost-effective to buy each of them a laptop, rather than to spend the development time making your intranet handheld-friendly. However, if many people need access to the intranet, then the lower price of handhelds in comparison to laptops might make them a more desirable solution. In any calculation of the ROI from laptops or handhelds, consider the time it takes to consult one, as well as the additional uses that could be made for either device.

A note on terminology

When I refer to "handhelds", I mean the generic class of handheld Personal Digital Assistants, such as the Palm, the Sony Viao, the MS Pocket PC, and the Compaq iPAQ. I'm not including mobile phones in this category, although devices like the Blackberry and the latest mobile phones have some overlap. I'm not referring specifically to the "Handheld PC" (HPC) that Microsoft produces, although it is included in the group when I'm referring to handhelds.

Note

When I refer to the "Palm", I'm referring to the Palm from Palm Inc., and the various handhelds that use Palm OS such as the Sony Viao and the Handspring Visor.

When I refer to the "Pocket PC", I mean the Microsoft Pocket PC and the Pocket PC 2002, and the various handhelds that use Windows CE such as the Compaq iPAQ and the HP Jornada. I'm not referring to the Tablet PC - in size, power, and cost, these more closely resemble a laptop than a handheld.

The Downsides of Handhelds

There are many downsides to accessing an intranet via a handheld. Some are starting to be overcome, while some are inherent in the size and portability of the device.

The problems of mobile devices include:

  • Screen size and resolution - resolution will improve over time, but screen size is unlikely to change (about 6cm by 6cm is standard)

  • Color support - only the more expensive models have any colors at all

  • Poor quality input devices - the stylus or keyboard on handhelds is not as good as a desktop keyboard, although they are still much better than a mobile phone keypad

  • Limited software support for popular document formats. This is becoming less of a problem, as both Palm and Pocket PC handhelds support PDF, and the MS Word and Excel formats

  • Dependence on batteries (especially a problem for the powerful but power-hungry Pocket PC handhelds)

  • Limited support for synchronizing with desktop computers that are not running Windows - both MacOS and Linux have some support for synchronization with handhelds, but it is not as complete nor as reliable as under Windows

And for interactive, online intranet access, the handheld is handicapped by:

  • Slow network transfer rate.

  • Poor network latency - there is a several-seconds delay establishing a WAP connection. With GPRS (General Packet Radio Service - a newer transport mechanism that is 'always on' and has higher data transfer rates), this is not so much of a problem. However, although GPRS has been around for a few years now, it hasn't yet achieved very great market penetration and whether it is available is dependent on the network service provider.

Because of these limitations, a handheld cannot be a replacement for a web browser on a desktop PC or a laptop. However, it has its own strong points:

  • Very portable.

  • Very fast to turn on

We will look at how to make reading the intranet useful on a handheld by leveraging these strengths and working around the weaknesses.

How to Access the Intranet

There are two different ways of accessing the intranet via a mobile device.

The first is to access the intranet interactively, by using the equivalent of a web browser on a mobile device. If using a mobile phone, this is the only generally available way of accessing an intranet at the moment. It is limited by the bandwidth available to the device, as well as the limited screen size and limited input possibilities.

The second is to access the intranet offline. This requires a device that has a reasonable storage capacity, and a reasonably powerful processor to render the stored content. At the moment, this means that it is limited to palmtop devices such as the Palm and the Pocket PC, and phone/palmtop crossover devices such as Blackberry.

In this section, we will look at accessing the intranet using palmtop computers, both online and offline. We will delay discussion of WAP on mobile phones until the next section.

Offline Viewing on a Palm

The major advantage of viewing the intranet offline is that you are not limited by the networking speed and connectivity. Except for very time-critical content, a synchronization every day or two is probably just as good at keeping the content up-to-date as an interactive connection. Choosing to view the intranet offline rather than online is a trade-off between the memory size required and speed - viewing the intranet offline is faster than doing it interactively, but requires more memory on the Palm.

There are a number of options for viewing an intranet offline on the Palm. These include:

  • AvantGo (http://www.avantgo.com/) - one of the standard pieces of software that comes with the Palm, and usable for Internet web sites via AvantGo Custom Channels. For intranets, you must purchase the AvantGo Server.

  • Plucker (http://www.plkr.org/) - free software described below.

  • iSilo (http://www.isilo.com/) - commercial software, worth the price for an individual user, but less useful for an intranet.

  • SiteScooper (http://www.sitescooper.org/) - free software, but more limited than Plucker (in particular, it doesn't have the sophisticated Palm client program that Plucker uses).

If your users are running a mix of Palm OS and Windows CE, then it may be worthwhile to buy a cross-platform commercial product such as AvantGo server. This may reduce your maintenance costs since you can use the same software on all of your users' handhelds. If you only have to support one handheld operating system, or if your budget is limited, then one of the free alternatives might be more suitable.

We'll look in depth at one specific piece of free software that allows you to access your intranet offline. This is Plucker. It consists of "Plucker Viewer" the Palm-based reader application, and "Plucker Distiller" that downloads, parses, and compresses the web pages into a database suitable for use by the viewer. There are versions of Plucker Distiller for Windows, Macintosh, and Linux computers.

Why Plucker?

Plucker is the most useful Palm application for reading an intranet offline for two reasons. First, it's free and open source (unlike most of its competitors), and second, you can use an application to do the bulk of the work on the server.

The way that most of the offline viewing applications work is to have the user's desktop computer downloading all the web pages that are to go onto the Palm, converting them to an appropriate Palm format, and then transferring them across to the Palm when it is next synchronized. There are two problems with this approach. Firstly, it can be slow, especially if there are a large number of documents to be downloaded, parsed, and converted. Secondly, if there are a large number of people doing this, then it can be a heavy load on the server.

The alternative approach that is made possible by Plucker is to have Plucker Distiller running on the server. This way around, there is only one process doing the downloading, parsing, and converting task, and the client machines simply use the resulting Palm database file.

Setting up Plucker on the Server

Plucker Distiller is the server-side half of Plucker. There are versions in the Python, Perl, and Java languages. Of these, the Python version is the best to use - the Perl version is older and lacks certain features, and the Java (actually Jython) version is new and hasn't yet been widely used. The Distiller is effectively a special-purpose web spider that downloads pages from a web site, following links to the depth that you specify, and stores the data in its own compressed form suitable for reading on the Palm.

There are full instructions on setup in the Plucker documentation (http://docs.plkr.org). To "pluck" an intranet, you need to create a file that defines which areas of your intranet should be plucked. By default this file is called home.html in your Plucker directory. It should look something like this:

 <html>   <head><title>Intranet home page</title></head>   <body>     <a href="http://intranet/news.html" maxdepth=3 stayonhost>Intranet news</a>     <a href="http://intranet/phone/" maxdepth=l stayonhost noimages>Phone list</a>   </body> </html> 

This specifies that Plucker should download the intranet news and the intranet phone list from the specified URLs, and convert them to its own format. Links in the "News" area should be downloaded to a depth of three links deep from the original news.html page, but not followed off the intranet server. There are a number of other options for the Distiller that are fully described in the Plucker documentation. The special attributes maxdepth stayonhost and noimages that appear above are not valid HTML, but only need to appear in the home.html file.

To invoke the Distiller, you need to call it with Python (the Python runtime is included with Plucker):

 python spider.py -f IntranetForPalm 

which will create a Palm database IntranetForPalm.pdb. On Windows you can set Plucker up to run regularly via the Task Scheduler, or on Unix you can use Cron.

Setting up Plucker on the Client

Plucker Viewer is a standard Palm OS application. The easiest way to make it available to your users is to put the Palm .PRC files on an intranet web page - users that have the Palm Desktop installed should be able to click on them to have them installed to their Palm on their next HotSync.

There are several options for transferring the Plucker database of your intranet to the Palm.

First, Plucker comes with a desktop application called "Plucker Desktop" that downloads and parses web pages on a schedule. The disadvantage of this is that it requires that the user sets up the channels to download themselves, and the downloading and parsing is done on the user's computer rather than on a central server. It may be appropriate if you have quite a small number of users, or if the users want to download other web sites apart from the intranet to be read on their Palm.

Secondly, you can generate the Plucker database on the server using the technique described. The simplest way of getting it from the server to the user's Palm is having the user click on the generated database on a web page (using a browser on their desktop computer) every time they want to update the content. This is inconvenient for the user, but if the intranet pages that need offline access are only rarely updated it may be an acceptable approach.

Alternatively, you can generate the database on the server, and then have a script running on the user's desktop computer that downloads the database locally (using software such as wget (http://www.gnu.org/software/wget/wget.html)) and then installs it using the Palm instapp executable. A DOS batch file to do this that could be put into the user's Startup folder would look something like this:

 @echo off wget http://intranet/palm/theintranet.pdb instapp theintranet.pdb 

It wouldn't be too hard to write a Palm conduit that would automatically download a pre-compiled Plucker database from a specified URL on the intranet every time the Palm was hot-synched. Unfortunately, such a thing doesn't yet exist, but it is being worked on, so keep an eye on the Plucker web page (http://www.plkr.org).

click to expand

Note

The Palm graphic displayed above is a screenshot of POSE, the PalmOS Emulator. It's available as a free download from Palm at http://www.palmos.com/dev/tools/emulator/. It is a complete emulator of Palm hardware, including memory constraints, and you can get a complete set of Palm ROMs so you can run any version of PalmOS on it.

When setting up your intranet to be used from a handheld, then it's very useful to be able to test it on a emulator - it allows developers without handhelds to do the testing, and it gives access to many more models of handheld than you're likely to have easy access to.

An additional use for the emulator is in producing documentation. Because the emulator runs under Windows, you can use the normal Alt-PrintScreen keyboard shortcut to make a screengrab of what it's showing. This is very useful when you need to provide instructions on setting up and using the software on the handheld.

Customized versions of POSE are also available from licensees of Palm OS, such as Sony and Handspring.

Viewing Other Intranet Information Offline on the Palm

Plucker is well-suited for viewing content-managed intranet pages, and for acting as an offline web browser; however, an offline web browser cannot take advantage of the server-side scripting that creates intranet applications. Some intranet applications would require custom programming to duplicate on a handheld, but it's possible to use off-the-shelf Palm applications to replace a lot of intranet functionality.

There isn't the space in this book to look at every Palm application that can be used for this purpose. One particularly useful one, though, is Pilot-DB (http://pilot-db.sourceforge.net/), a free and open source database program. This is very useful for storing data such as address books, contact lists, or product databases. Using Pilot-DB and its associated tools (http://sourceforge.net/projects/palm-db-tools/), you can convert CSV, Excel, or XML files from the intranet into Pilot-DB format, and make them accessible

Another alternative way of keeping contact lists is the standard Palm address book. The standard Palm software allows you to synchronize this with Outlook. Although this is useful for small address lists, it doesn't cope well with the thousands of addresses that would typically be held in the contact list of a medium-sized organization.

Viewing the Intranet Offline on a Pocket PC

The easiest way of viewing the intranet offline on a Pocket PC is to use "Mobile Favorites". This is an application that is installed on your desktop PC when you install ActiveSync. When you do so, a "Pocket PC" icon is added to the Internet Explorer toolbar on your desktop PC.

To use Mobile Favorites:

  • Connect your Pocket PC to the desktop PC with ActiveSync.

  • Browse to a web page in Internet Explorer on the desktop PC.

  • Select the "Pocket PC" icon on the IE toolbar.

  • Choose the name of the Mobile Favorite and how frequently it is updated.

  • Select Favorites > Organize Favorites from the IE menu and adjust the depth to download links to, the schedule, the passwords to use, and other details for that favorite.

  • On your Pocket PC, open Pocket Internet Explorer, and select the Favorites button on the taskbar at the bottom of the page.

This then allows you to view the pages that you have marked as Mobile Favorites on your Pocket PC. You can set a schedule on the desktop PC to update the pages regularly, and you can set the link depth to download pages that are linked to from the pages you select.

Unfortunately, there is no way that I know of to perform the parsing and downloading of web pages on the server, as you can with Plucker for the Palm. As a result, if you have many Pocket PC users, then each will have to set up their Mobile Favorites to download the intranet individually, which may lead to increased user-support problems, and an increased load on the intranet web server.

click to expand

Note

Just as with the Palm screenshot earlier in this chapter, the Pocket PC screenshot on the left was taken from an emulator. The Pocket PC emulator is a free download from Microsoft at http://www.microsoft.com/mobile/developer/downloads/ppcsdk2002.asp.

It requires that you also install Microsoft Embedded Visual Tools, which is another free download from http://msdn.microsoft.com/downloads/sample.asp?url=/msdn-files/027/001/963/msdncompositedoc.xml. Don't download this over a slow connection - it's over 300MB! You can order it from Microsoft on CD if this is too large a download for you.

This download includes Pocket PC, Palm-size PC, and Handheld PC Software Development Kits, as well as the emulators for each of these devices.

Viewing the Intranet Online with Palm and Pocket PC

Although browsing the intranet offline, as opposed to browsing the intranet online, has advantages in terms of speed, it may not always be suitable. Only the smallest intranets can be stored on a handheld in their entirety, and there are always likely to be situations when the right piece of content is not stored offline, in which case the intranet will have to be viewed online.

Some web browsers for the Palm are:

  • EudoraWeb (http://www.eudora.com/internetsuite/eudoraweb.html)

  • Palm Web Browser (http://www.palm.com/)

  • AvantGo Web Client (http://www.avantgo.com/)

  • Xiino (http://www.ilinx.co.jp/en/products/xiino/index.html)

Each of these has different levels of support for JavaScript, frames, images, and so on. If you are supporting Palm users, then it is best to evaluate a number of Palm web browsers to find the one that suits your needs best, and then standardize on that browser. This isn't to say that the intranet web pages you use should only work on one browser, but it makes web page maintenance significantly harder if you have to test every page in five or six different handheld browsers.

For the Pocket PC, the major option is Pocket Internet Explorer (PIE). There are a few other browsers available, but these are not nearly as widely used as PIE.

Designing for Handheld Viewing

Although handheld web browsers can display most web pages with no changes needed on the server, by making a few changes you can make the intranet a lot more usable for handheld users.

Creating Handheld Homepages

Pages written to be read on a handheld need to emphasize different things from normal intranet web pages. They should be much more concise, and have a minimum of "decoration" - like headers, footers, and navigation. The latter is easy to achieve by using a different template, but the former depends on the pages being rewritten manually.

It is impractical to produce two different sets of intranet content, one for handheld users and one for the Web. However, you can create "gateway pages" that act as homepages for handheld users, that are specifically written to be useful to handheld users.

Not all of the intranet is necessarily useful to view on a handheld, particularly offline. For example, intranet applications will depend either on server-side scripting, which is impossible offline, or on client-side JavaScript, which may not be supported on a handheld browser. Particularly large pages will be hard to read on a handheld, and may cause bandwidth problems. The handheld gateway page can provide links to only those parts of the intranet which are seen as useful for handheld access.

Personalization is more important for handheld browsers than it is for normal intranet users. As there is so little space on a handheld (both in terms of screen space and in memory), it is valuable to be able to remove unwanted content. If users are collecting the offline version of the intranet client-side (as with Mobile Favorites), rather than server-side (as with Plucker) then it's useful to allow your users to customize what appears on the handheld homepage. This allows them to change what they are downloading using a simple web-based interface, rather than having to learn a new software program interface. It also allows every client-side computer to be set up with the same offline browser settings, thus reducing maintenance costs, while still allowing users to store different information on their handheld. However, if the intranet is being spidered server-side, for example using Plucker, then the best you can do is provide several different spidered versions, and allow the user to choose which one they install.

Using a CMS to Serve Different Content to Handhelds

Just as a web site can serve different content to Netscape browsers and to Internet Explorer, it can serve different content to handheld browsers. One way to do this is by checking the User-Agent HTTP header in server-side script. Pocket Internet Explorer will always contain the string "Windows CE" in its user agent header. Other handheld browsers have a variety of different user agent strings.

Alternatively, you may be able to set your CMS up to use some sort of "virtual directory". For example, on the main intranet site you might access HR information by going to the URL http://intranet/hr/index.html. You may be able to set your CMS up such that clicking on the URL http://intranet/handheld/hr/index.html will open the same page, but served with a different template.

A template for handheld users should be as minimalist as possible. Items which do not provide an immediate benefit to the handheld user should be removed. This may include standard headers, footers and sidebars, the company logo, and most images. Form controls (such as a search textbox) take up space that could be used for content - and if the intranet is being read offline, then such forms are likely to be useless in any case. The intranet navigation is likely to need the most alteration; one option is to have a link to a separate site map on each page, rather than display the navigation on every page.

Note

There is a useful but incomplete web page listing some user-agent strings for mobile devices at http://www.zytrax.com/tech/web/browser_ids.htm, but you may need to work out what your user agent is by writing some server-side code (or by using the link on the URL just referenced).

Making Sections of the Intranet Easier to Read Offline

There are several techniques that can be used to make parts of the intranet easier to read offline.

Offline browsers are generally set to download links to a certain link depth - for example, only following links that are two deep from the originating page. This has implications for the way that you structure your articles. If an article spans multiple pages, then you need to provide an initial table of contents that links to each page, rather than having Previous and Next links on each page. If you don't do this, then the offline browser is required to fetch pages to a link depth equal to the number of pages in the article. Any CMS should be able to create such a table of contents automatically.

You can use the page URL to help the offline browser distinguish different sections. For example, if every part of the intranet sales information is beneath the URL http://intranet/sales/, then the offline browser can be told to follow only those links that begin with http://intranet/sales/. Likewise, if all the sales information is on the server "sales.intranet", then the browser can ignore those links which lead to other servers.

If you are using browser detection to serve different content to handheld user agents, as described above, then make sure that you're also checking for the user agent used by your offline browser.

Intranet Technologies that are Safe for Handhelds

Whichever handheld device you use, it is going to be less functional than the latest desktop browsers. Although different handhelds have different levels of support for web page technologies, there are a number of technologies that you need to be careful with. As always, you need to test the intranet on all the browsers that it is intended to be viewed with.

Frames

Frames are supported on Pocket Internet Explorer (PIE), but not on many Palm browsers (although Palm browsers will often provide a list of available frames so you can at least view them one at a time). In any case, the limited screen size makes them mostly useless unless you are very careful. They are best avoided.

Images

Handhelds will usually automatically scale images down and reduce their color depth, so the images can be seen, but you need to consider whether they'll be useful to handheld users. Only the most functional images should be used on a handheld - they not only take up valuable screen space, but they also take up the limited memory space of the handheld. alt text for images is not just useful for the partially sighted - it is very useful for handhelds as well.

HTML/WML

Most handheld web browsers are broadly HTML 3.2-compliant. Some will also support WML (the Wireless Markup Language) - but WML is more limited than HTML, and there's little reason to use it for handhelds that will support HTML. There's more detail on WML below, in the section on Supporting Mobile Phones.

JavaScript and DHTML

Several handheld browsers support a subset of JavaScript - but not necessarily the same subset. DHTML is supported only on the Pocket PC 2002, and not on early Pocket PCs or on the Palm. In any case, DHTML coders often make assumptions about screen size that may not be true of the Palm. Avoid JavaScript if you can - but if it cannot be avoided then test it thoroughly. If the intranet navigation is DHTML-based, then you will probably need to provide an alternative navigation for handheld browsers.

Flash

Flash is currently supported on the Pocket PC 2002 and on the Sony CLIE (running Palm OS). It's not yet widespread on handheld devices.

CSS

Very few handheld browsers have any support for CSS; Pocket Internet Explorer doesn't, and nor do the most widely used Palm web browsers. However, this is in no way a recommendation not to use CSS on your intranet - the handheld browsers that don't use CSS can just ignore the links to the CSS stylesheet.

Java

Java applets are unsupported on any handheld web browsers. However, Java 2 Micro Edition (J2ME) is a version of Java targeted at mobile devices (both handhelds and mobile phones), and might be usable as a replacement for any intranet applications that require Java. As long as Java isn't used as an essential part of the intranet, for example as intranet navigation, then this is unlikely to be a problem.

ActiveX

ActiveX is not supported on any Palm OS devices. It is partially supported on the PocketPC - ActiveX controls will not auto-install, but web pages can use ActiveX controls that are already present. In addition, some ActiveX controls may make assumptions about the environment in which they are running (for example, assuming that they have network access) that will not be true when they are running on a handheld. As with Java, this shouldn't be a problem unless ActiveX is being used as an essential part of the intranet.

Support for ActiveX is a clear advantage for the Pocket PC over other handhelds if your intranet has ActiveX-based applications, but you do need to check each one carefully to see if it will work on a handheld, and some ActiveX applications may need some amount of rewriting to make them work.

.NET

There are two options for .NET development for handhelds.

The first is to use the Microsoft Mobile Internet Toolkit (MIT) for ASP.NET development on the server-side. This simply uses ASP.NET controls to generate HTML or WML suitable for handheld devices, rather than for desktop PCs, without requiring any code changes for the developer. This is primarily targeted, as you would expect, at the MS Pocket PC handhelds, but there's no reason why it shouldn't work on many Palm web browsers too. There is more information on the MS MIT at http://msdn.microsoft.com/vstudio/device/mobilecontrols/.

The second is to use the .NET Compact Framework and the .NET Smart Device Extensions to produce code that can run on a handheld. This offers similar possibilities to running ActiveX controls on a handheld, but only works on Windows CE-based handhelds such as the Pocket PC. There is more information on this approach at http://msdn.microsoft.com/vstudio/device/compactfx.asp. The .NET Compact Framework is new, but could become an interesting option for handheld development over the next few years.

An overview of the two approaches, and their relative merits, is available at http://msdn.microsoft.com/library/en-us/dnppcgen/html/mobdevtools.asp.




Practical Intranet Development
Practical Intranet Development
ISBN: 190415123X
EAN: 2147483647
Year: 2006
Pages: 124

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net