Diiference B/n C and Assembly Language?

Can I use C in place of Assembly Language?

I want to learn how a Computer is Created ...help me?

Comments

  • Of course--Almost every high level language (HLL) translates to machine language. Alot of compiliers also support outputting the generated assembly language.

    So, to answer your question: Yes, you can use C or C++ instead of assembly language (In fact, simply by using C or C++ you are already doing this). Where assembly language is required (Which is very very minimal), C and C++ support inline assembly.

    If you want to learn more about the low level aspects of computers, I would recommend learning some assembly language. Mabey even get into some system-level programming and you will learn more then you ever wanted to.

    If you have never programmed before, then dont worry at all--stick with learning a high level language first (Like C or C++) to understand the basics of programming and the computer system in general (memory management, stack, heap, pointers, etc) and data structures (functors, linked lists, etc) before diving into assembly language.

    [hr][size=1][leftbr].:EvolutionEngine[rightbr][leftbr].:MicroOS Operating System[rightbr][leftbr][link=http://www.brokenthorn.com]Website :: OS Development Series[rightbr][/link][/size]
  • [b][u]Thanks for these kind Suggestions.[/u][/b]
    [italic]I have a little knowledge of C and C++ both but not at the System Programmings level, I do not know, How to Program using 'dos.h' file and many more[/italic]

    But I can write simple codes.....

    Can you Specify the Details about - How any code[Software] effects any Hardware component.

    Codes get saved into capacitors or some storing media.(How)
    In the form of Voltage or in the form of Current?

    [Its true that this Q: is not for this category of C/C++ beg. Sorry, But I want to clear my Doubts ]

  • : [b][u]Thanks for these kind Suggestions.[/u][/b]
    : [italic]I have a little knowledge of C and C++ both but not at the
    : System Programmings level, I do not know, How to Program using
    : 'dos.h' file and many more[/italic]

    How to program with dos.h has been obsolete knowledge for 13 years, so don't waste time on learning that, learn the Windows API.


    : Can you Specify the Details about - How any code[Software] effects
    : any Hardware component.

    This question is too vauge to answer...

    : Codes get saved into capacitors or some storing media.(How)
    : In the form of Voltage or in the form of Current?

    Wikipedia for RAM, flash or harddrive.
  • : I have a little knowledge of C and C++ both but not at the
    : System Programmings level,

    I am going to stop here and simply say that a little knowledge is not enough. System level programming is not a beginners task at all and almost always requires understanding of your systems architecture and assembly language.

    If you really want to understand it further, search Google for Art of Assembly (The DOS book) and start reading and practicing assembly language.

    You can also take a look at [link=http://www.brokenthorn.com/Resources/OSDev7.html]tutorial 7[/link] from my site to learn basic x86 system architecture.

    : I do not know, How to Program using
    : 'dos.h' file and many more

    dos.h is not at the system programming level.. With that its not standard C++.

    As Lundin said, dos.h is deprecated. Dos was an old 16bit real mode operating system. As such, you will need a 16 bit real mode compiler (I personally used Turbo C 2.1 before--Google it, its a free download. Its a great 16 bit compiler.)

    Open up dos.h and you will see a few routines for system time, software port io, interrupts (geninterrupt, int86) etc. It may be lower level, but it is not coinsidered system level software.

    We can answer any questions that you have if you don't know how to use it..

    : But I can write simple codes.....
    :
    : Can you Specify the Details about - How any code[Software] effects
    : any Hardware component.
    : Codes get saved into capacitors or some storing media.(How)
    : In the form of Voltage or in the form of Current?

    Both of these are covered in tutorial 9 and tutorial 17 at my site. Tutorial 9 describes direct hardware programming concepts, and tutorial 17 has a complete section covering how physical memory works and what it is.

    I decided not to post links here as it goes into advance topics that can be hard to understand without assembly language, system architecture, or system level programming exp. In other words, they might confuse you more.

    If you are still interested, feel free to check them out.

    ----------

    What is it that you are wanting to do? Learn DOS programming or learn system-level programming?

    In either case, as you are still a beginner, I highly recommend against both of these (at least for now).

    [hr][size=1][leftbr].:EvolutionEngine[rightbr][leftbr].:MicroOS Operating System[rightbr][leftbr][link=http://www.brokenthorn.com]Website :: OS Development Series[rightbr][/link][/size]
  • Have in mind that what MT2002 speaks of is PC / desktop-computer programming. There is a bunch of other areas in embedded programming, there are few electronic devices around us today that don't contain microprocessors. The average household has at least 50 computers, all of them were programmed by someone. So don't narrow your mind to "programming == PC".

    A PC is also incredible complex if you go down on system level. The x86 processor is really quite an abomination carrying 30 years of history on its shoulders. And then all the crap surrounding it... multiple cores, various levels of cache memories etc etc. Although the average desktop-programmer doesn't really need to know how all of this work, they tend to dismiss hardware as a necessary evil.
  • Thanks to both of you.....thanks by heart!

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories