The Function of software

A computer is one part electronic circuitry and mechanical components connected together. Software provides the digital instructions to these various components on how to operate and function together to complete a task or objective, and what the sequence and duration of the various functions shall be. Software is a program, which in turn is a series of instructions.

The microprocessor of the computer only responds to on / off electrical charges that represent simple instructions in binary notation code patterns. These “1” and “0’s” are known as machine code. Machine code adds up to address locations of data and simple operating instructions (add, subtract, etc.). Machine Language produces this code and is the first software level above the actual circuitry and processing hardware itself. Line after line of machine code are decoded by the microprocessor and its various sub-systems to further decode and execute instructions, access various memory locations for data and then manipulate the data to produce a desired end result.

However, rather than write code in binary machine language, the author of a program will use an alphanumeric language which is easier for humans to read in order to produce a source code that can be translated into machine code by either an interpreter application or a compiler application. At a basic level, these languages correspond with pre-determined binary patterns, and are designed for the particular construction of a specific microprocessor. Most recently, the higher languages are compatible with a CPU platform / architecture. Some languages are structured to either be Interpreted into machine language or Compiled into machine language (some programming languages can be both).

An Interpreter works with alphanumeric programming languages that are a level above machine language. This program works through a line of the programming language and the programming language is simultaneously interpreted / translated into object code or executable machine code and then is immediately executed (just the one line), by-passing the requirement that the entire programming language be converted to machine code prior to execution. The process is less efficient due to, as indicated, it usually is interpreted and executed at a line at a time and if it repeats a line then it must interpret that same line again. The Interpreter is beneficial for debugging a program as it will display exactly where a bug (especially syntax errors) is as the line will not execute and the program will cease running.

A Compiler can also translate alphanumeric programming language source code to machine language. The difference with and Interpreter is that the programming language is all translated to machine code (compiled) by the Compiler program prior to execution. Then all lines are executed sequentially rather than having an alternating line-by-line translation and execution similar to an Interpreter. A complied programming language source code is also alphanumeric and can be written in abstract ideas rather than specifying actual parts of the microprocessor. The compiled program language instruction file at this level is independent of the specific microprocessor. Rather, it is a universal instruction file understood by various different programmers. It is the Compiler Program (not the programming language) that needs to be specifically tailored to the individual microprocessor architecture. The end result of the Compiler program still tends to be slightly less efficient as the programming language itself needs to be generalized to be flexible enough to solve different types of programming objectives.

Assembly Language, one of the original low level programming languages, is an alphanumeric code that is converted into machine language/code by an Assembler program. There is normally an intervening step when the lines of code (the character strings), again known as the source code, are converted by the Assembler to an executable or object code (again, machine code). These languages side step the need for a compiler and are prevalent within the computer’s processors and card (circuit boards).

Most programs contain a Kernel, which is the main program. This main program is written to call up additional sub-programs, routines and sub-routines which expand the capabilities of the main program. For instance, in a digital audio application, the Kernel, sub-programs and routines are all loaded into RAM when the application is opened. If you wish to search your directory for a saved file, the kernel calls up the necessary programs to respond to the key strokes, search the directory, import a file in a certain format, open dialog boxes, adjust the graphic representation on the screen, communicate with the driver of the hard drive and soundcard, load the file, and then play the file.

Each programming language has its own unique syntax. However, there are two overall approaches in actually designing a program to obtain the best result possible: Structured Programming and Object Oriented Programming (OOP). The structured programming approach is that the program should be written in an exact, sequential order, which in turn will result in a clear, concise and accurate program. Object Oriented Programming encourages reuse of code within the program.

The original low-level programming languages consisted of short statements, quickly compiled to machine code and did not require much computer resources to run. Now, languages are ANSI-compliant (Amjerican National Standards Institute), which specifies a standard set of commands for a language recognized by the organization.

Writing a program is about creating a code that will receive and accept inputs, process the inputs and produce a desired output. The programming language is used to write unambiguous statements (YES / NO) that will process the data input as it moves through the program. The programming language is used to create that code, in many ways the two are synonomous. However, in approaching the actual coding one must first define what the output should or will be and what are the logical steps to process the data input to obtain that output.

An Editor (either a Line Editor or a Full Screen Editor) is an application used to type the lines of text of the programming language (code), edit the lines of code and save a copy of the program to the hard drive. A line editor accomplishes exactly as it is named: it allows one to either write or edit one specific line of code at a time. A full screen editor allows one to move the length of width of the code within the ediing area with the use of the cursor keys or by mousw click, and also includes drop-down menus for basic functions (open file, save, copy, paste, print). An editor can also have a compiler or interpreter application incoporated into it, thus one can immediately compile the source code then run the program and observe the output for any error.

