Gamestudio Links
Zorro Links
Newest Posts
Blobsculptor tools and objects download here
by NeoDumont. 03/28/24 03:01
Issue with Multi-Core WFO Training
by aliswee. 03/24/24 20:20
Why Zorro supports up to 72 cores?
by Edgar_Herrera. 03/23/24 21:41
Zorro Trader GPT
by TipmyPip. 03/06/24 09:27
VSCode instead of SED
by 3run. 03/01/24 19:06
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
4 registered members (Nymphodora, AndrewAMD, Quad, TipmyPip), 889 guests, and 6 spiders.
Key: Admin, Global Mod, Mod
Newest Members
sakolin, rajesh7827, juergen_wue, NITRO_FOREVER, jack0roses
19043 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
new SET_PATCH=8 #477756
07/26/19 14:42
07/26/19 14:42
Joined: Jul 2017
Posts: 783
Z
Zheka Offline OP
User
Zheka  Offline OP
User
Z

Joined: Jul 2017
Posts: 783

The manual says that this new command will use Server time calculated "on the Zorro's side".

Since bar building/internal Zorro time is in UTC already (because Zorro calculates the offset to the broadcast broker time at login), then what does this new setting actually affect?

Re: new SET_PATCH=8 [Re: Zheka] #477758
07/26/19 15:05
07/26/19 15:05
Joined: Feb 2017
Posts: 1,718
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,718
Chicago
Internally and externally, both are UTC, so that's irrelevant.

Without the patch, the plugin pushes the server's time to Zorro (but only if the server's time is made available).

With the patch, the plugin outputs nothing, so Zorro uses your computer's clock time.

Re: new SET_PATCH=8 [Re: AndrewAMD] #477762
07/26/19 19:22
07/26/19 19:22
Joined: Jul 2017
Posts: 783
Z
Zheka Offline OP
User
Zheka  Offline OP
User
Z

Joined: Jul 2017
Posts: 783
Originally Posted by AndrewAMD
Without the patch, the plugin pushes the server's time to Zorro
With the patch, the plugin outputs nothing, so Zorro uses your computer's clock time.
Only at connect, to determine offset? or not only?
If MT4 broker time is UTC+3 and my computer is in UTC, then how will historical bars from MT4 be timestamped with this patch? as if they were UTC?
Originally Posted by AndrewAMD
(but only if the server's time is made available).
What will happen if MT4 does not "provide" server time? Is there a way to set/override time manually to the required one - so that it works reliably 100% of the time in a given broker-user_trading_server setup?

Re: new SET_PATCH=8 [Re: Zheka] #477764
07/26/19 19:32
07/26/19 19:32
Joined: Jul 2017
Posts: 783
Z
Zheka Offline OP
User
Zheka  Offline OP
User
Z

Joined: Jul 2017
Posts: 783
Probably, the answer to the last question is to set your computer time to the known MT4 server time and use this PATCH.

Will this work or in practice MT4 broker servers can occasionally change their times ?

Last edited by Zheka; 07/26/19 19:32.
Re: new SET_PATCH=8 [Re: Zheka] #477765
07/26/19 19:35
07/26/19 19:35
Joined: Feb 2017
Posts: 1,718
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,718
Chicago
Originally Posted by Zheka
Only at connect, to determine offset? or not only?
All the time. Zorro makes many, many calls to BrokerTime().

Originally Posted by Zheka
If MT4 broker time is UTC+3 and my computer is in UTC, then how will historical bars from MT4 be timestamped with this patch? as if they were UTC?
Ask the plugin writer - this is implementation-defined.

Originally Posted by Zheka
What will happen if MT4 does not "provide" server time? Is there a way to set/override time manually to the required one - so that it works reliably 100% of the time in a given broker-user_trading_server setup?
MT4 does provide a server time. In the event that a server does not, it's as if the patch was being used.

Re: new SET_PATCH=8 [Re: AndrewAMD] #477767
07/26/19 19:42
07/26/19 19:42
Joined: Jul 2017
Posts: 783
Z
Zheka Offline OP
User
Zheka  Offline OP
User
Z

Joined: Jul 2017
Posts: 783
Originally Posted by Zheka
Only at connect, to determine offset? or not only?
I should have asked differently: Is offset to broker time determined at login only and then applied to timestamps returned by BrokerTime?

Re: new SET_PATCH=8 [Re: Zheka] #477768
07/26/19 19:48
07/26/19 19:48
Joined: Feb 2017
Posts: 1,718
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,718
Chicago
Originally Posted by Zheka
I should have asked differently: Is offset to broker time determined at login only and then applied to timestamps returned by BrokerTime?
If there is an "offset", this depends on how the plugin writer wrote it.

As an example, I wrote the Ally Plugin. The time stamps were always in a known time zone - Eastern Time, with or without daylight savings. So I hard-coded it to correctly translate to UTC every time. This is a no-guesswork setup. I cannot comment on the MT4 setup.

Re: new SET_PATCH=8 [Re: Zheka] #477798
07/29/19 19:59
07/29/19 19:59
Joined: Jul 2017
Posts: 783
Z
Zheka Offline OP
User
Zheka  Offline OP
User
Z

Joined: Jul 2017
Posts: 783
JCL,

would you be so kind to clarify the following re MT4 plugin:

- If MT4 broker time is UTC+3 and my computer is in UTC, then - on occasions when MT4 server does not provide its time - how will historical bars from MT4 be timestamped with and without this PATCH?

- what's the recommended approach to ensure that broker time(or rather offset to broker time to UTC) is identified/set correctly 100% of the time, regardless of MT4 server lack of response?
Can there be a new variable introduced that would allow to hard-code broker-time -> UTC offset?

Thank you.

Last edited by Zheka; 07/29/19 19:59.
Re: new SET_PATCH=8 [Re: Zheka] #477805
07/30/19 07:02
07/30/19 07:02
Joined: Jul 2000
Posts: 27,977
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,977
Frankfurt
All broker plugins must deliver time stamps in UTC. No need for a variable.

Re: new SET_PATCH=8 [Re: jcl] #477807
07/30/19 08:47
07/30/19 08:47
Joined: Jul 2017
Posts: 783
Z
Zheka Offline OP
User
Zheka  Offline OP
User
Z

Joined: Jul 2017
Posts: 783
This is clear.
But I am seeking to remedy a situation when MT4 server (or MT4 plugin) fails to provide time, hence my questions.

Page 1 of 2 1 2

Moderated by  Petra 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1