next up previous contents
Next: Limitations Up: Discussion Previous: Discussion

Frequently Asked Questions

  1. What is the difference between a device server and a device class ?

    A device server is a single process which instantiates and exports object(s) of one or more classes. Once the object(s) have been exported the process waits for requests on the network to execute commands.

    A device class is a software class which implements the generic behaviour and characteristics of a logical device. It is implemented in C using a method called Objects In C.

  2. Can device servers still be used to solve problems where fast timing is a critical issue ?

    This question demonstrates a misunderstanding of the work of a Device Server Programmer. Device Server Programmers are writing software classes which describe and implement device access. These classes can be used by other classes or in conventional procedure base software. A device server (i.e. the process which serves a or many devices) is simply a way of packaging these classes into a process which provides a procedural interface on the network. If network access is requested and if timing is a problem subclasses can be combined in superclasses in such a way that all critical timing takes place within a single class (i.e. locally in one process), thereby removing the network access part from the critical path. Alternatively the critical code can be implemented in an independent processes and device server can be used to provide network access.

    The DSM in no way prevents the programmer from using the operating system to its fullest - in theory it is possible to achieve the same response with a device server as with any other local process running under OS9 or Unix.

  3. What is the difference between a method and a command ?

    A method is a special function implemented in a class in the OIC programming methodology which can be inherited by subclasses of that class.

    A command is a special function in the DSM which can be executed across the network using the device server api call dev_putget(). All commands have a fixed calling syntax. Commands as opposed to methods cannot be inherited by subclasses. The only way to inherit a command to a subclass is to implement it as a method.

  4. Are device servers complicated to implement ?

    A device server is only as complex as the device it has to implement and serve. The advantage of the DSM is that all common functions related to network access are standardised. What might appear complicated to beginners is the object oriented aspect of class programming. The advantages of class programming (e.g. hierarchical structuring, generic solutions, re-using code) are sufficient however that it is worth investing the time in learning how to write classes.

    Device servers should not be used as an excuse not to write complex but maintainable software.

  5. Do device servers replace replace device drivers ?

    The answer is NO. In an ideal world both should exist. A device driver should be written to access the physical hardware by exploiting up to a maximum the I/O channels of the operating system. For example fast queued access with arbitration is offered by OS9 for drivers. A device server takes over from where the device driver leaves off. It offers higher level functions and network access. Although sometimes compared to a networked version of a device driver it is at a much higher level in terms of the way it presents information and the commands it offers.



next up previous contents
Next: Limitations Up: Discussion Previous: Discussion



Andy Goetz
Tue Jan 28 13:58:13 MET 1997