dingmaotu / mt4-server

Turn MetaTrader Terminal into a Redis compatible server with ZMQ sockets
Apache License 2.0
166 stars 95 forks source link

Error on commands #3

Open ildeb opened 5 years ago

ildeb commented 5 years ago

HI, I installed the necessary packages, and started the Mt4ServerZMQ script leaving the default 6666 port. I also installed the ridis-cli client and started the connection to the above port but when I try to run a command, for example orders I get the following error:
Error: Protocol error, got "\xff" as reply type byte What am I doing wrong? The operating system is Windows server 2016 on a VPS.

dingmaotu commented 5 years ago

You may want to use Mt4ServerRaw because it uses raw tcp connection, which is the same as redis-cli. You use Mt4ServerZMQ only when you are using a zmq based client.

ildeb commented 5 years ago

Hi @dingmaotu, I confirm what you said, using Mt4ServerRaw it worked. Do you know if it is possible to use a redis client from python?

dingmaotu commented 5 years ago

It is possible, but you need to use some low level methods instead of wrapped commands (the protocol is same but the commands are different)

ildeb commented 5 years ago

Hi @dingmaotu, thanks for the reply, sorry if I still ask you a question ... how do you send the commands to set the stop loss and take profit?

ildeb commented 5 years ago

this project seems almost dead ... nobody contributes, nobody talks ..

rkahun commented 3 years ago

Hey @ildeb , picoredis works with Mt4ServerRaw.