BeeHay

Members
  • Posts

    32
  • Joined

  • Last visited

Everything posted by BeeHay

  1. i think we are going to hardwire another channel from the pressure-tranduscers output as "another channel5" and use it to divide/multiply on itself... also, we are looking into some labjack hardware, might throw one in the trailers and try it out!
  2. i tried your initial reply, but somehow it shows up as a solid 50, dont know where that came from... anyway, i think it's going to be a little different since we dont use counters...everything i am scaling/using math on is a very small analog voltage and the ft/min aspect is calculated by a very "old school" pressure transducer that is gravity/water fed and is set on a 96min clock, but still 60min is the mutliplier, and how ever many minutes it takes from point a to point b is the divider.... i.e. - the pressure transducer shows the pipe went down 5ft in 4 mins.... 5*60 = 300 then 300/4 = 75ft/min i have it to where i can see the bristol pin movement in DF and it is scaled properly and reads the height of the moving "kelly" in feet... the tricky part is i don't need ft/min all the time, just when it gets to a certain point then starts to calculate...the certain point is the actual size of pipe measured, say 31.27 feet....the kelly will raise the pipe, then start to push in....so when it gets to 31.27, i need it to start ft/min...then it starts all over again with a new pipe size.... the goal i am looking for is just the ft/min aspect...the whole adding a certain pipe size then starting to calc is secondary...i'll try out that hertz over time measurement.... thanks again, your information is priceless.
  3. stumped again trying to read my channel, wait 60 seconds, read the value again and then add math to it... trying to find feet per minute... i have scaled my value to read feet, but getting it to read it, wait, then read again and divide/multiply has my brain crunching! it should be simple math, correct? forcing myself to read the whole users guide and im pretty sure it has something to do with the delay() or wait() statements.... any info would be awesome.... thanks!
  4. is that a word? lol thanks again for everything
  5. oh yea, i'm looking forward to the vertical graphs in DF 6.0! would be nice to see my graphs vertical, kinda like when they are printed... also, my boss noted that moving/rotating symbols would be a "cool" feature..
  6. i guess i needed the whole item, record, and data for the code...like this - global string datain global data global record global item while (1) try datain = device.WITS.ReadUntil(10) if (strtodouble(datain) != NaN()) &= NaN()) record = strtodouble(left(datain,2)) item = strtodouble(mid(datain,2,2)) data = strtodouble(mid(datain,4,10)) endif catch() delay(0.1) endcatch endwhile thanks for that again! i'm not sure if i need .readuntil or just .read cause when i change readuntil to (1) or (100) i get an infinite loop or timeout error, but it does display until it errors out... i thought i wanted an infinite loop? this is the error - the code does work though, i am reading and displaying the data variable in a variable value component.. there is one problem though...the data coming in is this - it's reading all of those values and displaying them one at a time...all i want is the 3rd set, "7508.04", not the other values... do i need to make the code recognize the 0110 in the if statement somewhere?
  7. i threw this in a new sequence and i'm getting an uncaught error in my sequence line 4 global string datain global data while (1) datain = device.serout.ReadUntil(10) if (strtodouble(datain) != NaN()) data = strtodouble(mid(datain,4,10)) endif catch() delay(0.1) endcatch endwhile can i do something like device.serout.readuntil (999999999999) and take the catch and delay off and add datain=datain+1? also a couple of OT questions - when is DF 6.0 coming? and will there be a charge to upgrade to it? also when i run this program on an old monitor with a really low res like 800x600, i can't "scroll" through my program...i tried to add a scroll bar, and for some reason, there is no "Vertical" tick box to check... thanks again for all your help...
  8. edited! thanks again, i have to mess with the private string stuff, but the company man is happy! thanks*20-0.1
  9. my math was off in trying to move the decimal... i needed write ("0140" format("%04.4f", ch1*20-0.01) thanks again for the help, really appreceiated...
  10. i'll mess with it i dont need the item or record number...so i could just take those two out of the if statement, correct? or do i nan out the other items? something like this? put private data in the vari valu comp expression? - ignorance edit... thanks a ton... Brandon
  11. how would i move the decimal left though, i can add 2, 4, 6 ect zeros on the right, but i want something like 0.00450 instead of 450... i have tried dividing/multiplying it out, but that's a no go though cause the ch1*2000-10 is the correct math for my channel 1's final value...if i divide 1000 or multi 1000, my value is incorrect... and yes, the chr(13) chr(10) are in the incoming serial data.. sorry if i double posted this and thanks
  12. thanks! i was wondering which to look for, thought it was Format.String or toPrecision an example would be my output is being read as 400 when it should be 4.00... and my format is this device.serout.write("0140" + format("%04.1f", but i really believe it is the receiving pc..i think the scaling is wrong or something... i can monitor my device with the comm monitor and it is saying that it's Tx is 4.00, just the screen on the other pc is showing 400...i can't access the other pc's settings though..only with a call from tech support. the device i want to pull data from is transmitting a set of numbers in the same format as what i'm trying to send in... !! 01103850.00 && 01 = record number 10 = item number 3850.00 = channel value not sure on how to pull it from the set and display it. i was thinking it is device.serout.read Thanks! Brandon
  13. Can DAQFactory use toPrecision() and/or toFixed() to move decimal places in a number being output say into a text document or to a receiving pc? i can move the decimal as far as i want to going to the right, but moving to the left is giving me troubles... also, how can i take a received signal over my serial connection and display it in a varial value component? would it be device.serialin.read? the same connection you helped me out with is in this post .. may have to create the protocol? Any info will be useful! Thanks! Brandon
  14. do i have to add a button? or can i use the button that shows up to the right of the edit box when you check "set on button press"? thanks!
  15. thanks for the rotation help, i think we'll leave it horizontal until df6 as for the edit box, it just needs to take a number, i.e. 31, and when the user presses the button provided, it adds to the last entered value and is displayed in a varial value component... ie- user enters 31 into the edit box and clicks the little button... since there is no before value, 0, it displays 31 in a varial value component placed right under the edit box the user enters 30 in the edit box and presses the little button, the varial value shows now 61 just a way to keep a tally thanks
  16. just wondering if you are able to rotate the 2d graph/ or trace so it will be displayed vertical instead of horizontal? also wondering about edit box components, what do i need to make in order just to count an entered value and be displayed in a varial value component.... i have the edit box setup to "set on button press"... thanks! brandon
  17. yea, it does seem to take a long time (atleast 8-10 seconds) before the daq connects....and sometimes it takes longer and the system almost hangs when you connect it.. all in all, you have been a wonderful help and slowly but surely, i will get the hang of this stuff!!
  18. well we have another led right above it to turn green/red when we connect the daq to Daqfactory and the expression in that led is CheckConnect(DevID[0]) and the led works when it is connected or not...the button has this Quick Sequence - Connect(@devid) SetScanType(devid[0], 05) SetMultiChanScanChans(devid[0], 07) SetDataLogOptions(devid[0], 02, 00, 00) Rate =50 SendRate(devid[0], @Rate) CheckConnect(devid[0]) so i thought CheckConnect(SendDataOut) would check to see if SendDataOut is 1 or 0 and would correspond with the green/red...
  19. thanks again for the help, REALLY apprecieate it!!! here is what ended up working after a few hours of trial and error if (SendDataOut) device.serout.write("&&" + chr(13) + chr(10)) device.serout.write("0140" + format("%04.1f",ch1*2000-10) + chr(13) + chr(10)) device.serout.write("!!" + chr(13) + chr(10)) endif i guess i did need those character returns and line feeds... but for some reason i can't get the toggle button to work.. i have action channel as SendDataOut and toggle between 0 and 1... also have a little LED there and in the expression box is CheckConnect(SendDataOut) not sure if that is right, but that is not critical, the serial connection is working woooo hooooo!!! again, thanks!
  20. i can not express how much you have helped, this is great... thank you so very much, and if you have pay-pal, let me buy you lunch or a case of beer...
  21. i just found the serialguide.pdf on the website, great read
  22. our channel 2 on our daq board. where we can turn the sending data on and off with a button. not sure what you mean, but this ouput needs to be real-time. im sorry if i sound like a newb at this, but i am... our pc with daqfactory needs to send our channel value over serial to a pc sitting right next to it...everyone i have talked to is like "thats simple"...yea, for those who know how... all of our daq board readings and simple channel readings are working fine, now we just needs to send ONE channel (ch2) over serial and our bashing our heads in at this... thanks for the reply...
  23. just looking for some help in trying to send a set of data in a format like this over a null modem cable - example set - && 01404950.75 !! 01 = record number 40 = item number 4950.75 = channel value i did make a new connection through comm monitor using com1 and used the NULL protocol...im just not sure on how to make it take my ch2 and send it to the receiving pc. also would like to know how to make it on/off switchable... would a serial breakout box be good for this? so i can monitor which pins are being used? please, any info would be great.