Sunday, November 28, 2010

Multimedia introduction

As a child, along with computers I was trying to develop some more “artistic” talents like playing music. I always wanted to learn playing the guitar and rock till the end. Along with guitar and bass, keyboards was really exciting too, and seemed to be easier playing. My parents bought me a small keyboard and I immediately started practicing using study guides and books. Later, they got me a teacher who was coming at my home and helped me develop some basic techniques through playing well-known classic songs.
It was amazing! I could make music! I could write my own music themes, and I could perform. Soon I realized that my computer could be a performer of music too. I thought that it would be a “perfect performer” playing music exactly as it is written on the music book. It could play the music I was “translating” in GW BASIC commands. It would follow my program flow and execute my commands, whatever my program was about, even playing music through that old and odd standard internal speaker. I should admit that listening to the music from my programs seemed perfect to my ears, even through that speaker.
It was then, when I learned that the music notes represent a different frequency, and there is an international code naming system using the first seven letters of the Latin alphabet.
The below table shows the correspondence of the common name, the Latin character, the frequency and the wavelength. (Source: http://www.phy.mtu.edu/~suits/notefreqs.html)
common name Note Frequency (Hz)Wavelength (cm)
doC016.352100.
reD018.351870.
miE020.601670.
faF021.831580.
solG024.501400.
laA027.501250.
siB030.871110.


I tried to remember (but I couldn’t) the command I was using to represent music in my programs. I just remembered that I was using the Latin characters and in some manner, using some numbers, I could declare the duration of each note. I finally googled it and I recalled the command was simply:
PLAY "edcdeee2dfedc4"
(example found at: http://en.wikipedia.org/wiki/GW-BASIC)
Later, I discovered that I could declare new sounds, out of the frequency ranges of the notes, using another command: SOUND. Following this idea, I discovered that this command was responsible for the sound of an explosion when playing the game with the gorillas, or, the sound of that primitive speech in some games, and any other sound effects. Next, I tried my first steps in the algorithmic art of music. Using loops, I created some cool sound effects similar to the simple sound effects of the games of that time.
It is a great experience to expand the possibilities of a tool. It is great to discover that there is one new distance in the tool you already use for some time now. So, I happily realized that the computer could not only output some characters on the screen, but it could also produce some audiovisual data!
It was then, when I realized that the games I was playing, have been written by programmers, not by magicians. I realized that I wanted to become one of them. Behind the graphics, the music, and the sound effects is hidden some pages of beautiful code (or ugly code :-)). Anyway, some lines of code could give some magic audiovisual moments to some people.
Later, I needed an upgrade of my computer and I bought a new 8-bit sound card, and real external speakers. I thought that my already written programs would be executed automatically now using the new equipment. And I was wrong.
Then I started to search and read my books about interacting with hardware. As I had no idea about the existence of the Internet to search for a solution, I had to find a good book. My parents let me order whatever book I needed from my already favorite bookstore, and then I first learned about the DMA (direct memory access) and IRQs (interrupt requests). When I studied some pages of code listings and found many hexadecimal numbers, I quited. I decided that first I could study some more mathematics, and some more computer hardware, and some more operating systems theory.
I was also advised to learn C programming language for better playing with the computer hardware programming. I was warned that it is a difficult programming language, but it is also the best. I knew that soon I would be studying C programming language step-by-step (Waite and Prata).

Saturday, November 20, 2010

First attempts

It was back in 1991 when my first computer arrived at home. At the age of 10, I was really excited and proud for my new hard-earned 80386 microprocessor, at 8/16(turbo) MHz, with 1 MB of RAM, 40 MB hard disk drive and full-color VGA screen!

I still had not a clue about what was the potential of this great tool, but I surely knew well that I could play some fancy games.

I remember my first technical books were about MS-DOS and GW-BASIC.

I remember my first contact with the operating system shell. I managed to find out how to change directory and go straight to the games folder (cd games). The first disappointment came out when I couldn’t figure out how to change directory stepping out of the current directory. Then I always had to restart the whole computer using the reset button, so, it reloads the operating system. Then I could start over from the root directory, changing directories diving one-way deeper in the directory structure… And then restart again. The end of this series of psychological test sessions ended when I discovered “cd ..”, “cd /”, absolute and relative paths.

I remember myself trying to copy my first programming example, from my first programming book. It was a good reference guide to GW-BASIC. One of its first example code listings was an if-statement, a decision flow example, that would read a number from keyboard and then check if this number is negative or not. Finally, it would print-out jubilantly an appropriately happy message: “This number is positive/negative”. I was reading the book and I was excited by the fact that I could put some logic into a machine. Then this machine would execute my logic and it would react in some manner. I couldn’t wait to type it and put it in some serious testing… but when I started typing, this strange machine replied that this was a “Bad command or file name”. I was not sure about the “file name”, but I knew that the “commands” I was typing were absolutely identical with the commands on the book. The mystery was unveiled when I got the enlightenment of the GW-BASIC compiler and editor existence.


I remember my first computer game. It was something open source software, written in QuickBasic. It's the well known Gorilla. An old time classic. Two gorillas (two king-kongs actually) on the roofs of skyscrappers in a big city, throwing explosive bananas to each other. As a turn based, two player game we could also play against the computer. To run this game, I had to execute QuickBasic editor-compiler, load the source code file named gorilla.bas and then compile and run it from there. Sometimes I tried to read parts of code, but it was really disappointing.

Wednesday, November 10, 2010

Ignition

Push the button, beep, OS is loading, input credentials, log in, point-click-type and miracles can happen.

There are beautiful tools we can use. There are new tools waiting to be created. We are here to make things happen because we love it.