A programming language contains some basic, fundmental common items (constructs): sequence (a series of instructions uninterrupted by a decision or looping), decision (two possible answers and resultant code sequence, exclusive of the other possible sequence, based on the either possible answer), branching (based on a decision or a GOTO) and looping (repetition of sequence code prefaced with a decision).

The higher languages that are popular with developers today are Visual Basic, C, C++, C#, Visual C++ (C and C++ compiler), Visual J++ and Java. These are languages used to write stand-alone program source code. This programming source code must be stepped down to machine language either by a one step compiler or in a two step interpreter.

Essential to writing programs is API (Application Program Interface). API are pre-written routines that can be used as reusable templates in writing a program to operate with a specific operating system or another application. Every operating system provides APIs to programmers: Unix (POSIX), Linux, MS Windows (Win32 and MFC) and Apple Mac (Classic, Carbon, Cocoa). An API saves the programmer time by allowing them to inset an API call into their application and precluding the need of having to rewrite the specific routine. APIs also provide a consistency to applications: this is why so many MS Windows-based applications have similar looking dialog boxes and drop-down menus. Similarly, DirectSound is a component of the DirectX API that allows audio related applications to work with many types of sound cards. The audio related application is written with DirectX API calls to the appropriate library file (.dll file) which are in turn compatible with the hardware, thus the programmer does not need to be familiar with the sound card, just with DirectX API (as the API either directly translates line commands into machine code or transmits data to the specific driver for the hardware). As the Creative Labs SoundBlaster sound card is so prevalent as the factory installed sound card by several computer manufacturers, there is also an EAX extension to the DirectSound API which allows programmers to write applications to take advantage of the attributes of that sound card.

Recent web authoring scripting languages that are embedded / included in HTML documents (and execute within the client-side browser) should not be confused as programming languages (although they can perform some sophisticated functions). These include DHTML (which combines CSS / Cascading Style Sheets and JavaScript), Java Applets (written in Java), JavaScript (which is an exception), VBScript (for executing Visual Basic ActiveX applications), XHTML (which combines HTML with XML syntax), XSL (XML style sheets), XSLT and SMIL. Server side scripting languages include CGI scripts (written in Perl, AppleScript, C++, Visual Basic), ASP (Active Server Pages), ColdFusion, Java servlets (written in Java), JSP (Java Server Pages), PHP and Perl, all of which can be used to query and/or update a database on the server.

Programming and scripting language development also continues to steadily move in the direction of enterprise computing, which is the server and client relationship that allows a desktop computer to run applications but access data and additional resources from a network. As the Internet is a network and has become exceedingly more important for business, presentation, information and communication, one focus of programming languages has become Web Services, which is the requirement to make applications and data operate seamlessly across desktops, local networks, mobile hardware and the internet. In addition, Web services coding should be less complex than C or C++ and should also have components that are reusable. Web programming languages / web application development tools for Web Services include PHP, SOAP, UDDI, WSDL (of which all three are cornerstones for integrating applications and share data across the internet), ASP.NET, ADO.NET, VC++.NET, VB.NET, PERL, Microsoft.NET (the Eiffel programming language is integrated in Microsoft.NET), IBM WebSphere Studio.

XML (Extensible Markup Language) is a scripting language that is used to describe the static content encased in HTML tags (or eliminate HTML and model data just with XML) and make the content available over networks for processing by any software application. XML can be used to model audio data. Unfortunately, various versions of XML are developing which affects its strength and purpose of being a unifying language. XML is being modified by various disciplines (scientific, economic, manufacturing, etc.). For instance, there are several XML-based business related standards being developed: BPML (Business Process Markup Language) developed by BEA Systems, CSC, SAP and Sun Microsystems which allows a company to model and define every function in its entire business process. Thus, any company that utilizes BPML now has data that is interchangeable with another company regardless if both companies are engaged in entirely different products and services. Similarly, there is BPEL (Business Process Execution Lanaguage) developed by BEA, IBM and Microsoft. BPEL is actually based on the combination of Microsoft’s XLANG (Extensible Language) and IBM’s WSFL (Web Services Flow Language), which had been recent and developing scripting languages, thus one can see how quickly the standard is changing. The whole idea behind XML-based language is similar to having an open standard: write an application once and have it run on any system operation.


Leave a Reply

Your email address will not be published. Required fields are marked *