Using the Siren Utility Pane and Transports

Support classes SirenUtility and SirenSession

There are two classes with utility and session management methods: SirenUtility and SirenSession.

SirenUtility is never instantiated, but has class methods for a number of usefiul utility functions related to system configuration (global verbosity flag and search directories). There are special functions for file search (see the section below on this page) and for handling s7 files (see below as well). The SirenUtility class initialization method sets the global logging verbosity level and creates a couple of lists of directories for searching for sound or score files. Users will typically customize this method so that Siren can find their data files.

SirenSession holds onto the user's persistent data (e.g., sounds and scores) in class-side dictionaries. This means that, by default, every sound or score that you give a name to becomes persistent and is stored in your Smalltalk virtual image. There are special functions for loading these caches from your hard disk, or for flushing them.

Links to the EventScheduler

The SirenSession also registers itself as a dependent of the EventScheduler, so it handles event logging and transport functions.

SirenUtility Panel

There are two main GUIs for Siren configuration: the Utility and the Transport.

The Siren utility panel has buttons for configuring and testing MIDI, sound, and OSC I/O, as well as for setting some global values such as the logging verbosity. There are also buttons in this panel for loading and flushing the session data.

To open the Siren utility view, use the button in the Launcher, or execute
[SirenSession openUtility] d

The left-most buttons in the pane asre for setting up and testing the MIDI and OSC I/O defaults. The 2nd row is for sound I/O cnofiguration.

SirenTransport Panel

The other SirenSession class GUI is the transport panel; to open this, hold down while pressing the Siren utility button in the launcher, or execute,
[SirenSession openTransport] d

The transport has menu buttons along the left for accessing your data (sounds, scores, and voices) and for controlling the EventScheduler. Below are some useful utility messages.

"SirenSession release"
"SirenSession instanceCount"
"SirenSession allInstances do: [ :ss | ss release]"
"EventScheduler instanceCount"
"EventScheduler instance"

SirenUtility file tricks

The folliowing examples demonstrate the SirenUtility class support for sound/score data. As mentioned above, users can customize the search directories by editing the SirenUtility class initialize method.

Find a file with the given name in any of the user's sound/score folders

[SirenUtility findFile: 'stp.ev'] p

Find a directory

[SirenUtility findDir: 'Data' tryHard: false] p
[SirenUtility findDir: 'Frameworks' tryHard: true] p

List all files with the given extension

[SirenUtility findFiles: 'au'] p
[SirenUtility findFiles: 'mid'] p

Create a new s7 folder and ask for the next free of a specific type name in it

[SirenUtility createS7: ((SirenUtility findDir: 'Data/'), 'testing')] d
[SirenUtility nextName: 'testing' type: 'aiff' ] p

SirenSession Storage
SirenSession eventLists
SirenSession sounds

Recreate the instance
SirenSession refresh
SirenSession release
SirenSession instance