is a programming-language (program that builds programs) for creating advanced sounds from simple equations+MP3s and theoretically designed to build and evolve Strong Artificial-Intelligence and Artificial-Life, thats so easy that ANYBODY (including programs) can use it to build computer-programs. |
|
[skip to the 6 steps]
You might think you will never understand computers without a brain transplant, but ANYONE can build software (computer programs) in 6 easy steps! Or synthesize music in a few more steps, as any combination of: MP3s, equations, mouse, keyboard, microphone, electric guitar (plug into mic hole). Or in less than an hour, you can build your own games (unlimited modifications of existing C.S. games). Anyone can build simple unique software, and it will be on your screen in 2 minutes if you use the summary (1-6) below. Custom software to-go. Your total is $0.00 Please drive around to the second window... |
faster than Humans can build software... and when the WIKI of code is created, it will also build smarter-than-Simian software... GNU GPL 2+ licenses - FREE (as in free speech) to use, modify, and distribute. The executable file (CodeSimian.jar) is the same file as the source-code (rename it to source.zip) This first CodeSimian costs no money. GPL does not prevent selling, but its rules about keeping code secret usually make it impractical. |
Summary (1-6): Open CodeSimian.JAR.
Replace text with ask("some question?") and click compileCode. To make it unique, for example, ask(about anything else...) or if( ask("again") ask("ok asking again") )
It can
be as
simple or
complex
as you
want.
(1) Download CodeSimian.JAR   (What is a JAR file?) (2) Find and double-click CodeSimian.jar (skip this step if you click OPEN in step 1) (3) A window with title "selfReplicating..." appears. If not, install Java 1.5 and try step 2 again. (4) Click Erase_Text. (If you skip steps 4 and 5, it will instead build another "selfReplicating" window) (5) Type ask("any text here") into the "selfReplicating" window. ask("or for different buttons" try this instead) (6) Click compileCode (in the "selfReplicating" window) then what you built appears on your screen. CodeSimian is a member of (codesimian.sourceforge.net), the biggest collection of FREE OPEN-SOURCE software ever (159,332 softwares 10/2007), organized by many properties of the softwares. I plan to connect CodeSimian to many softwares, because an artificial-intelligence needs things to play with so it can learn. (7) Look at these examples() of CodeSimian code and what they build...
code is in file: puyo.cs Of course you can find out which button was clicked. The question is asked again every time you click YES. Click NO to end it... Or do more complicated things. Same as above except plays a.mp3 when it stops repeating... but dont worry, theres more easy examples below... They're not all in order of difficulty... Almost same as above except shorter...... This window (and the code() inside it) appears when you double-click the file CodeSimian.jar (or click OPEN). It contains all code needed to build a copy of itself. Click the compileCode button to use whatever code is in the window. Of course, you can modify the code before you click compileCode, and a modified window will appear. The files_inside_CodeSimian.jar window is built inside the above window. It appears when you click SAVE_and_LOAD_files... Click any filename in files_inside_CodeSimian.jar and that file is loaded into the selfReplicatingWindow where you can edit and/or use it. Click SAVE and CodeSimian will ask you where to save CodeSimian2.jar, the modified version of CodeSimian you just created... CodeSimian is a JAR file that creates unique JAR files with unique appearance and behaviors. You can build it into your own program. This short code creates a button that turns the whole CodeSimian off when you click it, including all open windows and playing sounds. To turn it off immediately, use this code: You dont need to know why this works to use it. Just copy it into any of your own programs... (8) You will see pictures of CodeSimian on this website, often near the code() used to build what is shown in the picture. Learn to use the code you find on this website (not just the short ask code above)... Repeat step 4. Copy (and paste into CodeSimian with keys ctrl+V) some of the more complicated code from this website into the window. Repeat step 6. Then something appears on your screen, plays sound, or whatever the new code tells it to do... To "copy" code, select it with the mouse, right-click it, and click copy. Or use ctrl+C. Paste is the opposite of copy. Copy to get, paste to put. ctrl+V means hold the ctrl key and push v, when the text cursor is in CodeSimian. In most programs, you can paste with ctrl+V. Play and modify some MP3s...sound(mp3("http://codesimian.com/a.mp3")) (plays a.mp3 at normal speed) sound(mp3("http://codesimian.com/a.mp3" *(-2.2 count))) (plays a.mp3 backwards at 2.2x speed) if(ask("play a certain mp3 on your hard-drive?") sound(mp3("C:\\music\\yourfile.mp3"))) (plays yourfile.mp3 only if you click YES) Plug your microphone or electric-guitar into the microphone hole:sound(microphone) (simplest microphone code, plays it on speakers at normal volume) sound(*(10 microphone)) (plays microphone on speakers at 10x volume) sound(sine(*(40 microphone))) (wraps 40x extra volume around a sine wave, adds oscillations to the sound) sound(+(mp3("http://codesimian.com/a.mp3") microphone)) (plays microphone and a.mp3 together) Try inserting mp3("http://codesimian.com/a.mp3") and/or microphone in random places in sound codes, and see how it sounds. I've designed CodeSimian to do interesting things even with random code.To stop the sound, run this code: sound(0) and if that doesnt work, read How to stop the sound.txt More example sounds or the sounds page
(9) Learn how ( and ) connect the parts of code together. In the code: x(y(w) z) , x contains y and z, and y contains w. if(      ask( "is your operating system Windows XP?" )      if(          ask( "open control-panel?" )          commandLine#zzz( "control panel" )      )      if(          ask( "then I dont know if it will work. Try anyways?" )          zzz      ) ) That code asks a question, and depending on your answer, executes one if() or the other if(). Each if() contains an other question, and if the answer is yes, opens control-panel. zzz is the name of that commandLine object. zzz is in 2 places at once. You can put any type of code together with almost any other type. Each piece of code must contain some number of other other pieces. For example, if() must contain 2 or 3 things, and ask() contains 1 or more. The list of commands tells how many things each command uses.
What can you build with CodeSimian? Many things, the best are sounds built as equations of time vs wave-amplitude, code that lets you play electric-guitar with the mouse, bayesian artificial intelligence, and a game thats like Tetris but color of the blocks matters more than shape. CodeSimian can be as simple or complex as you want.(11) After you learn by example, build your own software... You will need the list of commands. Build something awesome... |
class X{ public static void main(String args[]){
if( args[1].equals("showIt") ) System.out.println("Show this on the screen");
} }
Programming-languages are becoming closer
to spoken/written languages (like the one you're reading now) every few years.
Eventually they will merge, but before that,
there must be transition languages between technical and vague.
CodeSimian will become such a language...
|
shortest code |
4 lines of code that plays |
Sounds generated by equations (and sometimes by moving the mouse) |
? |
download the fractal sound that short code above playsThe most interesting parts of the first sound have low frequency and volume, so listen very closely if you have cheap computer speakers. The next 2 sounds have better frequency distribution, but I dont know if they have any fractal parts. |
? | Download sound 2   (right-click, save target as) |
? | Download sound 3 |
There are many more sounds, but currently they're not on this webpage. They're in equations in files ending with .cs (means Code Simian), which can be found inside CodeSimian.jar when you open it with WinZip. |
Even if you know NOTHING about computers, you can still build sounds like these.To start, Download CodeSimian and copy/paste any of the code you see on this website into CodeSimian.Or with a little more skill, you can build many other things. CodeSimian is a tool for building software. Usually CodeSimian builds software, uses it, then discards it. But you can save the software you or CodeSimian creates. Each sound is the output of a small software I typed into CodeSimian. The code for the first sound is the fractal sound above. |
The last 2 sounds were created using (an older version of) this code and the window it brings up:
x y m1 and m3 are controlled by the mousePanel object because they are in its paranthesis.
They are also other places, a graph shape of code.
For speed, I turned off the infinite-loop-protection on this equation, so it cant have CYCLES in the graph.
Wave amplitude, calculated 44100 (or 22050) times per second,
range -1.0 to 1.0, equals the do(...) in the sound(...)
CODE THAT SOUNDS LIKE ELECTRIC-GUITAR DISTORTION AS YOU MOVE THE MOUSE... BUT YOU MIGHT NEED TO ADJUST THE NUMBERS A LITTLE TO GET IT TO SOUND RIGHT ON YOUR SPECIFIC COMPUTER... BEWARE: THIS SOUND IS COMPLEX SO IT RUNS SLOW... do( window#play_electric_guitar_with_mouse( mousePanel(.5#x .5#y 0#m1 0#m2 0#m3) 300 200 ) sound#snd(do( =D(1#a +(1#d *(5 1#c d x))) =D(1#b +(b *(.01 y))) =D(c delay( sine(*(a 5)) 7) ) =D(d delay( sine(*(b 5)) 4) ) if(m1 =D(d delay( sine(*(d 5)) 8) ) 0) =D(c delay( sine(*(c d .5)) 9) ) =D(c +(c d *(b .037))) if(m3 =D(c +(c 2 delay(d 44))) 0) =D(1#e sine( delay( delay(c *(.003 d b x)) 7 ) ) ) sine(*(e delay(e 2) delay(e 63) )) )) )The inner do(...) returns the value of its last object, sine(...), which sound(...) plays. |
SOME VIRUSES ARE LEGAL |
Rapid Application Development (RAD) of the development environment itself |
do( list(bayesNode#node( list(slidebar#in0 slidebar#in1) list( slidebar#prob0(.3) slidebar#prob1(.22) slidebar#prob2 slidebar#prob3(.7) slidebar#prob4(.2) slidebar#prob5(.44) slidebar#prob6 slidebar#prob7 ) 0 )) window#moveTheSlidebarsThenClickTheRightButton( horizontal( in0 in1 button prob0 prob1 prob2 prob3 prob4 prob5 prob6 prob7 button#execute( setP(slidebar#out0 0 node) ) out0 ) 700 100 ) )