sjukheter Posted February 26, 2011 Report Share Posted February 26, 2011 (edited) i am doing one application in which user will handle the SMPS by labview. So far in the gui i have taken 13 numeric indicators to display the current parameters(temperature, voltage, current and power etc.) in the SMPS and in the 13 indicators five are only monitor indicators means which always display the current values and no interaction of user on that five(only observation). Those five indicators display the result by sending commands from write visa block everytime. Coming to the remining numeric indicators(8) user can write the new values in the indicators which will taken by write visa and then writen to the SMPS. First doubt: --------------- Is it right for taking numeric indicators for wrting directly from textboxes. Is that possible? if no how can write values from that indicators. indicators means it will only for display purpose. Second doubt ---------------------- In that 8 numeric indicators are build under checkbox which display 6 when it is unchecked and 2 in ither case. So, i want to make a program that if user can write the values in the textboxes and which can be taken and written to the serial port by write visa block. can any one give me suggestions about how i can continue to that? I am using basic serial write read example for usb communication and using labview 8.5. hoping for help. Edited February 26, 2011 by sjukheter Quote Link to comment
jgcode Posted February 26, 2011 Report Share Posted February 26, 2011 Might be helpful if you post some code of what you have done sjukheter. Quote Link to comment
sjukheter Posted February 26, 2011 Author Report Share Posted February 26, 2011 Might be helpful if you post some code of what you have done sjukheter. yes, you can find the attachment and right now i am just sending five commands especially for five monitor indicators which i have described above and under check box you can find writeand read indicators. i want do this operations continously and get the data and set data alltime. another.vi Quote Link to comment
Anders Björk Posted February 27, 2011 Report Share Posted February 27, 2011 yes, you can find the attachment and right now i am just sending five commands especially for five monitor indicators which i have described above and under check box you can find writeand read indicators. i want do this operations continously and get the data and set data alltime. Sjukheter you will need to format the string you get from read and connect the correct outputs to the indicators. Furthermore, should it not be a index-array on leftside where char codes are? Surely you have some documentation about the message you will receive? I think handling the serial write and read in one loop and the actual decomposition of the string in another is good idea. Look at Producer / Consumer design pattern. Quote Link to comment
sjukheter Posted February 27, 2011 Author Report Share Posted February 27, 2011 Sjukheter you will need to format the string you get from read and connect the correct outputs to the indicators. Furthermore, should it not be a index-array on leftside where char codes are? Surely you have some documentation about the message you will receive? I think handling the serial write and read in one loop and the actual decomposition of the string in another is good idea. Look at Producer / Consumer design pattern. My instructor said, we are not at all using string communication added to this like hex communication is better . I know in labview only string can write and read also performed in string formet but how i can send hex commands to port and as well it send only hex not strings. Can you explaine how we can acheive this...thankj you... Quote Link to comment
Anders Björk Posted February 27, 2011 Report Share Posted February 27, 2011 My instructor said, we are not at all using string communication added to this like hex communication is better . I know in labview only string can write and read also performed in string formet but how i can send hex commands to port and as well it send only hex not strings. Can you explaine how we can acheive this...thankj you... Have you checked out this http://digital.ni.co...625722800710865 Quote Link to comment
sjukheter Posted February 27, 2011 Author Report Share Posted February 27, 2011 Have you checked out this http://digital.ni.co...625722800710865 thanks for your quick reply and i read the article and i saw many examples on ni forums also but as far as my notice that write visa only takes string format even though if you use typecast or array to string converters etc.. at last it will take in string only. This is same as what applied to read block also. Some people saw this message and they may feel about my basic level questions but indeed i need to know all the thing. Second question implies with numeric indicators that i know that i can read data by writing commands into and get the data and i will display in indicators but how i can do like if user enter any value in the indicator then in background the command will take that value and write to port again and also i notices while if any number displayed in numeric indicators will not erased by backspace when the vi is running . I fully messed with these problems and day by day i am wasting lot of time. Can any one help me ..? Quote Link to comment
ShaunR Posted February 27, 2011 Report Share Posted February 27, 2011 I know in labview only string can write and read also performed in string formet but how i can send hex commands to port and as well it send only hex not strings. Can you explaine how we can acheive this...thankj you... Strings are arrays of bytes. Quote Link to comment
Anders Björk Posted February 27, 2011 Report Share Posted February 27, 2011 thanks for your quick reply and i read the article and i saw many examples on ni forums also but as far as my notice that write visa only takes string format even though if you use typecast or array to string converters etc.. at last it will take in string only. This is same as what applied to read block also. Some people saw this message and they may feel about my basic level questions but indeed i need to know all the thing. Second question implies with numeric indicators that i know that i can read data by writing commands into and get the data and i will display in indicators but how i can do like if user enter any value in the indicator then in background the command will take that value and write to port again and also i notices while if any number displayed in numeric indicators will not erased by backspace when the vi is running . I fully messed with these problems and day by day i am wasting lot of time. Can any one help me ..? Have you read any book on LabVIEW? Quote Link to comment
sjukheter Posted February 28, 2011 Author Report Share Posted February 28, 2011 Have you read any book on LabVIEW? no i did not read any book but i saw some beginer materials and video's on ni website and also everytime watching forums and learning new stuff.. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.