Skip to content

Commit 76ed928

Browse files
authored
Merge pull request #10 from MLonCode/readme_update
remove sonic-pi from readme
2 parents 67afa7a + e7768fb commit 76ed928

1 file changed

Lines changed: 13 additions & 31 deletions

File tree

README.md

Lines changed: 13 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,15 @@
11
# Sonic
22

3-
[Lookout](https://github.com/src-d/lookout) analyzer that uses [Sonic Pi](https://sonic-pi.net/) to generate sound from PRs.
3+
[Lookout](https://github.com/src-d/lookout) analyzer that generates sound from PRs.
44

55
The analyzer part uses [bblfsh](https://bblf.sh) to extract the UAST nodes from old and new code separating the nodes in deleted and added. It gets the type of node, token (name), size (characters) and hash (used for comparing).
66

7-
Sound generation uses a preconfigured Sonic Pi setup with a synth and listens to [OSC](https://en.wikipedia.org/wiki/Open_Sound_Control) for note and synth configuration data. Currently the data sent is:
7+
Sound generation is compatible with any midi synthesizer which exposes midi device. Currently the data sent is:
88

99
* Note
1010
* Duration (sustain time in seconds)
11-
* Cutoff (filter parameter for the synth)
12-
* Attack (how much it takes the note to reach volume peak)
13-
* Release (how much time it sounds after "releasing" the key)
1411

15-
Currently only Note and Duration are changed and the rest of parameters are always the same. Two note sequences are generated per file, one for deleted and another one for added:
12+
Two note sequences are generated per file, one for deleted and another one for added:
1613

1714
* file 1
1815
* deleted sequence
@@ -35,7 +32,7 @@ Duration is a direct conversion from the node size with a maximum of 250 millise
3532

3633
## Getting Started
3734

38-
Here's the information on how to configure Sonic Pi and the development environment. The project as is cannot be used to send data to github as the sound is played where Sonic Pi is running. Currently the OSC endpoint is hardcoded to `localhost`.
35+
Here's the information on how to configure midi synthesizer and the development environment. The project as is cannot be used to send data to github as the sound is played where synthesizer is running.
3936

4037
### Prerequisites
4138

@@ -47,33 +44,18 @@ docker run -d --name bblfshd --privileged -p 9432:9432 -v /var/lib/bblfshd:/var/
4744

4845
* [lookout sdk binary](https://github.com/src-d/lookout/releases)
4946

50-
* [Sonic Pi](https://sonic-pi.net/)
47+
* [portmidi](http://portmedia.sourceforge.net/portmidi/)
5148

49+
```
50+
apt-get install libportmidi-dev
51+
# or
52+
brew install portmidi
53+
```
5254

55+
* Midi synthesizer
5356

54-
### Configure Sonic Pi
55-
56-
After installing Sonic Pi check with some examples that works and it produces sound. If you are using Linux and it does not work try using jack 2 instead of jack 1 and changing its configuration.
57-
58-
We need to activate OSC input messages. To do so open preferences, go to IO tab and make sure that "Receive remote OSC messages" is checked.
59-
60-
The last step is setting the configuration script in the editor. Delete whatever is in it and paste this script:
61-
62-
```ruby
63-
live_loop :foo do
64-
use_real_time
65-
note, duration, cutoff, attack, release = sync "/osc/trigger/prophet"
66-
synth :prophet,
67-
note: note,
68-
cutoff: cutoff,
69-
sustain: duration,
70-
release: release,
71-
attack: attack,
72-
amp: 8
73-
end
74-
```
57+
- for macOS we recommend [SimpleSynth](http://notahat.com/simplesynth/)
7558

76-
Press `Run` button.
7759

7860
## Running it
7961

@@ -82,7 +64,7 @@ Press `Run` button.
8264
There's a sound test with hardcoded data that can be run with:
8365

8466
```
85-
go run cmd/osc/main.go
67+
go run cmd/test/main.go
8668
```
8769

8870
### Run analyzer

0 commit comments

Comments
 (0)