Lecture ATP

  • View
    82

  • Download
    7

Embed Size (px)

Transcript

U I

Installing ATP: Mingw version of ATP ATPDraw -- latest version or latest patch Presently Atpdraw55.zip

ECE 529 Lecture 4

Minimum to Download

PlotXY

Installation is less straightforward.

Intro to ATP

1

Spring 2009

U I

Installing ATPDraw

ECE 529 Lecture 4

Installation is fairly easy Default installation path Program Files The space in the file name can createproblems running ATP from ATPDraw Install it somewhere else. I normally install in C:\tools\prog\ATPDraw

Install program creates shortcut in thestart menu, but not very cleanlyIntro to ATP2

Spring 2009

U I

Running ATP from ATPDraw

ECE 529 Lecture 4

Still need a copy of ATP Licensed users can get other versions Follow installation directions for yours ATPDraw calls ATP from a DOS Batchfile (extension *.bat) Passes full path to file when calls ATP

Intro to ATP

3

Spring 2009

U I

Sample Batch File

ECE 529 Lecture 4

The following batch file is for Ming32 ATPSET GNUDIR=C:\tools\prog\atp\ SET PATH=C:\tools\prog\atp;"%PATH% tpbig both %1 s -r

The first line defines variable GNUDIR Different ATP versions use different name Sets program working environment The final \ is important

Intro to ATP

4

Spring 2009

U I Sample Batch File (cont.)

ECE 529 Lecture 4

Second line adds executable to your search path (not needed if set this at boot time) The next line calls ATP itself tpbig both %1 s -R

both tells program to write error messages to screen and to file (useful for debugging) Could also set disk to only do disk file or leave blank for no message First %1 is input data file from ATPDrawIntro to ATP5

Spring 2009

U I Sample Batch File (cont.)

ECE 529 Lecture 4

The s is to create appropriate output file. -R tells ATP overwrite existing output file if one exists

This bat file will let you run ATP, and all ofthe support program (line constants etc)

Intro to ATP

6

Spring 2009

U I

Editing startup Resides in same directory as tpbig Sets variables for the program

ECE 529 Lecture 4

ATP reads a file called startup A few suggested changes from default Change PL4 file format to work with PlotXY Ignore blank lines

Intro to ATP

7

Spring 2009

U I

Editing startup Resides in same directory as tpbig Sets variables for the program

ECE 529 Lecture 4

ATP reads a file called startup A few suggested changes from default Change PL4 file format to work with PlotXY NOBLAN set to 0 NEWPL4 set to 1

Intro to ATP

8

Spring 2009

U I

Setting Up ATPDraw

ECE 529 Lecture 4

Open up ATPDraw Select: Tools pull down menu Select: Options... Choose Preferences tab You select a text editor, or use Notepad (default) ATP is where you set path to your batch file

Armafit: which we wont cover in this courseIntro to ATP9

Spring 2009

U I

ATPDraw Preferences

ECE 529 Lecture 4

Intro to ATP

10

Spring 2009

U I

Further Settings Problems with lost help files though

ECE 529 Lecture 4

The Directories tab settings are ok However, you do want changes in theView/ATP tab Select Edit settings tab You may want to change some of the default settings. However, you can change any of these for a specific data fileIntro to ATP11

Spring 2009

U I

Simulation Settings

ECE 529 Lecture 4

Default time step (deltaT)is very small Default run time short Xopt and Copt ok Select Power Frequency Reset to 60 Hz from 50Hz Can mess up some sources

Intro to ATP

12

Spring 2009

U I

Output Settings

ECE 529 Lecture 4

Probably dont need theselected Printout options for most cases Slow down the program somewhat Plot frequency should be low and odd.

Intro to ATP

13

Spring 2009

U I

Format Settings

ECE 529 Lecture 4

Switch settings ok formost cases (are for statistical studies only) May want to set some of Misc settings, although they will follow from some items in Drawing FileIntro to ATP14

Spring 2009

U I

Saving New Settings

ECE 529 Lecture 4

The Save or Apply buttons arentsufficient to permanently save change Also choose: Tools --> Save Options

Intro to ATP

15

Spring 2009

U I

Other Settings

ECE 529 Lecture 4

To set plotting program and other optionsyou need to open a file Either select the File|Open sequence of click on the icon Initial default is the Examples directory, after that it is the last directory worked in. For now, choose example Exa_1.adp (*.adp represents the drawing files).Intro to ATP

16

Spring 2009

U I

Example 1

ECE 529 Lecture 4

Intro to ATP

17

Spring 2009

U I

ATP Menu

ECE 529 Lecture 4

A new pulldownmenu is now available at the top of the window, called ATP

Intro to ATP

18

Spring 2009

U I

ATP Menu

ECE 529 Lecture 4

Settings is changes deltaTetc. for a given case Make File As generates ATP data file from drawing Run ATP calls your bat file Each Edit calls text editor Make Names, makes node names for drawingIntro to ATP19

Spring 2009

U I

Edit Commands

ECE 529 Lecture 4

Allows you to setadditional commands Run other ATP versions On Current ATP drawing On Selected File

Run plot programs On Current PL4

Use Update to setIntro to ATP20

Spring 2009

U I

Saving New Settings

ECE 529 Lecture 4

The Update buttons isnt sufficient tosave for next time All choose: Tools --> Save Options

Intro to ATP

21

Spring 2009

U I

Running an ATP File

ECE 529 Lecture 4

Now we run the example case opened earlier Always a multi-step process 1) Make file to create ATP data file from drawing. Must do this every time you change drawing Default is to place this in ATP subdirectory under ATPDraw home directory (with extension *.ATP) Can edit this file with Edit ATP-File option (not saved to drawing file)

2) Run your case 3) Call plotting programIntro to ATP22

Spring 2009

U I

Running an ATP File

ECE 529 Lecture 4

The drawing file saved separately (save often) Remember to save your changes often Default is to save this in the Projectsubdirectory under ATPDraw Note that if want to save elsewhere, need to select a new home for both ADP and ATP files PL4 and *.lis (or *.out depending on version) are written to same directory at *.ATP file Need to cleanup directories periodicallyIntro to ATP23

Spring 2009

U I

Making You Own File

ECE 529 Lecture 4

Open a new drawing (from Filemenu or from icon) Can get the component menu by right clicking mouse in the drawing screen Each item lets you select components to create More later.Intro to ATP24

Spring 2009

U I

Associated Files

ECE 529 Lecture 4

Input Datafile (text file) Extension options: *.dat or *.atp (ATPDraw) Avoid Long File Names

Plot Datafile (formatted ASCII) Extension *.PL4

Text Output File (plain text) Extension: *.OUT or *.LIS Error Messages in this fileIntro to ATP25

Spring 2009

U I

Associated Files (cont)

ECE 529 Lecture 4

ATPDraw Schematic File Extension: *.acp (or *.adp for older versions)

Supplement Include File Use modular programs Examples: Line constants output, subsystems Extension options: *.pch, *.pun, *.lib

Intro to ATP

26

Spring 2009

U I

Creating a File: Text Based

ECE 529 Lecture 4

Use fixed width fonts with your text editor If use MS-Word or Word-Pad make sure use Courier

Plain text editor better option Best if it provides column number Older ATP versions do not perform type checking, use all upper case for variables Column alignment is very important The ATP rule book refers to individual lines as data cards27

Intro to ATP

Spring 2009

U I

Sample File

ECE 529 Lecture 4

C Brian K. Johnson C Simulation for problem 3.11 in Greenwood BEGIN NEW DATA CASE C ........................... Miscellaneous data .............................. C DeltaT