Jump to content

Mellroth

Members
  • Posts

    602
  • Joined

  • Last visited

  • Days Won

    16

Everything posted by Mellroth

  1. QUOTE (Daklu @ Mar 31 2008, 07:53 PM) I think it is safe to say that the unbundle version should be faster for small arrays, and when only a few elements in the cluster is checked. The main goal for me when I first started to use this, was not speed, but a way to easily update the code to include many cluster elements and to let a user select elements to search from a GUI. The search algorithm is pretty much unchanged regardless of the size of the cluster, making it easier to maintain. /J
  2. Sometimes when I need to search through cluster arrays with some element values excluded, I do like this Download File:post-5958-1206627103.vi 1. Turn cluster array into a boolean cluster array by checking equality 2. Filter the active element by performing an AND operation 3. Search for the desired boolean cluster pattern In this case the resulting index is 4, since the first element wasn't activated. Hope this helps. /J
  3. QUOTE (Anders Björk @ Mar 26 2008, 08:59 AM) I agree with Anders that a shift-register could hold the background noise, but from what I can see in the picture posted, the shift-register value will change at every iteration, regardless of the measurement type. To get this working you would have to feed the case structure, that selects running state, with the old shift-register data. I would also suggest that the shift register is initialized by reading a previously saved background noise file. Then there is a question whether a real measurement should be possible if there is no "natural freq" data present? /J
  4. QUOTE (alexadmin @ Mar 18 2008, 11:53 AM) Seems like your code is reading the integer value and then waits for the event to fire. You can solve this by reading the integer value inside the event structure using a control reference (or local variable). You also say that you calculate the integer value based on the states of the boolean controls, and then why don't you keep the integer value in a shift-register passed in/out of each event case, this would also solve the synchronization issue that you are experiencing. Please show some code to get more help. /J
  5. QUOTE(lizimunro @ Mar 6 2008, 01:10 PM) Hi, No offense, but I would suggest that you try to clean up the code a bit, since it will make debugging much easier. * Try to keep wires straigh and visible (not hidden behind structures etc.) * don't use sequence structures to determine the data flow, this is in most cases handled by the wires automatically.- * add error handling, so that you can detect and handle errors, e.g. returned by the VISA read * runtime in sec, will always retuirn a value close to zero, since there is no way for LabVIEW to know that the second timer should be executed after the outer while loop Second, I think that the reason your code does not work is due to one of the following; 1. Match string uses \n to find newline character, but this is given in normal notation, right-click on the constant and select \-code display instead (if you do that you'll see a string of "\\n", i.e. a two character search, but maybe this is as it should be?) 2. There is no handling in the case that the match pattern function fails (perhaps due to that we have not read enough characters from the serial port) 3. VISA read returns an error that is left unhandled (I guess this is unlikely though) Good Luck /J
  6. QUOTE(crelf @ Feb 13 2008, 07:35 PM) True, but App.User is platform independant and could be used on Macs/Linux machines as well. Perhaps it will also work on Vista /J
  7. QUOTE(crelf @ Feb 13 2008, 06:34 PM) Or this /J
  8. QUOTE(Dan Bookwalter @ Feb 13 2008, 12:05 PM) You can also make the LV2 global reentrant and use VI server "Call by reference node" to access data. The VI server reference is then your reference to the data. Tomi's suggestion is probably faster, but using VI-server means that different objects don't share the same memory to store the by-ref data, and in turn this means that two objects can access data in parallel. /J
  9. Mellroth

    Delay Timer

    QUOTE(Natu @ Feb 4 2008, 12:35 PM) Hi If you are calling these three VIs in the same loop in your main VI, the timing for the updates will be determined by the maximum waiting time in them (2000 in this case). The reason for this is that the main loop cannot jump to the next iteration until all nodes in the current iteration are finished. Have a look in the timing palette, and checkout the "Elapsed Time" function, maybe this is something you could use. As said before, please post your MainVI to get more help. /J
  10. QUOTE(Nepomuk @ Jan 31 2008, 11:23 PM) Hi Andy, First some questions: Can you tell us what kind of device you are trying to use? You say the manual list a set of commands you can send, could you please give an example of a command? Does the manual say anything about how you should end a command, e.g. LF, CR etc.? If it does it is probably a stream connection ala TCP/IP, TELNET, ... Do you only have the IP address, no additional IP port information? (If no port is given, I would think that there is a standard protocol in use) Then some comments: As jdunham said, use a port scan to see what ports are open, then check the ports against a list of known ports ( http://www.networksorcery.com/enp/protocol/ip/ports00000.htm ). To check the communication, you could download a free network analyzer called Wireshark ( http://www.wireshark.org/ ). Off course this only works when sniffing on a established connection. Good luck /J
  11. QUOTE(gustav @ Jan 29 2008, 11:50 AM) I think the port tcplomp is taking about is the port that this application uses for remote access through VI server. You can change this port after you have compiled your exe, just open up the ini file that should be next to the exe file, check for the following keys server.tcp.enabled=True server.vi.access="+*" server.tcp.port=3340 basically these keys enable TCP access on port 3340, and exporting all VIs for remote access. In your test2.vi you then open an Application reference to localhost (if they are on the same computer), port 3340 (default is 3363 if the key is not present). Then use this application reference as an input to the Open VI reference. /J
  12. QUOTE(iniesta @ Jan 25 2008, 01:33 PM) You should only update the chart if you really read a value from the serial port, i.e. you should check that you get requested number of bytes at the serial port. In your case (with a small delay) you probably get "bytes at serial port" = 0, or a value less than than the actual amount transferred. You then convert a non-complete response into a number, hence the strange trace. /J
  13. QUOTE(orko @ Dec 4 2007, 10:56 PM) I think the reason that this does not work is that the Text.Selection.Start (or End) also takes the \ into account. E.g. if the \-code string displayed is string "12\s345" and we try to add a \t at the end, Text.Selection.End returns 7, when it should return 6. Therefore Insert Into Array fails to add the new \t element. /J
  14. QUOTE(rolfk @ Nov 20 2007, 10:15 AM) Cool-LV, just note that Rolf's suggestion of using the ipconfig /release and /renew, is not working if your network cars are configured using static IP addresses, i.e. they must be configured to use DHCP. Good luck! /J
  15. QUOTE(rolfk @ Nov 20 2007, 10:15 AM) Cool-LV, just note that Rolf's suggestion of using the ipconfig /release and /renew, is not working if your network cars are configured using static IP addresses, i.e. they must be configured to use DHCP. Good luck! /J
  16. QUOTE(ziman @ Oct 16 2006, 11:26 AM) Do you mean that the menu choice "Tools->SIT Connection Manager" is not available? Is the SIT sub-palette in the Function palette (check under Addons) present? /J
  17. QUOTE(Aristos Queue @ Nov 15 2007, 01:43 PM) Maybe in MS Windows /J
  18. QUOTE(Norm Kirchner @ Nov 15 2007, 12:39 AM) Hi Norm, you probably already know this, but if you only want to sort the Tree-items by one column, you can do that with an Invoke node. http://lavag.org/old_files/monthly_11_2007/post-5958-1195108778.png' target="_blank"> /J
  19. QUOTE(Val Brown @ Nov 14 2007, 09:23 AM) What you want is Windows support of the "Inline C" structure? http://zone.ni.com/reference/en-XX/help/37.../inline_c_node/ /J
  20. QUOTE(neB @ Nov 12 2007, 04:45 PM) Disabling Nagle is useful if you have small messages to send over TCP/IP, and you want to keep the delay of the messages to a minimum. But disabling Nagle in this case would probably give you less total throughput, since the size of the transfer is quite big. Just my 2c /J
  21. QUOTE(Anders Björk @ Nov 11 2007, 02:26 PM) Hi Anders, have you tried to use a timed loop for the GPS data, using the DAQmx sample clock as the timing source? /J
  22. QUOTE(PJM_labview @ Nov 10 2007, 12:36 AM) I have seen this in LabVIEW 8.2.1 as well, but I don't remember if I got this message when saving, I think it was when I closed the FP. /J
  23. QUOTE(Neville D @ Nov 9 2007, 07:24 PM) Hi, I don't think Windows actually supports having the two cards on the same subnet. The problem, if I remember correctly, is that two cards on the same subnet will still cause windows to use one of the cards for communication, even if the other card was specified for the TCP traffic. /J
  24. QUOTE(Cool-LV @ Nov 8 2007, 04:55 AM) Can you be more specific about your problem? Do you want to disable the network interface on the computer, or do you want to change computer IP settings, or do you want to break a TCP connection, or ... /J
  25. QUOTE(akjohn @ Nov 3 2007, 06:13 AM) Hi, if you look in the RealTime function palette, there is a method called PING RT controllers, this method will return a list of all RT controllers on the local subnet (listed with name, IP, and MAC address). In the same palette you can also find a method to Reboot a RT controller, but you'll need the MAC address to do so. /J PS. this question belongs to the Realt Time forum, http://forums.lavag.org/Real-Time-f22.html
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.