From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
10-18-2018 05:28 AM
Hello Kouki,
i am not clear on what you are trying to implement.
My issue was running the nl-opt toolbox on dedicated hardware (PXI)
I never succeeded in implementing matlab code to the PXI, due to toolbox dependencies.
Thus i resorted to do all my programming in C code, with the NL-opt toolbox.
For implementing NMPC within matlab i suggest to either code from scratch (build own optimizer and MPC algorithm), use the matlab optimization toolbox (thus only coding the MPC part) or look for a NMPC toolbox (i believe this exist).
But for implementing NMPC on dedicated PXI hardware, i suggest to avoid matlab and build your code in C.
best regards,
Tom
10-18-2018 06:12 AM
Dear ThomJ,
Thanks for your answer. But for this state, my problem is haw used NLOP library to optimized the Nonlinear model predictive control problem in Simulink. I have used s-function for coding the MPC part AND NLOP library for optimisation. Please if you have any information tell me. Thank you.
Best regrate
KOUKI
10-18-2018 06:23 AM
If i understand correctly you are trying to implement C code in simulink using the s-function block.
i have no experience in exporting the nlopt library to matlab, and i suggest you try the mathworks forums for more help.
or try to use matlab toolboxes for your optimization, i believe either matlab or the community will have already ported most if not all of the algoritmhs available in the NL Opt library
Best of luck.
10-24-2018 04:37 AM
Dear ThomJ,
Thanks for the reply,
When you are used Nl-opt toolbox in C code for solving the optimisation problem of nonlinear predictive control, you have used "NLOPT_GN_ISRES" NLOPT algorithm?
Best regrate
KOUKI
10-25-2018 07:09 AM
Hi Kouki,
I have applied BOBYQA.
Best regards,
Tom
10-26-2018 07:02 AM
Thanks for the reply Tom.
Best regards,
KOUKI
04-01-2021 05:33 AM
I compiled a quite simple model with the VeriStand 2020R4 toolchain (selecting the windows target) and add the following custom code to avoid resolution of __setusermatherr symbol at load time (it's just an empty stub).
The model seems to work on Windows (test done with a simple custom scheduler not VeriStand).
There are no more bad entries reported by DLL checker for LV2017, but I currently have no Pharlaps target to test it in real time.