Interfacing PDA to USB

T

Theo van der Merwe

Guest
How do I interface common USB devices to a PDA? As I have recently
bought the entry level Palm Zire, I would at present be more
interested in the Palm PDA.

More specifically, I have the following questions:

1) How does the interfacing to a regular USB keyboard work? I would
like to use a full size USB keyboard with the Palm Zire. It is not
necessary to develop a driver for the PDA, a simple application in
which one can type text (which can then be copied later to e.g.
memopad) is sufficient for my purposes.

2) How does the interfacing to a USB memory stick work? I have a 128MB
Kingston data traveller which I would like to interface to the Palm
Zire. Again it is not necessary to develop a full driver to the Palm
Zire (although it would obviously be very convenient!). Rather, an
application which can store (and restore) the complete memory contents
of the Palm Zire on memory stick is required.
So I don't necessarily need to interpret the file structure of the USB
memory stick (again that would be useful, for example what file
structure is used on a memory stick?) - just a simple memory dump from
the Palm (currently limited to 2MB I think) to the USB memory stick is
required at present.

In summary I want to know how USB interfacing works in detail so I can
interface some common USB devices to a PDA (I am assuming that USB
drivers for the Palm to common USB devices is not available?). I don't
need to develop an USB driver at this stage (which might be very
difficult?). Would it be possible to interface more than one USB
device to a PDA? If so, what changes in programming is required?

Best regards,
Theo van der Merwe (ntvdmREMOVE@iafrica.com)
 
"Theo van der Merwe" <ntvdml@iafrica.com> wrote in message
news:25af4009.0403180717.5960d2d5@posting.google.com...
How do I interface common USB devices to a PDA? As I have recently
bought the entry level Palm Zire, I would at present be more
interested in the Palm PDA.''...etc.
So what you're asking for, basically, is for someone to
type in the entire USB specification?

Bob M.
 
"Bob Myers" <nospamplease@address.invalid> wrote in message news:<gym6c.1187$my3.548@news.cpqcorp.net>...
"Theo van der Merwe" <ntvdml@iafrica.com> wrote in message
news:25af4009.0403180717.5960d2d5@posting.google.com...
How do I interface common USB devices to a PDA? As I have recently
bought the entry level Palm Zire, I would at present be more
interested in the Palm PDA.''...etc.

So what you're asking for, basically, is for someone to
type in the entire USB specification?

Bob M.
No - if you can read my original message again you will notice that I
am only interested in a small subset of the USB specification at
present. More specifically, how does USB communication work when a key
is pressed on a USB keyboard? I would imagine that communication would
only be one way in this case. The same applies for the memory stick -
how would one communicate with the memory stick using USB?
 
"Theo van der Merwe" <ntvdml@iafrica.com> wrote in message
news:25af4009.0403182149.1db0309b@posting.google.com...
No - if you can read my original message again you will notice that I
am only interested in a small subset of the USB specification at
present. More specifically, how does USB communication work when a key
is pressed on a USB keyboard? I would imagine that communication would
only be one way in this case. The same applies for the memory stick -
how would one communicate with the memory stick using USB?
Just as I thought originally. You DO need the entire USB
specification.

In other words, it ain't as simple as you seem to think...

Bob M.
 
On 18 Mar 2004 21:49:31 -0800, ntvdml@iafrica.com (Theo van der Merwe)
wrote:

No - if you can read my original message again you will notice that I
am only interested in a small subset of the USB specification at
present. More specifically, how does USB communication work when a key
is pressed on a USB keyboard? I would imagine that communication would
only be one way in this case. The same applies for the memory stick -
how would one communicate with the memory stick using USB?
USB is a master/slave system - the computer is the master, and
anything else is a slave. Slaves only speak in reply to queries from
the master.

For input devices like keyboard and mouse, the master (PC) will
repeatedly poll the device, asking for changes since last time - if
someone has pressed a key, the keyboard will respond to a poll with
"the A key was pressed", and a few polls later "the A key was
released".


--
Peter Bennett, VE7CEI
peterbb (at) interchange.ubc.ca
new newsgroup users info : http://vancouver-webpages.com/nnq
GPS and NMEA info: http://vancouver-webpages.com/peter
Vancouver Power Squadron: http://vancouver.powersquadron.ca
 
"Bob Myers" <nospamplease@address.invalid> wrote in message news:<LNG6c.1275$Zv4.148@news.cpqcorp.net>...
"Theo van der Merwe" <ntvdml@iafrica.com> wrote in message
news:25af4009.0403182149.1db0309b@posting.google.com...
No - if you can read my original message again you will notice that I
am only interested in a small subset of the USB specification at
present. More specifically, how does USB communication work when a key
is pressed on a USB keyboard? I would imagine that communication would
only be one way in this case. The same applies for the memory stick -
how would one communicate with the memory stick using USB?

Just as I thought originally. You DO need the entire USB
specification.

Please enlighten me as to why you feel it is necessary to know the
complete USB specification to interface a device like a keyboard? By
pressing a key and monitoring the subsequent USB communications it
should be possible to determine the USB interfacing requirements?

In other words, it ain't as simple as you seem to think...
Maybe so, but is it really impossible to do?

 
Peter Bennett <peterbb@somewhere.invalid> wrote in message news:<90um50p6acacki0f6vgd33iu6fckt1vp6l@news.supernews.com>...
On 18 Mar 2004 21:49:31 -0800, ntvdml@iafrica.com (Theo van der Merwe)
wrote:

No - if you can read my original message again you will notice that I
am only interested in a small subset of the USB specification at
present. More specifically, how does USB communication work when a key
is pressed on a USB keyboard? I would imagine that communication would
only be one way in this case. The same applies for the memory stick -
how would one communicate with the memory stick using USB?

