Click here to Skip to main content
Click here to Skip to main content

Sharp YO Series Communication Class

, 23 Sep 2001
Rate this:
Please Sign up or sign in to vote.
Class for performing a backup/restore to a Sharp YO series organizer.

Disclaimer

This communication class is conducted by experimenting with a commercially available product by Sharp Electronics Corp. Sharp Electronics Corp. is in no way involved in this research and assumes no liability, express or implied. The software may contain bugs and may not work with any given organizer; I do not take responsibility. Use the information herein at your own risk. You've been warned.

Introduction

The SharpComm class has been written as a result of my research on the protocol used by the Sharp YO series organizers. The protocol for the backup and restore procedures has been hacked through using Portmon, an excellent tool from SysInternals; since Sharp has denied my request to obtain the official documents describing the protocol.

As of now, the class has been tested using my Sharp YO-190 organizer, with 256KB of RAM. It's not as fancy as the Palm Pilots, but it's cheap (as low as $30 from Best Buy) and it's exactly what I need. This probably works with other models, as well.

Features:

  • Memory: 256KB (254KB user area)
  • PC Link: cable & software included
  • Display: 19 x 5 characters dot matrix display with backlight
  • Weight: 9.5 oz (270 g)

This may not be a technical masterpiece, but is smarter than my old 11KB Canon organizer Smile | :)

Class description

Method Description
SharpComm() Initializes the COM port to COM1 and allocates memory for the communication buffer.
~SharpComm() Deallocates memory for the communication buffer and closes the COM port used.
void Initialize(void) Opens the selected COM port and sets the communication parameters (9600 baud, 8N1), then purges the queue. This method must be called before performing a backup or a restore operation.
bool IsInitialized() Returns true if the communication port has been successfully opened.
void SetComPort(int Port) Sets the desired COM port. The Port parameter must have one of the following values: COM1, COM2, COM3, COM4. To be effective, this method must be called before Initialize.
void SetFileName(char *szFileName) Establishes the name of the file used for backup and restore operations. To be effective, this method must be called before Initialize.
void DoBackup() Backups the contents of the organizer in the file specified by SetFileName.
void DoRestore() Restores the contents of the organizer from a file specified by SetFileName.
void Shutdown() Closes the selected communication port.

Usage

The SharpComm class is fairly easy to use, there is no special setup needed, just the requirement that your organizer be connected to the computer using the included cable.

// SharpComm class instance
SharpComm device;
try {
// Set port to COM1
device.SetComPort(COM1);
// Initialize communication
device.Initialize();
// Set file name
device.SetFileName("c:\\SharpYO190.bin");
printf("Waiting for organizer...\r\n");
// Perform backup or restore (device.DoRestore())
device.DoBackup();
}
catch(DeviceException *ex)
{
// Catch exception, something has happened
printf("ERROR: %s\r\n", ex->GetMessage());
delete ex;
}

Known Issues

  1. The backup and restore operations are not implemented using threads, so there's no elegant way to cancel the operation or to add a progress bar to a GUI. The class is very simple and I leave the chore of adding multithreading to whoever is interested.
  2. The checksum computation is a simple 16 bit addition, but the first and the last data blocks seem to follow a different rule. The implementation of GetCheckSum is done experimenting, so I am not sure if the results are stable.
  3. The sample utility provided is extremely simple therefore minimal error checking is performed. Don't blame me if your computer explodes or goes on strike Smile | :)

A word about Sharp's backup files (*.bke)

The backup files generated by the original program that comes with the organizer seem to be encrypted. I say "seem", because the encryption schema used is so weak that I could decrypt the files within minutes after I saw them. For those who are used to working with files at a low level, all you have to do is apply XOR FFh to each byte from offset 8 onwards. That's all. In addition, if you do that, the password of your organizer can be found at offset 112h. For those who don't understand a word of what I am saying, here is the English version Smile | :)

Don't store sensitive information in your organizer!!! Even protected by the password, your data and password can be easily revealed using the simple class presented in this article. Also, remember that even after a reset, the memory is not completely erased, just marked as erased. Take out the batteries for a few minutes to wipe out any trace of your data from the organizer. Most importantly, do not store the backup files where they can be easily reached by others.

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here

Share

About the Author

Valer BOCAN
Architect
Romania Romania
I am a software engineer based in Timișoara, Romania and currently hold the position of software architect for one of the largest companies in the world.
 
I invented a dialect of the Forth programming language and implemented the first Forth compiler for the .NET platform. I reverse-engineered the communication protocol of some GPS trackers and wrote from scratch a vehicle tracking system that is currently used to track my two cars. I hold a PhD in computer science and I am the author of several papers and a book chapter. In the 90s I wrote several computer viruses in assembly language for my own research and I was the first to devise a technique to deter heuristic virus scanners. In short, a humble man.

Comments and Discussions

 
QuestionY0-180 compatible to YO-190 ? Pinmemberyosharpy14-Aug-07 23:31 
Questionhelp to sharp el6890 Pinmembercholo749-Aug-07 4:29 
GeneralYo180 1. Will not turn on 2. Salvage Data to new Sharp Wizard OZ 590A Pinmemberidowebster21-Jun-06 7:01 
QuestionSharp YO-190 organizer Auto-Off disable? PinmemberMERLINMAGIX4-May-06 20:38 
GeneralYO-500 PinsussAnonymous2-Oct-05 11:16 
GeneralRe: YO-500 PinmemberValer BOCAN2-Oct-05 17:41 
Generalyo-180 restoring backup problem Pinmembermkshaji7-Jun-05 7:16 
Generalcan't get data Pinmemberwalliselkemercedes8-Oct-03 12:27 
GeneralWhere'd you find out... Pinmemberjdunlap9-Jun-03 17:26 
GeneralRe: Where'd you find out... Pinmemberjdunlap9-Jun-03 17:28 
GeneralRe: Where'd you find out... PinmemberValer BOCAN9-Jun-03 19:17 
GeneralRe: Where'd you find out... Pinmemberjdunlap9-Jun-03 20:31 
GeneralRe: Where'd you find out... Pinmemberjdunlap9-Jun-03 20:53 
Generalbke file refuses to download to Organiser ZQ485 Pinsussgeorgea17-May-03 12:39 
GeneralRe: bke file refuses to download to Organiser ZQ485 PinmemberValer BOCAN20-May-03 20:48 
GeneralIm looking for computer link cable for YO-380 PinsussAnonymous2-Apr-03 8:21 
GeneralRe: Im looking for computer link cable for YO-380 PinsussAnonymous11-Apr-03 0:02 
GeneralIm looking for cable diagram for SHARP YO-380 PinsussAntonio Noriega2-Apr-03 8:19 
GeneralFYI PinmemberAnonymous6-Feb-02 9:48 
GeneralRe: FYI PinmemberValer BOCAN6-Feb-02 17:00 
GeneralYo180 or ZQ180 Protocol PinmemberMarc Hanssens15-Nov-01 10:11 
GeneralRe: Yo180 or ZQ180 Protocol PinsussAnonymous13-Feb-03 21:29 
Generalneed to decrypt the .bke file Pinmembersunkist7-Nov-01 15:01 
GeneralRe: need to decrypt the .bke file PinmemberValer BOCAN7-Nov-01 21:10 
GeneralRe: need to decrypt the .bke file Pinmembersunkist8-Nov-01 15:14 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Mobile
Web03 | 2.8.140821.2 | Last Updated 24 Sep 2001
Article Copyright 2001 by Valer BOCAN
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid