• Introduction
• What is in this manual
• What is Caspoc
• User interface
• Introduction
• Starting
• Simulation
• Editing
• Viewing and printing
• Getting Started
• Basic editing
• Simulation in the time domain
• Basic User Interface Topics
• Editing
• Simulation
• Viewing
• Library
• Reports
• Project management
• Circuit and Block Diagram Components
• Introduction
• Cscript and user defined functions
• Component parameters
• Modeling Topics
• Introduction
• Power Electronics
• Semiconductors
• Electrical Machines
• Electrical drives
• Advanced Electrical Drives
• Power Systems
• Mechanical Systems
• Thermal Systems
• Magnetic Circuits
• Green Energy
• Advanced user interface topics
• Coupling to FEM
• Experimenter
• Analog hardware description language
• Embedded C code Export
• Coupling to Spice
• Small Signal Analysis
• Matlab coupling
• Tips and tricks
• Appendices

## Create your first multilevel simulation

In the previous tutorials you created an electric circuit and a block diagram. In this tutorial we will couple the circuit and the system simulation. This means that we will use both circuit components and a block diagram. You probably already noted that the there is a difference between the electric circuit anda block diagram. In the schematic this is visible by the different types of nodes that are used. The electrical circuit nodes are round, while the block diagram nodes are squared.

In this tutorial we will create a controlled voltage source, where the voltage is constructed in a block diagram. The voltage from the voltage source and the current flowing in the circuit are then measured. From the measured voltage and current the instantaneous power is calulated in the block diagram.

We start with opening Caspoc from the start menu. You will see the white work-screen where we will place the components and on the left side the Project Manager from where we will select components. From the Project Manager we will not only select our components, but we can also start tools and read data from it.

On the top of the window you see the menu items as well as many buttons. These buttons are shortcuts to the command that you can select from the menu.

In this tutorial we will create a block diagram for solving c from the above theorem and therefore we select our components from the Project Manager on the left side. Click on the [+] sign in front of Components or double click the item Components

The component group will open in the Project Manager and list three sub groups:
• Circuit
• Blocks
• Library
Circuit
From the item Components/Circuit we will select all components that have to do with physical components, for example resistors, inductors, semiconductors, etc. Blocks
From the item Components/Blocks we will select all components that have to do with signals and mathematical relations, for example addition, sinusoidal signals, integrators, etc. Library
From the item Components/Library we will select all components that have to do with a combination of physical components and signals or mathematical relations, for example electrical machines, PI controller, harmonics calculation, etc.

In this simulation we will create a block diagram using a multiplier block. In the Project Manager open the item Components/blocks

