إنشاء روبوت تداول أوتوماتيكي للذهب XAUUSD باستراتيجية بسيطة

Tarea técnica

كيف يعمل هذا الروبوت؟

يستخدم متوسطين متحركين: سريع (Fast) وبطيء (Slow).

• شراء (Buy): عندما يقطع المتوسط السريع المتوسط البطيء نحو الأعلى.

• بيع (Sell): عندما يقطع المتوسط السريع المتوسط البطيء نحو الأسفل.

• الكود (انسخه وضعه في MetaEditor):

خطوات تشغيل الروبوت:

افتح منصة MetaTrader 5.

.

اضغط على F4 لفتح محرر MetaEditor.

.

من القائمة الجانبية، اضغط بيمين الماوس على مجلد Experts واختر New File -> Expert Advisor.

.

سمِّ الروبوت (مثلاً Gold_Bot) ثم اضغط Finish.

.

امسح الكود الموجود وضع الكود الذي كتبته لك أعلاه.

.

اضغط على زر Compile في الأعلى وتأكد من عدم وجود أخطاء (Errors).

.

عُد إلى منصة الميتا تريدر، ستجد الروبوت في نافذة Navigator تحت قسم Expert Advisors.

.

اسحب الروبوت وضعه على شارت الذهب (XAUUSD).

.

هام جداً: تأكد من تفعيل زر "Algo Trading" في أعلى المنصة ليتحول للون الأخضر.

ملاحظات ضرورية قبل البدء:

هذا الروبوت تجريبي: هو مجرد هيكل تعليمي. الذهب يحتاج إلى إضافة "إدارة مخاطر" (Stop Loss و Take Profit) و "فلتر أوقات" ليكون مربحاً.

.

الاختبار (Backtest): لا تضعه أبداً في حساب حقيقي قبل عمل "Strategy Tester" لمدة لا تقل عن 6 أشهر على بيانات تاريخية.

.

إدارة المخاطر: في حال أردت إضافة "وقف خسارة"، يمكنك تعديل دالة trade.Buy لتشمل مستويات الأسعار، وهو أمر حيوي جداً لتجنب تصفير الحساب.

//+------------------------------------------------------------------+
//|                                                Gold_Bot_Test.mq5 |
//|                                  Copyright 2023, Your Name Here  |
//+------------------------------------------------------------------+
#include <Trade\Trade.mqh>

CTrade trade;

input int FastMA = 10;      // فترة المتوسط السريع
input int SlowMA = 20;      // فترة المتوسط البطيء
input double LotSize = 0.01; // حجم الصفقة

int handleFast, handleSlow;

int OnInit() {
   handleFast = iMA(_Symbol, _Period, FastMA, 0, MODE_SMA, PRICE_CLOSE);
   handleSlow = iMA(_Symbol, _Period, SlowMA, 0, MODE_SMA, PRICE_CLOSE);
   return(INIT_SUCCEEDED);
}

void OnTick() {
   double fast[], slow[];
   CopyBuffer(handleFast, 0, 0, 2, fast);
   CopyBuffer(handleSlow, 0, 0, 2, slow);

   // منطق التقاطع:
   // تقاطع صعودي (شراء)
   if(fast[1] > slow[1] && fast[0] <= slow[0]) {
      trade.Buy(LotSize, _Symbol, SymbolInfoDouble(_Symbol, SYMBOL_ASK), 0, 0);
   }
   // تقاطع هبوطي (بيع)
   if(fast[1] < slow[1] && fast[0] >= slow[0]) {
      trade.Sell(LotSize, _Symbol, SymbolInfoDouble(_Symbol, SYMBOL_BID), 0, 0);
   }
}

Han respondido

