GettingStarted.txt -- How to set up a new project

* Create a directory for your project and make the following 
subdirectories:

	AppCon: (Application Configuration)
	Contains the configuration files for both the supervisor
	and each dsp. The files have conventional names, usually
	configSup.c, cnfgDSP1.c cnfgDSP2.c; the compressed names
	are for the 8 character limit imposed by the primitive
	TI cross compiler tools.

	Also contains the generic.dat, generic.c, and generic.h
	files. By placing a copy of the application generic.exe
	in this directory, the generic.c & .h files can be produced
	by simply running the program.

	The C40 Linker commands file C40Link.txt also goes here.
	It describes the memory configuration for the DSPs.

	AppDsp:
	All the application-dependent source files for code that 
	runs on the DSP.
	This includes most of the signal processing and control classes.
	The configuration module is cnfigDsp.c

	AppSup
	All the application-dependent source files for code that
	that runs on the supervisor DLL.
	The configuration module is cnfigSup.c

	CoopsCom:
	All the COOPS kernel source files shared by both the supervisor
	DLL and the DSP image.

	CoopsDsp:
	All the COOPS kernel source files used by the DSP alone.

	CoopsSup:
	All the COOPS kernel classes used by the supervisor DLL alone.

	LibDebug:
	Object modules and gark for the DemoProject.

	LibDsp:
	Object modules for the DSP code image.

	LibSup:
	Object modules for the supervisor DLL.

	HydraSupport:
	Source files for the Ariel Hydra downloader.

	NTDriver:
	Sources for the NT/VME driver.
	This driver is used to map the VME bus to an NT application's
	virtual address space.

	Documents:
	Notes and help files.

* Don't get rid of "c:\temp\" directory--- the Microsoft Developer's Studio
assumes this directory exists.

* Make sure the top level project directory contains a copy of "Makefile". This
file contains the nmake program to build the DSP image for your application.

* Make sure the top level directory contains the file "define.bat". This file
defines symbols for the DSP cross compiler tools.

* To create a new Microsoft C++ Developer Studio project, run
the application from the Program Manager Icon:

* Under the File menu, create a new workspace for a console application.
Give it the name of your project. In this example, we will call it
"DemoProject". The application created will be for debugging
your DLL locally without Alltalk or other remote application.

* Using the Build menu Settings dialog for DemoProject select the debug and
release configurations. Change the following dialog settings:

	General; Intermediate Files:
			LibDebug
	General; Output Files:
			./
	C/C++;	 Category: Preprocessor; Preprocessor definitions:
			Add WIN32_LEAN_AND_MEAN,
			plus whatever your application requires.
	C/C++;	 Category: Preprocessor; Additional include directories:
			CoopsCom, CoopsSup
	C/C++;	 Category: General; Warning level:
			2

* Insert files into project: (Make sure you pick DemoProject in combo box.)
	CoopsSup\DebugWindow.c
	CoopsSup\winExcept.c
	CoopsCom\strnew.c

* Now use the Build/Subprojects dialog to create a new DLL
subproject.  Select type "Dynamic-Link Library" in the dialog and enter
the name of your DLL.  For this example, we will use the name "DLLProject".

* Using the Build menu Settings dialog for DLLProject select both the debug
and release configurations. Change the following dialog settings:

	General; Intermediate files:
			LibSup
	General; Output files:
			./
	Debug; Category: General; Executable for debug session:
			c:\Alltalk\Alltalk.exe 
	C/C++; Category: Preprocessor; Preprocessor definitions:
			Add WIN32_LEAN_AND_MEAN,
			plus whatever your application requires.
	C/C++; Category: Preprocessor; Additional include directories:
			CoopsCom, CoopsSup, AppCon, AppSup, NTDriver, HydraSupport
	C/C++;	 Category: General; Warning level:
			2

* Insert Files into project: (Make sure you pick DLLProject in combo box.)
	AppCon\generic.c plus other project-specific configuration files
	AppSup\*.c
	CoopsCom\*.c
	CoopsSup\*.c
	HydraSupport\*.c
	NTDriver\*.c

* Select the DemoProject - Win32 Debug from the main window
combo box and rebuild all.

After building DLLProject.dll and DemoProject.exe you will have
some required rubbish files in your top level project directory. They all
begin with "DemoProject" or "DLLProject" and have mysterious extensions.
They cannot be hidden in subdirectories without less desireable compromises. 
The only file you need to restart the Microsoft Developer Studio is 
DemoProject.mdp When you double-click this file in the File Damager, the
development environment will restart with the last saved configuration.
A directory called DLLProject will also be created automatically. It can
be deleted. 

* Building the DSP Image:
Edit the "Makefile" to add or remove your application files. The
macro definition for "dspobjs" is a list of the application object
modules. This is the only part of the make file you will normally
need to edit.

You will be shocked to note that the object modules don't have individual
dependencies on their .h files. This is a compromise to simplfy the
make procedures. COOPS doesn't really have much protection for parameter
passing anyway and the huge and tedious make files required to account
for the dependencies don't seem worthwhile to me.

* Run the "MS-DOS" program to get a command line window. (You DON'T
have to install DOS, just use the NT Command window.) From the top
level directory of your project, type the command "define" to run
a batch file that defines symbols for the cross compiler tools.

* Now use the command "nmake" to create your dsp image. The tons of
useless glark that scroll by in the command window cannot be prevented, 
but the make process will stop if a compiler or link error occurs.

* Debugging

When you are developing your code, you can debug in one of two
ways: from Alltalk or from a local test program. To debug locally
select "DemoProject - Win32 Debug" from the main window combo
box. When you run your program, the DebugWindow.c module will load
and initialize the supervisor DLL. For this kind of debugging you
will need to edit configSup.c to add your test cases.

To debug using Alltalk, select "DLLProject - Win32 Debug" from the
main window combo box.  When you run your program, the Alltalk
listener window will appear. You can now restore a saved image
or compile your application interface. When the application opens
the "MailBox" driver in the RemotePort, your DLL will be loaded 
and initialized. You can now debug from the Alltalk listener window.
