Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
01/12/01 14:35
Read: times


 
#8149 - RE: does anyone know the reason
Here is what I think on this subject:
At a given moment the productivity of the digital technology overcame greatly human capacity to understand what goes on. That is why the programmers began to work in teams that became their normal way of life: a big task was divided into several small pieces and each piece was treated separately. Very soon it was noticed that the most awful bugs occur at the connections between different parts. That is why the protection of each separate part became so valuable. This approach was taught in the universities and finally became a common superstition: for example, the very notion of class in C++ is its logical development.
I do not want to say that this technique is useless or stupid : when the task is really big it is natural. But for big tasks they use big processors and in this case the main limit is our capacity of understanding because a table PC can do any imaginable and unimaginable task. I myself, when I write a code for PC, I use all the protection of C++ (classes and their private members, const functions, etc).
But that is not the case for the embedded systems. The protection technique is expensive from the point of view of material: a local variable takes an additional byte if not more. Its creating takes additional time and code length. And for most tasks we still can have a general vision of the application.
That is why I see nothing bad in using global variables in the 8051 applications. In fact, for about 20 years I use only global variables and never had problems. I can say more: I prefer writing in assembler for 8051 applications, and to attribute the addresses manually, because it gives programmer a total control of the material.
But in general the opposite approach is dominant: when I mentionned in the discussion forum of KEIL that I used only "void (void)" functions,the whole forum was shocked.
Michael.

List of 19 messages in thread
TopicAuthorDate
does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      
RE: does anyone know the reason            01/01/70 00:00      

Back to Subject List