06-18-2018 04:19 AM
good news!!!
I managed to communicate with my device and make it broadcast, there is only one problem I do not understand that you might be able to help me overcome. (The problem appears in the picture)
06-18-2018 06:53 AM - edited 06-18-2018 06:55 AM
@Matanlaza wrote:
good news!!!
I managed to communicate with my device and make it broadcast, there is only one problem I do not understand that you might be able to help me overcome. (The problem appears in the picture)
You should save your VI with your default settings, and upload your very VI and not a screenshot here! It is much easier to debug your code if we can work on the actual VI!
There are several issues with your latest code version:
:OUTP ON
Try something like the following...
If you have any more problem with your VI, you should attach your VI here, or create a snippet and post that one...
06-18-2018 08:13 AM
thanks a lot, I will try it and hope for good!
06-18-2018 08:19 AM
There is a small mistake in the attached VI/snippet: forgot to connect the "OK Button" control to the Case structure's selector terminal, but I guess you found the problem...
06-19-2018 12:03 AM
Thank you very much for the comments, it is very helpful!
As you saw, I am at the beginning of my way and your comments advanced me towards the goal.
I'll try to fix some things in the software and if I get stuck I'll upload the VI and not a picture 🙂
06-19-2018 12:06 AM
Good luck, and have fun learning LabVIEW! 🙂
06-19-2018 12:43 AM
Hey again,
I'm coming back to you faster than I thought 😄
the program is working great but there is still the same problem with the message shown in the pictures, do you know what it means?
another issue, I understand the block diagram of the VISA but there is one block that I did not understand so much what its importance - "property node" - the block before the while loop.
thanks and have a great day 🙂
06-19-2018 01:13 AM - edited 06-19-2018 01:14 AM
You did not really make the same VI as I showed you before.
I see you try to program an output enable/disable feature with that Case structure. The problem with the recent version of your VI is that, you repeatedly execute one of the ON or OFF commands. This is not a desirable design. You could use an Event Structure, which gives more flexibility, but I would not make that big step since you are a beginner.
So I advise you to experiment with my original VI! Where you use the Latching "OK Button", to execute only ONCE when you click on the button, and not repeatedly commands! Regarding to your question, that property node just sets a certain timeout. You can try to increase it to 10 sec (10000 msec), as I remember that was the used value in the official driver. And the error msg means exactly what it says: a timeout error. It means that, the VISA Read did not read data back from the instrument. This can be due to several things, I am not sure yet.
So please test the unit with my VI, and see if there is any error with it?
06-19-2018 01:33 AM - edited 06-19-2018 01:34 AM
Ok, you have to read the pdf programming manual a bit more. The reason of the timeout error is that, the device does not reply with data for the
":OUTP On/OFF"
commands. You need to query a status response with the
":OUTP?"
command! See my attached VI for testing! And please use this very VI and not a modified one, before showing error msgs! 🙂
06-19-2018 02:45 AM
thanks again! I'm beginning to understand things and of course, there are things I need to improve on
I checked and it works, however, after it performs the action the error pops up again as before. 😞
I just want to understand how to fix this mistake and from there I believe that I will manage on my own, hopefully 😄