Home › Forums › EXCHANGE › CO-SIMULATION PYTHON OPTISYSTEM15 CIDF Scheduler error › Reply To: CO-SIMULATION PYTHON OPTISYSTEM15 CIDF Scheduler error
![Profile Photo](https://optiwave.com/wp-content/uploads/avatars/63222/1668178330-bpfull.jpg)
Hi Claudette,
Before you can retrieve data from the signal you first have to ensure that you calculated the project
mydocument.CalculateProject(True, True)
or
mydocument.CalculateAllSweepIterations(True, True)
depending on what type of simulation you are running.
Then to send the data to a .txt file dynamically you can assign a value to a file location, ex. file = open(“SomeFilePath”),’w’), and then in a loop file.write(objSignal) to export the data.
An example of this can be found in OptiSystemSDK_General (SDK_Result.py or SDK_OutputPort.py)
Another possibility for why it isn’t working is that objOpticalSignalInput1 is not defined. If its copy and pasted from an example you would have to ensure that all variables are defined somewhere. ex objOpticalSignalInput1 = GetSampledSignalSignal()
If you’re still having troubles you can either send me the exact error message or I can take a look at the code for you and debug it.
Regards,
Alex
Categories
- All
-
Knowledge
Contains a detailed Q&A knowledge base. -
General
All non-technical questions. -
System
Optical system design and analysis. -
Instrument
Communicate and control different kinds of instruments. -
SPICE
Opto-electronic circuit design. -
FDTD
Finite-Difference Time-Domain simulation. -
BPM
Beam Propagation Method analysis and design. -
Grating
Fiber optic grating simulation. -
Fiber
Optical fiber design and characterization. -
Exchange
Users can exchange design files.
(Matlab, C++, etc.)