A real-time cryptocurrency trading desktop application built with C# / .NET 8 / WPF, featuring custom technical indicators, WebSocket-driven live charts, and a comprehensive risk management system.
⚠️ This is a personal project for learning and strategy validation. Use at your own risk.
Screenshots coming soon
- 5 technical indicators implemented from scratch — EMA, RSI, MACD, ATR, ADX (no external library dependencies)
- Multi-timeframe analysis (5m / 15m / 1h) with cross-validation entry signals
- Multi-symbol simultaneous monitoring scanner
- Paper trading mode for risk-free strategy validation
- Binance Futures WebSocket streaming → 100ms throttle buffer → LiveCharts2 (SkiaSharp) rendering
- 60fps candlestick charts with smooth updates
- Dark theme UI
- Dynamic position sizing based on account balance
- Trailing stop-loss with configurable parameters
- Maximum loss limit per trade / per session
- Real-time P&L tracking
- Full Binance Futures REST + WebSocket API coverage
- HMAC-SHA256 request authentication
- Auto-reconnection on WebSocket disconnection
| Layer | Technology |
|---|---|
| Language | C# 12 |
| Framework | .NET 8, WPF |
| Architecture | MVVM (CommunityToolkit.Mvvm) |
| Charts | LiveCharts2 (SkiaSharp backend) |
| API | Binance Futures REST + WebSocket |
| Auth | HMAC-SHA256 |
4-layer MVVM architecture with clear separation of concerns:
BtcTradingBot/
├── Models/ # Data models (candles, orders, positions, indicators)
├── Services/ # Business logic (API client, WebSocket, trading engine)
├── ViewModels/ # Presentation logic (MVVM bindings, commands)
├── Views/ # XAML UI (charts, dashboards, settings)
├── Collections/ # Observable collections & data structures
└── Converters/ # WPF value converters
Data Flow:
Binance WebSocket → Services (throttle + parse) → ViewModels (transform) → Views (render)
↓
Trading Engine
(indicators → signals → orders)
- .NET 8 SDK
- Binance account (for API keys, paper trading works without real funds)
git clone https://github.com/sjsr-0401/btc-trading-bot.git
cd btc-trading-bot
dotnet restore
dotnet run --project BtcTradingBot- Copy your Binance API key and secret into the settings panel
- Select trading mode: Paper (recommended) or Live
- Choose symbols to monitor and configure risk parameters
All 5 indicators are implemented at the algorithm level without external TA libraries:
- EMA — Exponential Moving Average with configurable period
- RSI — Relative Strength Index (Wilder's smoothing)
- MACD — Moving Average Convergence Divergence (signal + histogram)
- ATR — Average True Range for volatility measurement
- ADX — Average Directional Index for trend strength
Market Stream → Deserialize → Throttle Buffer (100ms) → UI Update (Dispatcher)
↓
Indicator Calculation
↓
Signal Evaluation
↓
Order Execution (if conditions met)
- Pre-trade: Position size = f(account balance, ATR, max risk %)
- In-trade: Trailing stop adjusts with price movement
- Exit: Max loss limit triggers forced liquidation
- 50+ C# source files
- 14 model classes
- 14 service classes
- 4-layer MVVM architecture
- Also includes Python prototype (
core/,gui/) used during initial development
MIT License — see LICENSE for details.
Built by Kim Seongjine — Industrial equipment software engineer exploring algorithmic trading.