1
Desarrollador 1
Evaluación
(19)
Proyectos
23
9%
Arbitraje
6
33% / 50%
Caducado
1
4%
Ocupado
2
Desarrollador 2
Evaluación
(22)
Proyectos
21
10%
Arbitraje
4
25% / 75%
Caducado
0
Libre
3
Desarrollador 3
Evaluación
(448)
Proyectos
710
34%
Arbitraje
34
71% / 9%
Caducado
22
3%
Libre
4
Desarrollador 4
Evaluación
(32)
Proyectos
35
34%
Arbitraje
5
0% / 80%
Caducado
0
Trabaja
Ha publicado: 2 ejemplos
5
Desarrollador 5
Evaluación
(216)
Proyectos
368
33%
Arbitraje
34
41% / 29%
Caducado
108
29%
Libre
Ha publicado: 1 ejemplo
6
Desarrollador 6
Evaluación
(60)
Proyectos
87
29%
Arbitraje
24
13% / 58%
Caducado
7
8%
Trabajando
7
Desarrollador 7
Evaluación
(104)
Proyectos
125
24%
Arbitraje
23
26% / 52%
Caducado
8
6%
Trabaja
8
Desarrollador 8
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
9
Desarrollador 9
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Trabaja
10
Desarrollador 10
Evaluación
(6)
Proyectos
5
0%
Arbitraje
3
33% / 67%
Caducado
2
40%
Libre
11
Desarrollador 11
Evaluación
(28)
Proyectos
31
45%
Arbitraje
1
100% / 0%
Caducado
3
10%
Libre
12
Desarrollador 12
Evaluación
(17)
Proyectos
19
26%
Arbitraje
0
Caducado
3
16%
Libre
13
Desarrollador 13
Evaluación
(38)
Proyectos
41
59%
Arbitraje
1
100% / 0%
Caducado
1
2%
Trabaja
Ha publicado: 5 ejemplos
14
Desarrollador 14
Evaluación
(3)
Proyectos
1
100%
Arbitraje
3
0% / 100%
Caducado
0
Libre
15
Desarrollador 15
Evaluación
(273)
Proyectos
402
27%
Arbitraje
40
40% / 50%
Caducado
1
0%
Libre
16
Desarrollador 16
Evaluación
(13)
Proyectos
20
40%
Arbitraje
3
0% / 67%
Caducado
3
15%
Libre
17
Desarrollador 17
Evaluación
(1)
Proyectos
1
0%
Arbitraje
3
0% / 100%
Caducado
1
100%
Libre
18
Desarrollador 18
Evaluación
(3)
Proyectos
3
0%
Arbitraje
0
Caducado
0
Libre
19
Desarrollador 19
Evaluación
(433)
Proyectos
633
54%
Arbitraje
32
53% / 22%
Caducado
6
1%
Trabajando
20
Desarrollador 20
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
21
Desarrollador 21
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
22
Desarrollador 22
Evaluación
(3)
Proyectos
5
20%
Arbitraje
1
100% / 0%
Caducado
2
40%
Libre
23
Desarrollador 23
Evaluación
(35)
Proyectos
53
74%
Arbitraje
4
50% / 0%
Caducado
0
Libre
24
Desarrollador 24
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
25
Desarrollador 25
Evaluación
(52)
Proyectos
58
59%
Arbitraje
4
0% / 25%
Caducado
1
2%
Libre
26
Desarrollador 26
Evaluación
Proyectos
0
0%
Arbitraje
1
0% / 100%
Caducado
0
Libre
Ha publicado: 1 ejemplo
27
Desarrollador 27
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
Solicitudes similares
I need a professional MT5 Expert Advisor (EA) built with clean, modular code. This is an advanced strategy combining liquidity concepts, controlled DCA, hedge protection, and strict risk management. Core Requirements: Entry Logic (ALL must align): Liquidity sweep (Previous Day High/Low breakout and return) EMA50 and EMA200 trend alignment Higher timeframe bias (H1 or H4) RSI confirmation Bollinger Band entry Filters
Greetings I need MT5 developer that has expertise in developing a custom indicator for mt5 boom and crash based on my exact details and requirements which would be discuss later. Kindly bid for this project if it is something you can handle for me
I need a fully functional Expert Advisor (EA) for MetaTrader 5 focused on trading XAUUSD (Gold). The strategy should be based on fast scalping entries using indicators such as RSI, Moving Averages, or similar confirmation tools. The EA must include fixed risk management (1%–2% per trade), automatic lot calculation, and stop loss/take profit settings. It should be optimized for low spread conditions and quick market
I need a professional developer to help me create an EA using RSI and Moving averages.The strategies are well organised and everything is in order. I will send all the details in the inbox
MT5 Indicator SMC 30 - 100 USD
Hello, I would like to clarify something before we proceed. I already have a base code prepared for the indicator. However, the code is not the final version and it still requires professional refinement, debugging, and optimization. Because of this, I am specifically looking for a highly experienced developer who can understand the full logic and structure of the system and improve it properly. Before I send you the
Project Overview I need assistance coding a hedging Expert Advisor (EA) that operates in "closed cycles" with a strict limit of five simultaneous open positions . EA Logic & Mechanism Initial Entry: Open a Buy position of 0.01 lots (Position A) with a Take Profit (TP) target of $1.00. Scenario 1: Price Drops (Hedging Step 1): If the price moves against the first trade, open two positions simultaneously: a Sell 0.02
Hello, I would like to clarify something before we proceed. I already have a base code prepared for the indicator. However, the code is not the final version and it still requires professional refinement, debugging, and optimization. Because of this, I am specifically looking for a highly experienced developer who can understand the full logic and structure of the system and improve it properly. Before I send you the
Powerful 30 - 100 USD
I really want a powerful developed EA that can generate a minimum of 10% every month without martingale, greed or any dangerous strategy for sale. Developer must provide the mql5 file or the raw file for modification etc
I already have a fully developed MT5 Expert Advisor with all required prop firm features, including: Risk management Daily loss & max drawdown limits Spread & slippage filters News filter Trade management system The EA structure is complete. 👉 What I need is a professional developer to replace ONLY the entry logic with a high-quality, rule-based trading strategy. 🚨 STRICT REQUIREMENT (READ CAREFULLY): I am NOT
SMC Price Action Pro 30 - 100 USD
Hello, I have a source code for an MT5 indicator that is open-source and belongs to me. However, it still requires professional improvements and some corrections. At the moment the indicator does not work as expected and there are several issues in the logic and performance that need to be fixed. Because of this, I am looking for a highly experienced MT5 developer who is comfortable working with existing code

Información sobre el proyecto

Presupuesto
30 - 80 USD