digego / extempore

A cyber-physical programming environment
1.41k stars 127 forks source link

Cannot run some of the example source code in the documentation with latest pre-built binary #347

Closed stefafafan closed 4 years ago

stefafafan commented 5 years ago

Hello, I am new to extempore.

I was checking out the docs, and it told me the binary release may be a good option to get me going, so I tried that out. https://extemporelang.github.io/docs/overview/install/

So I got the 0.7.0 from here which was released in April 2016. (I am running it on macOS Mojave 10.14.1) https://github.com/digego/extempore/releases

Now I see that I am good to go, I went on to the guide to try out instruments on this page. https://extemporelang.github.io/docs/guides/note-level-music/

However the code below does not work for 0.7.0 (the make-instrument macro does not work but if I change it with bind-instrument it works).

;; load the instruments file
(sys:load "libs/core/instruments.xtm")

;; define a synth using the provided component fmsynth
(make-instrument synth fmsynth)

;; add the instrument to the DSP output sink closure
(bind-func dsp:DSP
  (lambda (in time chan dat)
    (synth in time chan dat)))
(dsp:set! dsp)

;; play a note on our synth
(play-note (now) synth (random 60 80) 80 (* 1.0 *second*))

I checked out the other issues and the code and see that the make-instrument macro was added in 2017, so I guess the documentation is up to date but the recommended installation method is old (since the latest release is 2016).

My suggestion

I think most beginners will first try out with the binary && example code in the documents, but I understand it is probably hard to sync the version of the docs and the code--perhaps write somewhere in the docs that the sample code there works for the newest code and not necessarily for the newest release build?

Other than that, nice project 👍

benswift commented 5 years ago

Hi, thanks for raising the issue. A couple of points:

The good news is that I've got some time over the summer to sort this sort of thing out, so although I don't have a precise timeline for you I'll keep this open and close it when it's done. If you find any more specific issues then feel free to add them here.

stefafafan commented 5 years ago

Great! Thanks for the quick response :)

benswift commented 4 years ago

Ok, since the release story is now much nicer (and we really should try and keep the docs in sync) I'll close this one.