Lavoro terminato
![](https://c.mql5.com/i/avatar/avatar_na2.png)
![](https://c.mql5.com/i/avatar/avatar_na2.png)
Specifiche
Hello,
I am looking for conversion of an existing EA and 2 related indicators from MQL4 to MQL5. The indicators are custom RSI and MACD indicators.
Desired outcome:
As a result of our collaboration I want to have at the end:
- Functional EA for MT5
- Source code for the EA for MT5
- Indicators that are used in EA being drawn on the chart for MT5
- Source code of the indicators for MT5
Other add-ons expected from you as developer:
- Handling of simple errors
- Handling of reconnections etc….
- Your suggestions
General assumptions:
For the calculation of indicators I don't want to rely on the MT5 build in indicators. I want to have my own indicators to be programmed and drawn at the bottom (other sections below price) of the chart. The indicators I use in this EA are versions of Relative Strength Index (hereinafter RSI) and MACD (hereinafter MACD) but as I stated above I want these indicators to be programmed based on my description. All the calculations of indicators are mathematically only adding, substracting, dividing, multiplying and some simple moving averages well known from web and will be provided based on agreement.
This EA is designed for EURUSD currency pair and trades long and short.
It is working only on closed bars, i.e. entry conditions for submitting orders are evaluated at the beginning of new bar considering values of RSI and MACD for last closed bar. Entry conditions are comparison of RSI values and MACD values of previous bar(s) and comparison of RSI values and MACD values to certain trashold (e.g. below 30 or above 70 or in certain window 40 to 60 or similar).
Entry orders are limit orders based on mid-point of last bar (i.e (high+low)/2) +- PriceAdjustment or market orders depending on the actual price after conditions evaluation. Description for long (similar for short): In case the current price is below mid-point of last bar minus PriceAdjustment than EA should take long position at current price. In case current price is above mid-point of last bar minus PriceAdjustment than Limit order has to be submitted.
Stop-loss order is based on percentages of input price (e.g. if entry price is 1.18 and STP value is 2% than STP order should be submitted at 1.1564 right after the entry order is fulfilled)
Exit orders: For long position: the position is closed only after the RSI of last bar is below RSI of previous bar. For short position it is closed if the RSI is higher than RSI of previous bar
Cancellation of orders: If entry order is not fulfilled within the next bar after entry conditions were evaluated OK (i.e. practically during the bar it was submitted) entry order has to be cancelled