Coder Social home page Coder Social logo

programs-make-waves's Introduction

Programs Make Waves

Description

This is a simple implementation of "turning code execution into audio". With a history back into the mid 20th century, programmers and operators historically would use these type of sounds coming from a computer to detect (via sound!) a program hang (i.e. a running program would have constantly changing sounds, but a hung program gets stuck on one tone indefinitely).

An example of a computer system doing this "code to tones" trick can be viewed here.

You can "cut to the chase" and hear what these 'Hello, World!' programs "sound like" via this YouTube playlist.

NOTE that make-waves.sh was developed under Ubuntu 20.04 x64, but should work on any system with syscall and a modern bash interpreter. I probably shouldn't have done this as a bash script, but, well, here we are... :)

This project currently contains 8 versions of "Hello, World!" to showcase the make-waves.sh script ability (but you can absolutely use make-waves.sh to create tones from YOUR progams, too!):

  • C
  • go
  • rust
  • java
  • python
  • ruby
  • perl
  • bash

You can use make to build the compiled versions, and make clean to remove compiled artifacts. NOTE that you'll need to have installed the required build tools and script interpreters to run each version of these.

You can create the associated WAVE file for a program (or several) easily:

./make_waves <program name> [<program name> ...]

Examples:

WAVE file for C's "Hello, World!" (results in hellow-c.wav):

./make-waves.sh ./hellow-c

WAVE file for go's "Hello, World!" (results in hellow-go.wav):

./make-waves.sh ./hellow-go

WAVE file for rust's "Hello, World!" (results in hellow-rust.wav):

./make-waves.sh ./hellow-rs

WAVE file for java's "Hello, World!" (results in hellow-java.wav):

./make-waves.sh ./hellow-java

WAVE file for python's "Hello, World!" (results in hellow.py.wav):

./make-waves.sh ./hellow.py

WAVE file for ruby's "Hello, World!" (results in hellow.rb.wav):

./make-waves.sh ./hellow.rb

WAVE file for perl's "Hello, World!" (results in hellow.pl.wav):

./make-waves.sh ./hellow.pl

WAVE file for bash's "Hello, World!" (results in hellow.sh.wav):

./make-waves.sh ./hellow.sh

You can use make waves to create ALL of the WAVE files (might take a minute), and you can use make clobber to remove compiled artifacts AND all WAVE files.

Potential improvements

  • make computation algorithms and WAVE file specifics more easily "tweakable" in make-waves.sh
  • base tones on actual instruction execution (although, using SYSCALLs makes this software eaiser for more folks to use)

programs-make-waves's People

Contributors

pbarry25 avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.