BC3WINCL fresh installation for Windows and CLISP-2.42, version February 15, 2008

  1. You have downloaded (or will download) "BC3WINCL" software distribution of February 15, 2008, from http://www.acoustics.hut.fi/software/BlockCompiler/BC3WINCL150208.zip to Windows (XP tested) and then expand it. Move the whole directory to your favorite directory path, for example to ‘Program Files’. 
  2. In order to export BC patches to Matlab/Octave .m-files and run the code examples, copy the directory “bc_functions” to a proper place (default in file "BC-SETTINGS.lisp" is "C:/Program Files/MATLAB") with Matlab path set to access it, see BC3WINCL testing (1).
  3. As you probably want to use C compilation and real-time operation of BC models (in addition to only creating models for exporting to Matlab/Octave or Pd), then you need to install MinGW (Minimalist GNU for Windows) or Cygwin in order to have access to a GCC compiler. Here we guide you to install MinGW: Click the ‘MinGW-5.1.3’ (or later) installer icon (included in "Support/MinGW-setup") when you are connected to Internet, and follow the instructions to make a base tools installation. If problems appear in downloading from the default site, try others. It is assumed that you install MinGW to "C:\MinGW". If you decide to install in another destination, then you should set the path to the variable *MinGWgcc* in "BC3WINCL" file "BC-SETTINGS.lisp"
  4. Clicking the icon "clisp" inside the directory ‘clisp-2.42’ inside ‘BC3WINCL’ starts the CLISP (only the Lisp). In the opened Lisp listener window, write: (load “BC-COMPILE.lisp”) and Carriage Return (CR). This should compile the BlockCompiler software. There should be no errors; don’t care about possible warnings. 
  5. Exit CLISP by writing (exit) and CR or just by closing the window. 
  6. Start the CLISP again and write: (load “BC-LOAD.lisp”) and CR. This should load the BC3 software without errors and make it ready for use. (If you don't want sound-I/O for realtime sound, or if you don't have such sound support, then open file "BC-SETTINGS.lisp" and comment out make-audio by replacing the row by ;;; (bc::make-audio).) After loading, BC3 is ready for operation, but you may quit now and:
  7. Make a shortcut icon on desktop for starting BC by a mouse-click. First make a shortcut of CLISP, open it by Right-click, and append the following text to the end of Target field (after the application path that exist there already):  -q -i “BC-load.lisp”. Finally, you may name the icon for example as ‘BC3’. For preparing EMAC editor for interacting with BC, see instructions below.
  8. In order to write and evaluate Lisp code for BC, the Lisp package :BC should be used. Normally this means that a source file should start by line (in-package :BC). It is recommended to write code using an editor (e.g., EMACS), although it is possible to execute simple forms in the Lisp listener. In the listener, executing form (in-package :BC) makes the Listener to use BlockCompiler package so that the BC-forms are directly accessible. Another way is to stay in the default package and use the package prefix bc:: for all BC-symbols, such as (bc::.add) to create an adder block.

BC3WINCL directory management and software update

  1. If you reinstall or update the BC3WINCL software or parts of it, the most important thing is not to overwrite your user files or user settings.
  2. The top-level BC3WINCL directory is modularized so that CLISP is an independent directory that must include also the files “BC-COMPILE.lisp” and “BC-LOAD.lisp”. If you replace CLISP directory for example by a newer CLISP version, please copy these two files from directory “Support” to CLISP directory before compilation and loading. You may need to recompile BC3 if you chance CLISP version.
  3. Subdirectory BC3 inside top-directory BC3WINCL includes the source files of BC3 an compiled files after compilation, as well as two .dll-files for C and audio support.
  4. Directory “Support” includes documentation and installation instructions (this file), original versions of compiling and loading files, MATLAB interfacing support, and MinGW support.
  5. Demos are in directories "MDEMOS" (for MATLAB) and "RTDEMOS" (realtime demos).
  6. File BC-SETTINGS.lisp includes user-specific settings that are loaded after the BC3 kernel files have been loaded.
  7. You may place your own BC3 files as you wish to manage them from Lisp, but the easiest way is to make a directory inside the top-level BC3WINCL directory for them. Be careful not to delete them when you update BC3 or parts of it.

BC3WINCL testing

  1. Start BC3 after installation, execute (in-package :BC) and (load “mdemos/dsp/sinosc”) in the Lisp listener. This should create a sinewave oscillator (as the value of symbol sinosc) as well as export the model as an m-file to Matlab (or Octave) to directory ‘C:/Program Files/MATLAB’. (This path is defined in file ‘BC-SETTINGS.lisp’ and you may specify it according to your directory configuration.) If you have Matlab (Octave) and you set a path to the directory mentioned, then you can simply evaluate bc_resp in Matlab (Octave) to see how the sine oscillator makes a graphical presentation of the waveform.
  2. To test a realtime patch and audio-I/O, go to the sine-wave synthesis case in file "rtdemos/dsp/sine-tone" as documented in the Report.pdf "Discrete-Time Physics-Based Modeling – A Block-Based Multi-Paradigm Approach with Applications to Audio and Acoustics", in chapter "Introduction to BlockCompiler". (Now it is easier to operate with EMAC and SLIME, but you may also execute the commands in the Lisp listener after switching to package :BC, which is not that convenient.)
  3. It is recommendable to check all the examples in chapter "Introduction to BlockCompiler" to get familiar with BC3 modeling.
  4. NOTICE: This is a quite unfinished version of BC3, and it has known and unknown bugs. Feedback of your experience and comments is welcome.

EMACS/SLIME/CLISP environment

To be codumented here ...


Back to BlockCompiler home page