ВУЗ:
Составители:
Рубрика:
39
contain the address at which a specific type of information is stored. However, the
pointer can be set to literally any address value, and by «casting» a programmer can
trick the compiler into storing any type of information at the arbitrary pointer address.
This is convenient if you write error-free code, and a snake pit if you don't. Java does
not have pointers.
Equally important, Java has built-in support for multiprogramming. С and its
immediately descendent C++, were designed to express a single thread of computing
activity.
There was no inherent support for multiple program threads executing
simultaneous ly (on multiple CPUs), or in parallel (timesharing a single CPU). Any
such fac ilit ies had to be supplied by an external multitasking operating system. There
are several good programs of this type readily available, such as MTOS-UX from
Industrial Programming. However, the services provided are all vender-specific.
Neither ANSI nor any of the various committees set up to hammer out a universal set
of OS services ever produced a single, universally-accepted standard. There are in
fact, several proposed standards, so there is no standard.
Java bypasses the problem by building multithreading and the data
synchronization it requires directly into the source program. You still need an OS to
make this happen, but, the semantic meaning of the OS actions is standardized at the
source level.
A standard at last
Java has all of the technical requisites to become the standard programming
language for programs to be distributed over the net. And with a well-supported
campaign spearheaded by Sun Microsystems, Java is becoming the de facto working
standard. Will Java supersede С as the language of choice for new programs in
general? With network programming likely to play an increasingly larger part in the
overall programming field, I think so.
Java for embedded systems
Embedded or real-time systems include all those in which timing constrains
imposed by the world outside of the computer play a critical role in the design and
implementation of the system. Common areas for embedded systems are machine and
process control, medical instruments, telephony, and data acquisition.
A primary source of input for embedded systems are random, short-lived,
external signals. When such signals arrive, the processor must interrupt whatever else
it is doing to capture the data, or it will be lost. Thus, an embedded program is most
often organized as a set of individual, but cooperating threads of execution. Some
threads capture new data, some analyze the new data and integrate it with past inputs,
some generate the outgoing signals and displays that are the products of the system.
Currently, most embedded programs are coded in C, with critical parts possibly in
assembler.
Putting the issue of execution efficiency aside, some of the major problems of С
for embedded systems are:
Страницы
- « первая
- ‹ предыдущая
- …
- 38
- 39
- 40
- 41
- 42
- …
- следующая ›
- последняя »