tags: C # learning process c# matlab simulink

using System;
using System.IO;
using System.Windows.Forms;
using MLApp;
using MathWorks.MATLAB.NET.Utility;
using MathWorks.MATLAB.NET.Arrays;
using MathWorks;
using MathWorks.MATLAB;
## Add using
namespace my1
{
public partial class Form1 : Form
{
MLApp.MLAppClass matlab = new MLApp.MLAppClass();
## Instantiated object Named Matlab
private void button2_Click(object sender, EventArgs e)
{
string operation1;
operation1 = "open_system('bosilunwen')";
matlab.Execute(operation1);
## Enter and run "Open_System" in the MATLAB engine'bosilunwen')”
## Open a Simulink model called "bosilunwen"
Everything can use the MATLAB operation of Simulink instructions to operate from C # from C #.
MATLAB operation of Simulink instructions
Install compilation CurveLab2.1.3 in the Windows10 environment and use Fortran in VS2012 to call MATLAB engines to implement draw calculations. Article catalog Foreword First, download link Second, co...
In the last few articles, the simulation of the ADRC algorithm was established, and the follow-up must be verified on the actual object. In the process of writing the C code, I had a whim. If I can us...
Embedded MATLAB Function is located in User-Defined Functions libraries, this module may be used in the composition of the Simulink model to a MATLAB function. Format is as follows: function [output1,...
Original link: Use Matlab's Simulink forUDP communication requires attention Packing and unpacking of data Use Simulink for UDP sending As shown in the figure below, it is built using Simulink blocksU...
Use matlab simulink to view the data conveniently, simulink supports custom bus, and you can customize the data structure in the bus. It should be noted that the custom data structure is in order. Whe...
Introduce how to use the matlab function in simulink, which is a custom module that can give users a richer development experience. The following figure shows the module. Double-click the module to en...
This paper studies the method of calling Matlab function in Simulink model. Article Directory 1 Matlab Function module 2 Modeling and code generation 3 Data management in Matlab Function 3.1 Associate...
Article Directory 1 s-function 2 Specific settings 2.1 Input and output 2.1.1 Add the corresponding input signal 2.1.2 Add the corresponding output signal 2.2 Build S-Function 3 Source code analysis 3...
This article introduces how to embed C language in simulink of matlab for multi-input multi-output simulation; matlab version is 2015b; Creation is not easy, if this article helped you; If this articl...
Basic PID control 1. Control requirements The controlled object is a second-order linear transfer function of 133 / (s ^ 2 + 25s) The generated signal is sinusoidal signal y = A * sin (2 * pi * Ft) Pr...