We’ve updated our Terms of Use to reflect our new entity name and address. You can review the changes here.
We’ve updated our Terms of Use. You can review the changes here.

random waves i

from passing time by sevenism

/

about

from midiutil import MIDIFile
import random

# Create a MIDI file with one track
midi = MIDIFile(numTracks=1)

# Define track parameters
track = 0
time = 0
tempo = 80
midi.addTrackName(track, time, "Experimental Ambient")
midi.addTempo(track, time, tempo)

# Define note parameters
channel = 0
volume = 64

# Define random function
def get_random_note():
return random.randint(48, 84)

# Add notes to the track
duration = 2
for i in range(32):
pitch = get_random_note()
midi.addProgramChange(track, channel, time, 81) # set instrument to "Square Lead"
midi.addNote(track, channel, pitch, time, duration, volume)
time += duration
duration = random.choice([1, 2, 4, 8])
pitch = get_random_note()
midi.addProgramChange(track, channel, time, 88) # set instrument to "Pad 5 (bowed)"
midi.addNote(track, channel, pitch, time, duration, volume)
time += duration
duration = random.choice([1, 2, 4, 8])

# Save the MIDI file
filename = "experimental_ambient.mid"
with open(filename, "wb") as output_file:
midi.writeFile(output_file)

credits

from passing time, released March 30, 2023

license

tags

about

sevenism UK

ambient/acoustic/experimental

contact me for licensing / mastering / collaborations

thanks for the support guys.. havent got much money at the mo so it goes a long way; but feel free to download if you don't want to pay!

please do comment on the album if you do buy something

also if you want to donate directly and avoid fees you can here paypal.me/sevenism
cheers!
... more

contact / help

Contact sevenism

Streaming and
Download help

Shipping and returns

Report this track or account

sevenism recommends:

If you like sevenism, you may also like: