Weather station programme.

  • Thread starter Thread starter English
  • Start date Start date
E

English

Guest
Hi - I have registered to ask help with this programme. I would like to add a pressure sensor to the programme but dont know how to go about it. If anyone understands this please get back to me and Ill go into more datail.

Heres what Ive got. This is for wind direction,speed,temprature wet and dry, relative humidity, solar radiation. Some of the parameters are not in use.

TIA Gordon.

'Prog TWS for STN35.DLP
/c/n/u/m

P15=1
P22=44
P25=64

S1=0,40,0,40 'DT
S2=0,40,0.3,40.3 'WT
'3=RH
S4=0,50,0,1000 'WS
'5=NR
S6=0,1000,0,12.98 'SR
'7=BP
'8=P
S9=0,6.266,0,241 'WD
S10=0,10,0,100 'R

BEGIN
RS10S

RA10S

1PT385(4W,S1,=1CV,W) 'DT
1-PT385(S2,=2CV,W) 'WT
1HSC(R,S4,=4CV,W) 'WS
2-V(S6,=6CV,W) 'SR
2+V(I,S9,=9CV,W) 'WD

'RH
27CV(W)=(2.75E-08*(1CV^5))+(2.73E-06*(1CV^4))+(.000271*(1CV^3))+(0.014*(1CV^2))+(0.44*1CV)+6.1
28CV(W)=(2.75E-08*(2CV^5))+(2.73E-06*(2CV^4))+(.000271*(2CV^3))+(0.014*(2CV^2))+(0.44*2CV)+6.1
3CV(W)=(28CV-(0.8*(1CV-2CV)))/27CV*100

'Hour Acc
11CV(W)=11CV+COS(9CV) ' Sum COS(WD)
12CV(W)=12CV+SIN(9CV) ' Sum SIN(WD)

RX
D(NL) T(NL) ' D&T
4CV(NL,FF1) ' WS
20CV(NL,FF0)=9CV*57.29 ' WD
6CV(NL,FF0) ' SR
5CV(NL,FF0)=-99999 ' dummy NR
1..2CV(NL,FF1) ' D&WT
3CV(NL,FF0) ' RH
7CV(NL,FF1)=-9999 ' dummy BP
20CV(NL,FF1)=0 ' dummy P
16CV(NL,FF1)=-9999 ' dummy R

RB1H
D(NR)
T(NR)

4CV(NR,FF1,AV)

22CV(W)=ATAN(12CV/11CV)*57.29
22CV(W)=22CV+((11CV>0)AND(12CV<0))*360 ' 4th quad +Cos -Sin
22CV(W)=22CV+((11CV<0)AND(12CV<0))*180 ' 3rd quad -Cos -Sin
22CV(W)=22CV+((11CV<0)AND(12CV>0))*180 ' 2nd quad -Cos +Sin
22CV(W)=22CV+((11CV>0)AND(12CV>0))*0 ' 1st quad +Cos +Sin
22CV(NR,FF0)

1..2CV(NR,FF1,AV)
3CV(NR,FF0,AV)
6CV(NR,FF0,AV)
11..12CV(W)=0

END
LOGON
G
 
How do you receive data from sensors..using MSCOMM32 via microcontroller?
 
The data is via data taker. Since posting I have found their forum and recieved a promising reply - thanks for your interest.
Gordon.
 

Users who are viewing this thread

Back
Top Bottom