Avatar

Please consider registering
guest

sp_LogInOut Log In sp_Registration Register

Register | Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed Topic RSS sp_TopicIcon
TimeStamp= NOW+3
March 23, 2015
9:26, EEST
Avatar
jura
Member
Members
Forum Posts: 16
Member Since:
March 14, 2014
sp_UserOfflineSmall Offline

HI.
When you add a tag I get the time to 3 hours more than computer time.How to fix it

March 23, 2015
10:30, EEST
Avatar
Jouni Aro
Moderator
Moderators
Forum Posts: 851
Member Since:
December 21, 2011
sp_UserOfflineSmall Offline

You must provide the timestamps in UTC timezone. Current time is available with PsUtils.UTCNow.

March 23, 2015
10:52, EEST
Avatar
jura
Member
Members
Forum Posts: 16
Member Since:
March 14, 2014
sp_UserOfflineSmall Offline

Sorry I didn’t understand how it can be used in these program code

name:=TPsString.Create(nil);
name.Value:= Info.softSettings.linkSettings.name ;
idx:= OPCserver.AddressSpace.AddVariable(ctrlIdx, name, ‘Name’);

and

var
arr: TPsFloatArray ;
HistoryData : array[0..POINT_COUNT-1] of double;

HistoryData:= ….
arr.AssignArray(HistoryData) ;

March 23, 2015
12:08, EEST
Avatar
jura
Member
Members
Forum Posts: 16
Member Since:
March 14, 2014
sp_UserOfflineSmall Offline

Current time is 14:59
stro:=TPsString.Create(nil);
stro.SetPropValueAt(vpValue, ‘tst’, vpqGood, UTCNow ) ;
in browser time is 17:59 ???

stro:=TPsString.Create(nil);
stro.SetPropValueAt(vpValue, ‘tst’, vpqGood, Now ) ;
in browser timestamp is 20:59 ???

and UTC now is 11:59 .

March 23, 2015
12:26, EEST
Avatar
jura
Member
Members
Forum Posts: 16
Member Since:
March 14, 2014
sp_UserOfflineSmall Offline

correct time is

arr.SetPropValueAt(vpValue, mas, vpqGood, UTCNow – Abs(Now-UTCNow )); Confused

March 23, 2015
14:42, EEST
Avatar
Jouni Aro
Moderator
Moderators
Forum Posts: 851
Member Since:
December 21, 2011
sp_UserOfflineSmall Offline

Which client application are you using? What is the TimeBias used?

March 24, 2015
6:09, EEST
Avatar
jura
Member
Members
Forum Posts: 16
Member Since:
March 14, 2014
sp_UserOfflineSmall Offline

MatriconOPC Explorer

March 24, 2015
8:09, EEST
Avatar
jura
Member
Members
Forum Posts: 16
Member Since:
March 14, 2014
sp_UserOfflineSmall Offline

In your Prosys OPC Test Server also time for 3 hours ahead of local time.Confused

March 24, 2015
8:37, EEST
Avatar
Jouni Aro
Moderator
Moderators
Forum Posts: 851
Member Since:
December 21, 2011
sp_UserOfflineSmall Offline

And what does our Prosys OPC Client show? The TimeBias parameter is the problematic one, which is not always interpreted or used correctly. If you check the LocalTimeBias option in Prosys OPC Client, the server will convert to the local time. This will make the client use NULL for the parameter. If the server is not supposed to convert, the client should use 0 for the TimeBias.

It feels like the client is requesting local time, but still converting the timestamps itself, too.

March 24, 2015
11:09, EEST
Avatar
jura
Member
Members
Forum Posts: 16
Member Since:
March 14, 2014
sp_UserOfflineSmall Offline

Thanks, I understood.Laugh

Forum Timezone: Europe/Helsinki

Most Users Ever Online: 267

Currently Online:
6 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

hbrackel: 103

pramanj: 86

ibrahim: 70

kapsl: 57

gjevremovic: 49

TimK: 41

Fransua33: 39

fred: 38

Rainer Versteeg: 32

Thomas Reuther: 31

Member Stats:

Guest Posters: 0

Members: 1105

Moderators: 14

Admins: 1

Forum Stats:

Groups: 3

Forums: 15

Topics: 1009

Posts: 4268

Newest Members:

user1290, gregp, mariohetheringto, normagalindo47, aurelia27u, isobel41d356980, michaeldegli, gqbdolores, kez1399, jaclynmcvay358

Moderators: Jouni Aro: 851, Otso Palonen: 32, Tuomas Hiltunen: 5, janimakela: 0, Pyry: 1, Terho: 0, Petri: 0, Bjarne Boström: 545, Heikki Tahvanainen: 402, Jukka Asikainen: 1, Teppo Uimonen: 20, Markus Johansson: 19, Matti Siponen: 53, Lusetti: 0

Administrators: admin: 0