It shows you an overview of the categories that contain block diagram components. We will first place a multiplier on the work-screen. To do so, select the item Components/Blocks/Math You see a list of blocks that can be used in your block diagram. We select the block MUL, being a multiplier. You select a component and place it on the screen using the following steps:
1. Move the mouse pointer over the component to be selected, in our case the block MUL
2. Click and release the left mouse button, while the mouse pointer is positioned over the component. It is important to release the mouse button, the component is now sticked to your mouse pointer
3. Drag the mouse pointer over your work-screen to the place where you want the block MUL to be placed.
4. During dragging you will see that the block is sticked to your mouse pointer
5. To place the component, click and release the left mouse button. The component will be dropped onto the work-screen.
The block MUL is now placed on your work-screen. The next step is to add the controlled voltage source. This voltage source willl be connected to a resistor. In our first simulation we created a circuit from a voltage source and a resistor. This time we have to replace the voltage source by a controlled voltage source In the Project Manager open the item Components/Circuit It shows you an overview of the categories that contain circuit components. We will first place a controlled voltage source on the work-screen. To do so, select the item Components/Circuit/Controlled Sources You see a list of sources that can be used in your circuit. Since we need a controlled voltage source, we select the component B. You select a component and place it on the screen using the following steps:
1. Move the mouse pointer over the component to be selected, in our case the voltage source B
2. Click and release the left mouse button, while the mouse pointer is positioned over the component. It is important to release the mouse button, the component is now sticked to your mouse pointer
3. Drag the mouse pointer over your work-screen to the place where you want the controlled voltage source to be placed.
4. During dragging you will see that the controlled voltage source is sticked to your mouse pointer
5. (Try to click the right mouse pointer during dragging of the component over the work-screen, you will see that the component is rotating)
6. To place the component, click and release the left mouse button. The component will be dropped onto the work-screen.
At the moment that you click the left mouse button to place the component on the empty work-screen a message box pops-up. It askes you to automatically include a ground node. Just click the [YES] button to automatically insert a ground node. The voltage on this ground node will always be zero volt. The controlled voltage source is now placed on your work-screen. The next step is to add the resistor. You will find the resistor in the item Components/Circuit/RLC You see a list of pasive components that can be used in your circuit. Since we need a resistor, we select the component R. You select the resistor and place it on the screen using the following steps:
1. Move the mouse pointer over the component to be selected, in our case the resistor R
2. Click and release the left mouse button, while the mouse pointer is positioned over the component. It is important to release the mouse button, the component is now sticked to your mouse pointer
3. Drag the mouse pointer over your work-screen to the place where you want the resistor to be placed.
4. During dragging you will see that the resistor is sticked to your mouse pointer
5. (Try to click the right mouse pointer during dragging of the component over the work-screen, you will see that the component is rotating)
6. To place the component, click and release the left mouse button. The component will be dropped onto the work-screen.
Both components are now placed on the work-screen and we have to connect them. Connections are made by drawing wires between the nodes of the components. The drawing of a wire is started by clicking and releasing the node with the left mouse button. Drag the mouse pointer to the end node and click and release the mouse pointer to connect the wire. The voltage is given by the result fom the multiplication by the MUL block. We will assign numerical values to the input of the MUL block. The first input will get the numerical value 3 and the second input will get the numerical value 4. The voltage should equal 12 volt.
You assign a numerical value to a node by clicking with the right mouse pointer over the node. Move the mouse pointer over the first node and click the right mouse button. Enter the numerical value 3 and select [OK] to close the label dialog box. Repeat the same for the second input, but now with the numerical value 4. We would like to know the power dissipation in the resistor. Therefore we have to measure the voltage over the resistor and the current through the resistor. To measure the voltage over the resistor we have to label the node where we want the measure the voltage. Label the node in the same way as you assigned a numerical value to a block diagram node. Move the mouse pointer over the upper node of the resistor and click the right mouse button. Enter the label "out" in the input field ofthe label dialog box and click the button [OK] to close the dialog box. The voltage can now be measured from the label "out". To measure the voltage and current, we need a VOLTAGE and CURRENT block from the block diagram list. Select the item Components/Blocks/Source that contains an overview of source blocks for the block diagram. Select the block VOLTAGE and drag it onto the work-screen. Do the same for the block CURRENT. The VOLTAGE block has to measure the voltage on the node labeled "out". Open the block VOLTAGE by moving the mouse pointer over the VOLTAGE block and clicking it with the right mouse button. The component properties dialog box will pop up, where you have to specify the label "out" of the node at the text input field. Click the [OK] button to close the components properties dialog box. The current through the resistor R1 has to be measured by the CURRENT block. The name of the resistor is "R1". This name has to be specified at the block CURRENT, to measure the current through the resistor. Open the block CURRENT by moving the mouse pointer over the CURRENT block and clicking it with the right mouse button. The component properties dialog box will pop up, where you have to specify the name "R1" of the resistor at the text input field. To calculate the power dissipation in the resistor, we have to multiply the measured voltage with the current. Therefore we insert another MUL block and multiply the voltage and current signal. Select the MUL block from the Project Manager at Components/Blocks/Math Place the MUL block behind the voltage and current measurement and connect the inputs of the MUL block with the outputs from the VOLTAGE and CURRENT block. Since the output from the MUL2 block is the calculated power, we would like to rename that block and its output label. The name of the block and its output label can be changed in the component properties dialog box. Open the block MUL2 by moving the mouse pointer over the MUL2 block and clicking it with the right mouse button. The component properties dialog box will pop up, where you have to specify the block name "P" of at the upper text input field. The name of the output label is now changed into "P" Before we start the simulation, be sure that all animation options are enabled. Simply take care that all buttons are enabled as shown in the following button bar. Start the simulation by pressing the Play button or pressing the [Enter] key. The simulation is now started and the numerical calulated values of each node will be shown. The input voltage is set to 12 volt. Because of the resistor of 1kohm, the current throught the resistor equals 12mA. The power is thus 12*12m=144mW

© 2020 CASPOC, All rights reserved. Home   |   Terms and Conditions   |   Legal   |   Export Compliance   |   Privacy Policy   |   Site Map