Lexington

Members
  • Content Count

    19
  • Joined

  • Last visited

Community Reputation

0 Neutral

About Lexington

  • Rank
    Member
  1. Hello, I am currently having trouble using the get history function. Every time I try to call the function nothing happens. No alarms, nothing. The syntax that I am using is the following: DAQ_Server.gethistory("ChannelA",0,1000) [/CODE] I really need this to work. It is unfeasible for me to set up a sql server at the moment. Thanks Lexington
  2. Lexington

    Trouble Using Readdelim

    Ah thank you, I did not notice that. Lexington
  3. Lexington

    Trouble Using Readdelim

    Thank you for the last tip. I saw it in the user manual but, I must have somehow missed it. However, I now have another problem with readdelim, this time it is a bit more perplexing. Whenever I try to read the attached file, at line 22, the array that is read is {"","F74841",""} instead of {"F74841","","Centrifuge..."}. The lines above it are fine, however, the lines below it are shifted over as well. Is there any way to fix that? Point Descriptions.csv
  4. Lexington

    Trouble Using Readdelim

    Hello, I am experiencing trouble using ReadDelim. When I try to run: global string SavedGraphs private FileHandle = file.open("C:\DAQFactory\SavedGraphs.cfg",1,0,0,1) SavedGraphs=file.ReadDelim(FileHandle,-1,",",chr(10),1) [/CODE] For the file with data: [CODE] First Graph,A7225,mm,A74424,mm,,,,,,,,,,,,,,,,,,,,,,,,,,,, Moo,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, [/CODE] it gives me {{"NaN","NaN"..."NaN"}} However if I use parse instead: [CODE] global string SavedGraphs private FileHandle = file.open("C:\DAQFactory\SavedGraphs.cfg",1,0,0,1) SavedGraphs=parse(file.Read(FileHandle) ,-1,",") [/CODE] It gives me the correct values. However, I would rather use readDelim since it can parse returns. Is there something that I did wrong? Lexington SavedGraphs.txt
  5. Hello, I was wondering if there is expression that I could use to assign a trace to an axis? I was looking at the expressions that were associated with graphing and I couldn't find such an item. Lexington
  6. Lexington

    A Single Script For An Entire Group

    Hello, It looks like I am having trouble getting the script to work. Currently I have the following: private nextTime=floor(systime()/60)*60+60 //start of next minute private string groupA = {"TH1F1","TH2F1","TH3F1","TH4F1","TH5F1","TH6F1","TH7F1","TH8F1","TH1F2","TH2F2"\ ,"TH3F2","TH4F2","TH5F2","TH6F2","TH7F2","TH8F2"} private string groupB = {"TH1F1_DUP","TH2F1_DUP","TH3F1_DUP","TH4F1_DUP","TH5F1_DUP","TH6F1_DUP","TH7F1_DUP"\ ,"TH8F1_DUP","TH1F2_DUP","TH2F2_DUP","TH3F2_DUP","TH4F2_DUP","TH5F2_DUP","TH6F2_DUP","TH7F2_DUP","TH8F2_DUP"} while(1) waituntil(nextTime) //waits until start time for (private i=0,i private average=mean(groupA[i][nextTime,nextTime-3599.999]) //can't exactly be a minute average.time=nextTime //Adds the minute time stamp to the value groupB[i].AddValue(average) //Adds value to the point listed endfor nextTime+=60 //waits until next minute endwhile But I get an error on line 12. I guess I have some trouble understanding the group. I thought it was merely a matrix and I could specify the parts of the matrix that I wanted. Lexington
  7. Lexington

    A Single Script For An Entire Group

    Ah that makes sense. And for the renaming, I mean rename the group from Group B to Group B Minute.
  8. Hello, I was wondering if there was an easy way to have a sequence to map one group of channels to another group of channels. However the channels are not in numerical order. For an instance: GROUP A Channel1 Channel2 Channel3 ... Channel30 Map it into GROUP B Channel1_DUP Channel2_DUP Channel3_DUP ... Channel30_DUP Also is there an easy way to rename the groups? Lexington
  9. Hello, I have a weird issue where I have a sequence, F74407DUP, that calls a channel, F74407, but causes a C1000, channel or function not found, error but yet I have another sequence, TESTREST, calling the same channel and not causing an error. Additionally F74407DUP is a template script that is used to call other channels without issue. I have tried deleting and renaming the script and channels without avail. Please help! This doesn't make sense. Lexington test2.ctl
  10. Lexington

    Issue With Random Port Locks

    Actually the problem just went away on it's own. Not exactly sure why. Anyways thank-you for your help. Lexington
  11. Lexington

    Issue With Random Port Locks

    No, the two devices are not on the same RS485 chain. And what do you mean by output channels? Lexington
  12. Lexington

    Issue With Random Port Locks

    Hello again, I was wondering how to deal with the issue of port locking. Currently I have two devices set up each with an offset of 0.5 seconds. All channels for a given device has the same offset. Additionally there is only 40 channels thus far with 38 channels on one device and 2 on the other device. However, despite the seemingly light load on our system, DAQFactory reports a single port lock once every several hours. Is there a way to fix this? Lexington
  13. Lexington

    About Averaging

    Thank You, I figured out my problem, I was placing the script in the wrong location. I had it in the Events area instead of the Sequence area. Lexington
  14. Lexington

    About Averaging

    Hi again, So I tried the code that you suggested: privite nextTime=floor(systime()/60)*60+60 //start of next minute while(1) waituntil(nextTime) private average=mean(F7427[nextTime,nextTime-59.999]) //can't exactly be a minute average.time=nextTime F7427mm.AddValue(average) nextTime+=60 endwhile Where F7427 is the raw value and F7427mm is the minute approximation. Only problem is when I run the code, DAQFactory freezes, much like how it was the first time I tried to implement a similar code. Lexington
  15. Lexington

    About Averaging

    If the averages do need to line up with the hour, how would I do it? Or is that not possible? Lexington