Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Begining QNX programmer question

100 views
Skip to first unread message

Darius

unread,
Jul 28, 2004, 3:52:27 PM7/28/04
to
Hello,

Now I'm studying QNX programming and have several questions. First of all, I
think I understood IPC comunications, but I have lost when I read about
resource managers. They use IPC for communicating with clients, but how they
do that? They use open(), read(), close() functions, but not functions to
send messages such as MsgSend() or MsgReceive. What type of IPC
communications use resource managers?
And there is second question. What's the difference between device driver
and resource manager. Is it the same things?
Thank you for answers.

Best regards,

Darius


David Gibbs

unread,
Jul 28, 2004, 6:52:26 PM7/28/04
to
Darius <alpha...@safe-mail.net> wrote:
> Hello,

> Now I'm studying QNX programming and have several questions. First of all, I
> think I understood IPC comunications, but I have lost when I read about
> resource managers. They use IPC for communicating with clients, but how they
> do that? They use open(), read(), close() functions, but not functions to
> send messages such as MsgSend() or MsgReceive. What type of IPC
> communications use resource managers?

Ok... QNX is a microkernel. Most things that would traditionally be a
kernel call (e.g. open(), read(), etc) get turned into a message under
QNX. That is, if you call read(), that becomes: setup header, then
call MsgSend().

> And there is second question. What's the difference between device driver
> and resource manager. Is it the same things?

A device driver is something that abstracts access to a piece of hardware.
Usually under QNX this will be a process doing it -- but in some places is
a library or shared object.

A resource manager is a process that handles the messages generated by the
POSIX i/o functions -- that is by the functions like open(), read(), write(),
stat(), etc. Being a resource manager defines the interface between the
client and the server.

Very often a resource manager is used to provide a POSIX interface to a
device driver. But, a resource manager need not be a driver -- e.g.
/dev/null (null device), or mqueue (message queues); and a driver need
not be a resource manager.

Hope this clarifies a bit,
-David
--
QNX Training Services
http://www.qnx.com/services/training/
Please followup in this newsgroup if you have further questions.

Robert Krten

unread,
Jul 28, 2004, 9:52:17 PM7/28/04
to
Darius <alpha...@safe-mail.net> wrote:
> Hello,

You can also take a look at my book, "Getting Started with QNX Neutrino 2"
I believe it will answer most of your questions.

http://www.parse.com/products/books/book_v3/index.html

Cheers,
-RK

--
[If replying via email, you'll need to click on the URL that's emailed to you
afterwards to forward the email to me -- spam filters and all that]
Robert Krten, PDP minicomputer collector http://www.parse.com/~pdp8/

Dr. Khl

unread,
Jul 30, 2004, 6:43:42 AM7/30/04
to
Robert Krten wrote:

> Darius <alpha...@safe-mail.net> wrote:
> > Hello,
>
> > Now I'm studying QNX programming and have several questions. First
> > of all, I think I understood IPC comunications, but I have lost
> > when I read about resource managers. They use IPC for communicating
> > with clients, but how they do that? They use open(), read(),
> > close() functions, but not functions to send messages such as
> > MsgSend() or MsgReceive. What type of IPC communications use
> > resource managers? And there is second question. What's the
> > difference between device driver and resource manager. Is it the
> > same things? Thank you for answers.
>
> You can also take a look at my book, "Getting Started with QNX
> Neutrino 2" I believe it will answer most of your questions.
>
> http://www.parse.com/products/books/book_v3/index.html
>
> Cheers,
> -RK

Ah, a very good book with a very good chapter on resource managers.
Read that whole section through and try the example before you write
your first one. The difference between doing things the 'QNX way'
and not is the difference between easy and reliable and not.
The QNX Cookbook (same author) has some very good working examples.

Doug

0 new messages