0

I sense a data 'v' in a Simulink model and now want to generate 'v' magnitude of DC voltage in again, the same simulink model.

I tried to get this working by putting 'v' in block parameters of DC voltage block.

Please help me with how I can generate 'v' voltage from DC voltage block.

Brian Tompsett - 汤莱恩
  • 5,753
  • 72
  • 57
  • 129
  • I would suggest `From Workspace` block, too, as am304 did in the answer. Other option may be using Matlab Function Block to load mat file from disk to your current workspace. – Y. Chang Jul 25 '14 at 14:27
  • I cannot post pics here. https://lh4.googleusercontent.com/-cspOOIICn6w/U9OG-mV53NI/AAAAAAAAAFw/uX334dAF-cg/w435-h545-no/Capture.JPG I want to vary this highlighted voltage continuously based on certain measurement within the same simulink model. Can we use matlab function block for the same? – user3876908 Jul 26 '14 at 11:13

1 Answers1

0

Is this with Simscape? if so, you can use the Controlled Voltage Source block, in combination with a From Workspace block and a Simulink-PS Converter block.

am304
  • 13,758
  • 2
  • 22
  • 40
  • Actually, I was working on a transformer. I want to dynamically change voltage tap on secondary winding based on certain measurement done in the same simulink model. Unlike a controlled voltage source block, there is no controlled transformer in simulink library. Please suggest. Thanks. – user3876908 Jul 26 '14 at 10:21
  • 1
    You can't. The screenshot you have shows block parameters. You need to distinguish between parameters (constant) and signals (varying with time). You will need to create your own transformer block from scratch. See http://blogs.mathworks.com/seth/2011/03/08/how-do-i-change-a-block-parameter-based-on-the-output-of-another-block/. – am304 Jul 27 '14 at 09:13