LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Fuzzy Control file build problem

Hi I want to build my fuzzy control file. For example when I build a file ( for example in Labview's example "FuzzyEx Dynamic Fuzzy Controller for a greenhouse") system didnt work. I want to build this file and control my system. Why the Labview's example didnt working when I build this file?

0 Kudos
Message 1 of 11
(4,359 Views)

Hi

 

When you say it doesn't work, does it mean you have an error constructing or it is just not getting the expected value? Try to add your code to this post and explain what is not working.

 

As you could see with the example, it is possible to create your system with the API. However notice that this example already have the rules in the system and we are only modifying the values of the membership functions. So, if you are creating from scratch, you have to create the rules too.

Barp - Control, Simulation, RTT and HIL - National Instruments
0 Kudos
Message 2 of 11
(4,334 Views)

The files are below. When I built these files. System doesnt working. Why ?

0 Kudos
Message 3 of 11
(4,321 Views)

When I run the VI in attachment, I do not see any "error" and the VI works as expected in the example. What kind of problem are you encountering? Could you describe what issue you are encountering?

 

Also, are you using which Operating System? Do you have comma as decimal operator? Any additional information will help us find out what is not working for this example.

 

Thank you!

Barp - Control, Simulation, RTT and HIL - National Instruments
0 Kudos
Message 4 of 11
(4,315 Views)

This example working fine bu I want to built this example and make it exe (aplication) file. When I built this file fuzzy controller didnt work.

0 Kudos
Message 5 of 11
(4,293 Views)

If you want to create a EXE, then you have to be familiar with Build Specifications and you have to add the external file (.fs) to the project and build specifications. Do you actually have the project available for me to look? Also, when you try to run the EXE, where do you place the .fs file? It is possible that your EXE can't find the location of the files. Does the .fs file is on the same location?

Barp - Control, Simulation, RTT and HIL - National Instruments
0 Kudos
Message 6 of 11
(4,274 Views)

could you make and send this project to me? (Exe file of this files)

0 Kudos
Message 7 of 11
(4,260 Views)

Hi ismail,

 

I think this may help if you're having trouble distributing your application.  That tutorial will walk you through the requirements in the Source Files section when you create your build specification, like the Startup VI and Always Included files that Barp mentioned.

 

- Greg J

0 Kudos
Message 8 of 11
(4,240 Views)

I built files by doing  distributing your application . But again same problem occured. First image is vi image, fuzzy controller is working and membership functions are displayed. Second image is application which I built, when I run this application fuzzy controller is not working and membership functions arent displayed...where I am making mistake

Download All
0 Kudos
Message 9 of 11
(4,230 Views)

Hey ismail,

 

The problem is related to the way LabVIEW treats file paths in 2009. As you can see in the code, we use the function "Current VI's Path", which gives you the VI in the Development Environment. However, when we try to build an EXE, this VI will give a different path. For example, if you do not do any changes, this VI will give "C:\Users\,<me>\Documents\Customer Files\builds\BuildFuzzy\My Application\Application.exe\LabVIEW 2009\examples\control\fuzzy\Dynamic greenhouse controller\FuzzyEx Dynamic Controller for a greenhouse.vi", which is not a valid system path.

 

So, you have option to hardcode the path to a location that you know on the file system or you can try to strip-out all the file path until you get to "My Application". Since the file system is kind of long, another option is to change the configuration of your build specification to "Use LabVIEW 8.x fiel layout". To do that, open your build specifications and choose "Advanced" under "Categories". The option is at the bottom. If you do this change, you just need another "Strip Path" VI to get the right information.

 

Please let me know if that works for you.

Barp - Control, Simulation, RTT and HIL - National Instruments
0 Kudos
Message 10 of 11
(4,189 Views)