Simulation/Fimmwave-Fimmprop

From OptoelectronicsWiki
Revision as of 13:56, 14 October 2010 by 128.111.239.6 (Talk)

Jump to: navigation, search

Scripting

There are a few steps that you need to do with your computer in order to allow scripting in python of Fimmwave. Please see the manual (File:Fimmwave Scripting Manual.pdf) for step by step instructions. I have already done this to the simulation computer.

Once you have completed these preliminary steps, please feel free to take a look at this already constructed python scripting example File:LioniX WG Example.zip. If you write a new and interesting example, with additional functionality please post the commented code.

1) Extract all of the files in the above .zip you will need them to walk through this example. Be sure to place all three of these files (LionixPyScriptExampleFDM.py, LionixPyScriptExampleFMM.py and PdPythonLib.py) in the same folder.

2) Open Fimmwave via the desktop shortcut with the target "...fimmwave.exe" -pt 5101 for reasons described in the manual. (python and other programs communicate with communicate with Fimmave over TCP/IP)

3) Open LioniX_WG.prj

4) Open LionixPyScriptExampleFDM.py or LionixPyScriptExampleFMM.py in Python IDLE (or your preferred python script compiler)

5) You can modify a output file save location in this script, else the data will simply be saved in the current directory of your script

6) Run the script with Python 2.3 (other versions give you errors, this is the version on the Fimmwave CD).

7) Once the script is complete the output file can be viewed. It is tab delimited and makes a nice table in excel.

Have fun and share your knowledge!!!

Updates

There is an update CD in one of the binders for July 19, 2010, Jock has a copy.

Once you install you need to replace these 3 files in the bin folder. File:LioniX WG Example.zip