Our full technical support staff does not monitor this forum. If you need assistance from a member of our staff, please submit your question from the Ask a Question page.


Log in or register to post/reply in the forum.

I want a CRBasic code for integrating a HADCP with the CR1000 in the XYZ format if possible ?


sarahh Dec 9, 2019 10:24 PM

i want to know about bins ?what dose it mean here 

i want to collect the magnitude and direction ..

can any body help me with that thank you alot 


JDavis Dec 10, 2019 03:44 PM

What make and model of HADCP are you using?

Different brands use different formats.


sarahh Dec 10, 2019 06:03 PM

thank you for replaying 

the sensor  is  Teledyne RDI Horizontal ADCP

measuring magnitude and direcion  


JDavis Dec 11, 2019 04:48 PM

Here is an example for a CR300 connected to a HADCP configured for PD23 output format. The HADCP is also configured to run on its own schedule.

 

Public CMData(13)
Alias CMData(2) = HighVolume
Alias CMData(3) = LowVolume
Alias CMData(4) = FaultCount
Alias CMData(5) = StageA
Alias CMData(6) = StageP
Alias CMData(7) = FlowRate
Alias CMData(8) = MeanVelocity
Alias CMData(9) = Area
Alias CMData(10) = Temperature
Alias CMData(11) = Pitch
Alias CMData(12) = roll
Alias CMData(13) = HADPC_Battery
Dim RawString As String * 500
Public NBytesReturned



'Main Program
BeginProg
  SerialOpen (ComRS232,9600,3,0,500) 'Change to match sensor serial configuration
  Scan (1,Sec,0,0)

    SerialInRecord (ComRS232,RawString,&h5052,0,&h0D,NBytesReturned,00)
    'Note that NBytesReturned is 0 if no data came in
    SplitStr (CMData(),RawString,",",13,4)



  NextScan
EndProg

 

I do also have an example program that reads in the full PD0 format, but it is quite large. I will email it to you.


mrtoffoli Jul 3, 2020 12:26 PM

Hello  JDavis, can you email me the code for PD0 RDI protocol? 

Log in or register to post/reply in the forum.