next up previous contents
Next: 6.1 Getting into the Up: PAPCO User Guide Previous: 5.7 Caveat on system

   
6. Including your own modules

The main thing to keep in mind if you are trying to add your own module is, DON'T PANIC. The task may look daunting but the actual work involved is minimal, although the first time you try it it might take some time. We have attempted to lead you through the process by means of a series of templates, which allow you to check your process at every stage. These templates are included here in the Appendix B for your reference: They contain all the documentation you would need to use them. That's why they're so ``big''; they actually contain very little code.

To use this step-by-step guide successfully, follow all the steps and read all the information included in the template files themselves. The step-by-step guide tells you what you need to do, and the information in the templates tell you how to do it. Test your modules at every step of the way, as described: in this way it's easier to track down any problems.

The templates have been written in such a way that all you need to do is to copy them and do a global rename - and there is even a utility that does that for you. If you have stuck to the naming convention then you should be able to test out the default behavior straight away. You should make sure that the PaPCo interface part of the routines works fine before you actually start programming your own plots or slices.

The module template supplied with PaPCo is actually a fully functioning module, the module ``plot_type''. This is a working module using a sample data file for Jan 11, 1997. This data file is not part of the PaPCo distribution, as the plot_type module supports the remote data get facility. If you don't have wGet installed, you can get the file manually via ftp. Check the plot_type modules config for the location of the file. Try it out, it supports all the basic PaPCo functionality. Using this module as a model it should be fairly easy for you to get a module of your own up and running quickly. The plot_type module can be found under papco_XX/papco_modules/plot_type.

Remember: DON'T PANIC. (Take your towel along.)

(That last statement is lost on you if you haven't read Douglas Adams' ``The Hitchhikers Guide to the Universe'').

The guide included here is a step-by-step guide for the adding of one new plot_type which has one data_product to plot. The best way to learn how PaPCo works is to go through this thoroughly once, which involves a fair amount of reading. But then the second module you add is a piece of cake.

I'm assuming that you already have an IDL read-routine (as described in 5.6) to put your data into common blocks, and that you know what type of plot you want to produce, and what range of input parameters your plot routine requires. Then follow the procedure described in the next sections, IN THAT ORDER.

NB: Make sure that all your filenames only user lower case letters. This makes portability a lot easier, as not all operating systems differentiate between lower and upper case letters.
This restriction does not apply to the actual IDL procedure/function names used.
Also, DO NOT use any special characters in your filenames AND your data file names, such as a period, dollar or percent sign, etc as this produces big problems with portability. Long filenames are O.K. - unless you plan to run on older WINDOWS versions (pre Win95).



 
next up previous contents
Next: 6.1 Getting into the Up: PAPCO User Guide Previous: 5.7 Caveat on system
Reiner Friedel
1999-02-03