USB is a master/slave system - the computer is the master, and
anything else is a slave. Slaves only speak in reply to queries from
the master.
That seems a rather strange way of doing things! Can there only be one
master? What if you want to connect two computers together?
Is it perhaps possible to get a master PDA (or adapter) so that one
can control external devices?

For input devices like keyboard and mouse, the master (PC) will
repeatedly poll the device, asking for changes since last time - if
someone has pressed a key, the keyboard will respond to a poll with
"the A key was pressed", and a few polls later "the A key was
released".
Thanks for the feedback, this is exactly the procedure I suspected
(very similar to the interfacing on a regular PC with PS2 port if I am
not mistaken). Can you provide me with further details on the protocol
used to exchange this information?
 
On 19 Mar 2004 22:05:02 -0800, ntvdml@iafrica.com (Theo van der Merwe)
wrote:

Peter Bennett <peterbb@somewhere.invalid> wrote in message news:<90um50p6acacki0f6vgd33iu6fckt1vp6l@news.supernews.com>...
On 18 Mar 2004 21:49:31 -0800, ntvdml@iafrica.com (Theo van der Merwe)
wrote:

No - if you can read my original message again you will notice that I
am only interested in a small subset of the USB specification at
present. More specifically, how does USB communication work when a key
is pressed on a USB keyboard? I would imagine that communication would
only be one way in this case. The same applies for the memory stick -
how would one communicate with the memory stick using USB?

USB is a master/slave system - the computer is the master, and
anything else is a slave. Slaves only speak in reply to queries from
the master.


That seems a rather strange way of doing things! Can there only be one
master? What if you want to connect two computers together?
Is it perhaps possible to get a master PDA (or adapter) so that one
can control external devices?
I understand that cameras (and perhaps some other things) can act as
either master or slave as needed - if you want to download from camera
to computer, the camera will be a slave, but if you connect the camera
directly to a printer, it becomes a master (I'm somewhat guessing
here...)

For input devices like keyboard and mouse, the master (PC) will
repeatedly poll the device, asking for changes since last time - if
someone has pressed a key, the keyboard will respond to a poll with
"the A key was pressed", and a few polls later "the A key was
released".

Thanks for the feedback, this is exactly the procedure I suspected
(very similar to the interfacing on a regular PC with PS2 port if I am
not mistaken). Can you provide me with further details on the protocol
used to exchange this information?
Sorry - I don't know the gory details - I've just read bits about USB
on the web.

For the details, you'll probably have to look at the USB spec, or at
datasheets for some USB interface chips. From what I've read, USB is
not simple!


--
Peter Bennett, VE7CEI
peterbb (at) interchange.ubc.ca
new newsgroup users info : http://vancouver-webpages.com/nnq
GPS and NMEA info: http://vancouver-webpages.com/peter
Vancouver Power Squadron: http://vancouver.powersquadron.ca
 
Theo van der Merwe <ntvdml@iafrica.com> wrote:
"Bob Myers" <nospamplease@address.invalid> wrote in message news:<LNG6c.1275$Zv4.148@news.cpqcorp.net>...
"Theo van der Merwe" <ntvdml@iafrica.com> wrote in message
news:25af4009.0403182149.1db0309b@posting.google.com...
No - if you can read my original message again you will notice that I
am only interested in a small subset of the USB specification at
present. More specifically, how does USB communication work when a key
is pressed on a USB keyboard? I would imagine that communication would
only be one way in this case. The same applies for the memory stick -
how would one communicate with the memory stick using USB?

Just as I thought originally. You DO need the entire USB
specification.

Please enlighten me as to why you feel it is necessary to know the
complete USB specification to interface a device like a keyboard? By
pressing a key and monitoring the subsequent USB communications it
should be possible to determine the USB interfacing requirements?
No, you really do need to go and read the entire spec.
What you are asking requires knowledge of the bus electrical specs,
signalling system, how a peripheral is initialised, ...
USB stuff won't work if you just apply power.
You need to tell it it can now turn on, initialise registers, ......
In other words, it ain't as simple as you seem to think...
Maybe so, but is it really impossible to do?
No.
 
Ian Stirling wrote:
No, you really do need to go and read the entire spec.
What you are asking requires knowledge of the bus electrical specs,
signalling system, how a peripheral is initialised, ...
USB stuff won't work if you just apply power.
You need to tell it it can now turn on, initialise registers, ......

In other words, it ain't as simple as you seem to think...
Maybe so, but is it really impossible to do?

No.
Was there a URL posted for the PDA spec?



Richard
 
Richard Lamb <n6228l@earthlink.net> wrote:
Ian Stirling wrote:


No, you really do need to go and read the entire spec.
What you are asking requires knowledge of the bus electrical specs,
signalling system, how a peripheral is initialised, ...
USB stuff won't work if you just apply power.
You need to tell it it can now turn on, initialise registers, ......

In other words, it ain't as simple as you seem to think...
Maybe so, but is it really impossible to do?

No.

Did anybody post a URL for the specs?

They are on usb.org
 
Ian Stirling wrote:
Richard Lamb <n6228l@earthlink.net> wrote:
Ian Stirling wrote:


No, you really do need to go and read the entire spec.
What you are asking requires knowledge of the bus electrical specs,
signalling system, how a peripheral is initialised, ...
USB stuff won't work if you just apply power.
You need to tell it it can now turn on, initialise registers, ......

In other words, it ain't as simple as you seem to think...
Maybe so, but is it really impossible to do?

No.

Did anybody post a URL for the specs?

They are on usb.org
Thank you.

Wow. very interesting site...
 

Welcome to EDABoard.com

Sponsor

Back
Top