forked from Hamhackin/espBode
-
Notifications
You must be signed in to change notification settings - Fork 0
/
esp_config.h
79 lines (62 loc) · 1.91 KB
/
esp_config.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
#ifndef _ESP_CONFIG_H_
#define _ESP_CONFIG_H_
#define FY6800 1
#define FY6900 2
#define JDS2800 3
/* Specify DEBUG output target by defining DEBUG_TO_SERIAL or DEBUG_TO_TELNET (or NONE) */
//#define DEBUG_TO_SERIAL
#define DEBUG_TO_TELNET
/* Select the target AWG from: FY6900, FY6800 or JDS2800 */
#define AWG FY6900
/* Select either AP or CLIENT mode:
- AP - creates new network that oscilloscope can connect to
- CLIENT - joins existing network
*/
//#define WIFI_MODE_AP
#define WIFI_MODE_CLIENT
/* WiFi credentials */
#define WIFI_SSID "wlan_ssid"
#define WIFI_PSK "wlan_key"
/* Comment this for DHCP. However you'll need to obtain IP somehow. */
//#define STATIC_IP
/* Static ip configuration */
#ifdef STATIC_IP
#define ESP_IP 192,168,1,6
#define ESP_MASK 255,255,255,0
#define ESP_GW 192,168,1,1
#endif
#define ID "IDN-SGLT-PRI SDG1062X\n"
#define RPC_PORT (111)
#define LXI_PORT (703)
#define PORTMAP (0x000186A0)
#define VXI_11_CORE (0x000607AF)
#define PORTMAP_GETPORT (0x00000003)
#define RPC_SINGLE_FRAG (0x80000000)
#define RPC_REPLY (0x00000001)
#define VXI_11_CREATE_LINK (10)
#define VXI_11_DESTROY_LINK (23)
#define VXI_11_DEV_WRITE (11)
#define VXI_11_DEV_READ (12)
#define RX_BUFF_SIZE (128)
// define PRINT macros
#ifndef PRINT_TO_SERIAL
#define PRINT_TO_SERIAL(TEXT) Serial.println(TEXT);
#endif
#ifndef PRINT_TO_TELNET
#define PRINT_TO_TELNET(TEXT) telnet.println(TEXT);
#endif
// define DEBUG output macro
#ifndef DEBUG
#ifdef DEBUG_TO_SERIAL
#define DEBUG(TEXT) PRINT_TO_SERIAL(TEXT)
#endif
#ifdef DEBUG_TO_TELNET
#include "ESPTelnet.h"
extern ESPTelnet telnet;
#define DEBUG(TEXT) PRINT_TO_TELNET(TEXT)
#endif
#endif
#ifndef DEBUG
#define DEBUG(TEXT)
#endif
#endif /* _ESP_CONFIG_H_ */