[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: program writting



Fardin,
  There are basically three options for adding content to TRNSYS. If the performance of the component that you wish to add is fairly simple, then you can actually do a very great deal simply by writing equations directly into the input file. Often times control strategies can be written in this manner. If your component is more complex then the fact that you cannot put an IF - THEN - ELSE structure into the equations becomes a problem.

The most common way to add a component is to use a Fortran compiler (such as the Compaq Visual Studio) and write a new Type, compiling and linking it in with the other components contained in the trnlib.dll. There are instructions on how to create a DLL project in CVF at the end of Chapter 3 in your manual and there is a workspace included in the \trnsys15 directory. If you are not sure about how to structure your component, I would suggest taking an existing component (Type6 for example) and structuring your new one based on that.

The final method is that you can use another programming language to create your component, then compile it and turn it into a DLL called EXTDLL. Again, there is information in Chapter 3 of the main TRNSYS manual. TRNSYS Type61 is designed to communicate with a component called EXTDLL, passing it all the information that is typically passed to a standard component. You will find the basic structure for creating the EXTDLL component in the userlib folder in a file called extdll.for.

Kind regards,
  David

At 02:44 PM 10/2/2003 +0800, you wrote:

Dears all

 <?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Good day

How and where in TRNSYS 15 could I write some programming

And is it possible with which programming script (C++, VB,…)?

And how is possible to make your own component?

 

Thanks
Fardin

****************************************************************************************
Thermal Energy System Specialists (TESS)
David BRADLEY                           2916 Marketplace Drive - Suite 104
Project Engineer                           Madison, WI 53719
Phone: (608) 274-2577 USA
Fax: (608) 278-1475
E-mail: bradley@tess-inc.com
Web Pages:  http://www.tess-inc.com    and      http://www.trnsys.com

"Providing software solutions for today's energy engineering projects"
****************************************************************************************