Google Answers Logo
View Question
 
Q: raw code vs linux ( No Answer,   3 Comments )
Question  
Subject: raw code vs linux
Category: Computers > Operating Systems
Asked by: myq-ga
List Price: $10.00
Posted: 20 Jul 2004 12:25 PDT
Expires: 19 Aug 2004 12:25 PDT
Question ID: 376769
have been told that a simple system (say for emailing input text to
a single preset address) without linux (using a microcontroller chip
with raw code) would be much less costly to make (in terms of cost of
components ...not software) than a system which was powerful enough to
have linux running on it. Maybe by a factor of 5. However, it seems to
me that linux (in some distributions)  is small enough not to really
require a scalng of processor power and other components etc.
Would you agree that considerable scaling up (i terms of cost and
power of components)would be required just so that one can run linux?
there are two cases that I am interested in, I guess: 1) when a
(small) graphical LCD is being used and (2) when a (small) text based
lcd is being used.
Answer  
There is no answer at this time.

Comments  
Subject: Re: raw code vs linux
From: booser-ga on 22 Jul 2004 18:02 PDT
 
For something like e-mailing data, an embedded processor probably
would be cheaper in term of components.  Embedded processors are
extremely cheap.  It might cost only a dollar for something like a PIC
chip (www.microchip.com) that can be literally programmed hundred of
times (use EEPROM).

They can pretty easily be interfaced with other devices like keypads
or LCD displays.  You are only limited to the number of I/O pins.  If
you are trying to connect it to a 32 bit ethernet card, forget it. 
You probably don't have enough pins to do it.  Controlling an LCD, let
it be character or graphical, it doesn't take a whole lot of
processing power.  Their is not that much to do.  Drawing a Sine wave
across a graphic display might take some time, considering you find a
way around the low number of bits of the microprocessor (many of them
are 8 bits).

By default, running Linux requires a faster processor.  Text LCDs
require exact timing and microprocessors are generally faster then
they are.  So the extra processing power would be wasted on text LCD. 
On a graphical LCD, a faster processor means you can do more
calculations and thus, draw more on the screen, quicker.

The biggest drawback to these small computers is the speed.  One
dollar chips many only run at a few megahartz and is limited by the
frequency of the oscillator attached to it.  Generally, the slower the
oscillator, the less power the chip will consume.

The problem with Linux is it is a memory and processor hog.  On an
embedded processor, you might only have a few hundred kilobytes of
memory.  On Linux, that entire memory would be consumed by the kernel
alone.  We haven't started to even execute the applications on it. 
Thus, just to run Linux, you would have to invest several dollars in
SRAM (static RAM) alone.  The program in the Micropressor maybe only
30k and written in Assembly or a specialized version of C.  Also,
Microprocessors can boot and start executing code almost immediately,
whereas Linux would have to initialize all its programs and memory,
load itself, than start executing.  Linux, although very efficient,
would have to worry about multitasking processes.  This takes cpu
cycles.  You would need a faster computer.  Microprocessors might only
have to execute one program.

Microprocessors are better for specified, simple tasks, where huge
processing power is not required.  Linux is better for more complex
tasks where more processing power and memory is required and the
project needs to be more generalized.  Think of a microwave.  You are
not going to attach an ethernet card and a VGA display to it, so why
does it need an entire operating system to cook your meal and display
"Enjoy your food!!!"
Subject: Re: raw code vs linux
From: myq-ga on 23 Jul 2004 08:44 PDT
 
Thanks, booser-ga ,  for an absolutely excellent comment (answer,
really. too bad you are not a researcher)
I can't help for certain extra clarifications, though.
Can something like a z80 clone run linux/graphical LCDs without problem?
If not, what is the minimum chip level (maybe a couple of chip numbers
and maybe ballpark cost) which would be able to run a really small
distribution of linux(but one which is still capable of basic net
connectivity) And to handle a graphical LCD?
You mention that the linux kernel itself may need a few hundred KB of
memory. How much more --order of magnitude-- to run something like
very basic emailing?
Typically, what would a very small distribution of linux require on,
say, flashmemory
Subject: Re: raw code vs linux
From: psychojamin-ga on 28 Jul 2004 11:56 PDT
 
There is a compromise.  Check this:
http://developer.axis.com/products/mcm/index.html

This is an embedded linux chip, you can definitly run a simple e-mail
program on this, and it's quite cheap. I saw a price around $29 at a
first look.

Important Disclaimer: Answers and comments provided on Google Answers are general information, and are not intended to substitute for informed professional medical, psychiatric, psychological, tax, legal, investment, accounting, or other professional advice. Google does not endorse, and expressly disclaims liability for any product, manufacturer, distributor, service or service provider mentioned or any opinion expressed in answers or comments. Please read carefully the Google Answers Terms of Service.

If you feel that you have found inappropriate content, please let us know by emailing us at answers-support@google.com with the question ID listed above. Thank you.
Search Google Answers for
Google Answers  


Google Home - Answers FAQ - Terms of Service - Privacy Policy