Showing posts with label sonic pi. Show all posts
Showing posts with label sonic pi. Show all posts

Sunday, 20 March 2016

Dark in Sonic Pi



I am not a musician but I do love playing/coding (not difference really) Sonic Pi and video (using Voila http://www.globaldelight.com/voila/index.php) so I came up with this, it was just fun to do. 

Please someone take it and improve it.

use_synth :prophet
in_thread do
  loop do
    sample  :ambi_choir, rate: 0.1, attack: 4, release: 4
    sleep 10
  end
end
in_thread do
  loop do
    sample :bass_trance_c, amp: 0.75, release: 3
    sleep 2
    sample :bass_trance_c, rate: 0.5, amp: 0.5, release: 5
    sleep 4
    sample :bass_trance_c, rate: 0.3, amp: 0.25, release: 9
    sleep 10
  end
end
sleep 4
sample :ambi_drone, amp: 0.75, release: 3
sleep 8
sample :ambi_dark_woosh, amp: 0.75, release: 3
sleep 7
sample :ambi_dark_woosh, amp: 3, release: 6
sleep 6
sample :ambi_dark_woosh, amp: 3, release: 5
sleep 5
sample :ambi_dark_woosh, amp: 5, release: 4
sleep 4
sample :ambi_dark_woosh, amp: 5, release: 3
sleep 3
sample :ambi_dark_woosh, amp: 5, release: 2
sleep 2
sample :ambi_dark_woosh, amp: 5, release: 1
sleep 1
sample :ambi_dark_woosh, amp: 5, release: 0.5
sleep 0.5
sample :ambi_dark_woosh, amp: 5, release: 0.5



Creative Commons License
Dark by Scott Turner is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.


All opinions in this blog are the Author's and should not in any way be seen as reflecting the views of any organisation the Author has any association with.

Wednesday, 30 December 2015

playing with Sonic Pi

If you haven't played with it SonicPi (http://sonic-pi.net/) is well worth a go, it combines programming, computational thinking and  music (or trying to create music in my case). Raspbian on the Raspberry Pi has it as standard, but  is great that SonicPi is available on the Mac and PC as well. 






Here is an simple (if I am honest, because of a lack of musical ability) piece I have been play with. You can end up playing for hours trying out different sounds, synths, effects etc.

in_thread do
  loop do
    sample  :ambi_choir, rate: 0.1, attack: 4, release: 4
    sleep 10
  end
end
2. times do
  sample :bass_trance_c, amp: 0.75, release: 3
  sleep 2
  sample :bass_trance_c, rate: 0.5, amp: 0.5, release: 5
  sleep 4
  sample :bass_trance_c, rate: 0.3, amp: 0.25, release: 9
  sleep 10
end

Here is the sneaky bit, even in the code above there a mixture of threads, loops, sequences as well designing of the 'shape' of the sounds. 

There is also a community producing material/examples. For example at https://gist.github.com/rbnpi/7713ac59ed553d3f336e you can find code for the Star Wars theme. It is very hard to resist playing with the theme and adding drums, etc.

There are some great tutorials available on The MagPi magazine site https://www.raspberrypi.org/magpi/issues/

All views are those of the author and should not be seen as the views of any organisation the author is associated with.

Answers not on the Screen

  2.  The answers not on the screen Hill, G. ,  Turner, S. J.  and  Childs, K.  (2017)  Abstract:  Reflection from two areas on the issues...