├── ECNIRP_Tool_OS ├── DrawInitialUI.ino ├── ECNIRP_Tool_OS.ino ├── EcnirpGitPic │ ├── 0c6d4848-dfa2-4c58-96a2-3af7f936a3a7.jpeg │ ├── 1c535c53-2db9-4742-879d-526c5b8eeffa.mp4 │ ├── 66b8e013-cf5f-4c14-a625-abe4c76bbb46.mp4 │ ├── 80c9bfeb-7831-46ca-8a3d-187b0ea4a2c6.jpeg │ ├── ae484d8f-845c-49b9-96e2-38805dcbfb37.mp4 │ ├── bbbdd466-4e67-4fbb-b165-d52df876085d.mp4 │ └── cb78ede4-6dba-4abe-b444-61fef1e054c6.jpeg ├── KeyInput.ino ├── LoadingScreen.ino ├── ML01Attacks.ino ├── NRFSubModule.ino ├── Org_01.h ├── Pin Connections.txt ├── User_Setup.h ├── updateFace.ino └── updateMessage.ino ├── LICENSE └── README.md /ECNIRP_Tool_OS/DrawInitialUI.ino: -------------------------------------------------------------------------------- 1 | #include "Org_01.h" 2 | 3 | static const unsigned char PROGMEM image_network_3_bars_bits[] = {0x00,0x0e,0x00,0x0a,0x00,0x0a,0x00,0x0a,0x00,0xea,0x00,0xea,0x00,0xea,0x00,0xea,0x0e,0xea,0x0e,0xea,0x0e,0xea,0x0e,0xea,0xee,0xea,0xee,0xea,0xee,0xee,0x00,0x00}; 4 | 5 | static const unsigned char PROGMEM image_SmallArrowUp_bits[] = {0x20,0x70,0xf8}; 6 | 7 | static const unsigned char PROGMEM image_SmallArrowDown_bits[] = {0xf8,0x70,0x20}; 8 | 9 | static const unsigned char PROGMEM image_ButtonRightSmall_bits[] = {0x80,0xc0,0xe0,0xc0,0x80}; 10 | 11 | static const unsigned char PROGMEM image_ButtonLeftSmall_bits[] = {0x20,0x60,0xe0,0x60,0x20}; 12 | 13 | static const unsigned char PROGMEM image_ButtonCenter_bits[] = {0x38,0x44,0xba,0xba,0xba,0x44,0x38}; 14 | 15 | static const unsigned char PROGMEM image_wifi_75_bits[] = {0x01,0xf0,0x00,0x06,0x0c,0x00,0x18,0x03,0x00,0x21,0xf0,0x80,0x47,0xfc,0x40,0x8f,0x1e,0x20,0x5c,0xe7,0x40,0x3b,0xfb,0x80,0x17,0x1d,0x00,0x0e,0xee,0x00,0x05,0xf4,0x00,0x03,0xb8,0x00,0x01,0x50,0x00,0x00,0xe0,0x00,0x00,0x40,0x00,0x00,0x00,0x00}; 16 | 17 | static const unsigned char PROGMEM image_download_bits[] = {0x01,0x00,0x02,0x80,0x02,0x40,0x22,0x20,0x12,0x20,0x4a,0x48,0x26,0x90,0x33,0x30,0x26,0x90,0x4a,0x48,0x12,0x20,0x22,0x20,0x02,0x40,0x02,0x80,0x01,0x00,0x00,0x00}; 18 | 19 | static const unsigned char PROGMEM image_cards_hearts_bits[] = {0x00,0x00,0x00,0x00,0x38,0x38,0x7c,0x7c,0xfe,0xfe,0xff,0xfe,0xff,0xfe,0xff,0xfe,0x7f,0xfc,0x3f,0xf8,0x1f,0xf0,0x0f,0xe0,0x07,0xc0,0x03,0x80,0x01,0x00,0x00,0x00}; 20 | 21 | static const unsigned char PROGMEM image_download_1_bits[] = {0x00,0x00,0xff,0xff,0x80,0x01,0xbf,0xfd,0xa0,0x05,0xa0,0x05,0xa0,0x05,0xa0,0x05,0xa0,0x05,0xbf,0xfd,0x80,0x01,0xff,0xff,0x03,0xc0,0x03,0xc0,0x0f,0xf0,0x00,0x00}; 22 | 23 | static const unsigned char PROGMEM image_download_3_bits[] = {0x07,0xc0,0x18,0x30,0x27,0xc8,0x48,0x24,0x93,0x92,0xa4,0x4a,0xa9,0x2a,0xa3,0x8a,0x06,0xc0,0x03,0x80,0x01,0x00,0x03,0x80,0x02,0x80,0x06,0xc0,0x04,0x40,0x00,0x00}; 24 | 25 | 26 | void drawInitial(void) { 27 | tft.fillRect(0, 0, 320, 240, 0x0); 28 | 29 | tft.drawLine(20, 33, 13, 33, 0xFFFF); 30 | 31 | tft.drawLine(20, 5, 12, 5, 0xFFFF); 32 | 33 | tft.drawLine(307, 33, 300, 33, 0xFFFF); 34 | 35 | tft.drawLine(307, 5, 300, 5, 0xFFFF); 36 | 37 | tft.drawLine(307, 6, 307, 32, 0xFFFF); 38 | 39 | tft.drawLine(12, 6, 12, 33, 0xFFFF); 40 | 41 | tft.fillRect(15, 8, 290, 23, 0xFFFF); 42 | 43 | tft.drawLine(11, 19, 5, 19, 0xFFFF); 44 | 45 | tft.drawLine(135, 229, 5, 229, 0xFFFF); 46 | 47 | tft.drawLine(5, 20, 5, 228, 0xFFFF); 48 | 49 | tft.drawLine(314, 19, 307, 19, 0xFFFF); 50 | 51 | tft.drawLine(314, 229, 184, 229, 0xFFFF); 52 | 53 | tft.setTextColor(0x0); 54 | tft.setTextSize(2); 55 | tft.setFreeFont(&Org_01); 56 | tft.drawString("ECNIRP TOOL", 95, 15); 57 | 58 | tft.drawRect(135, 223, 50, 13, 0xFFFF); 59 | 60 | tft.drawLine(314, 20, 314, 228, 0xFFFF); 61 | 62 | tft.setTextColor(0xFFFF); 63 | tft.setTextSize(1); 64 | tft.drawString("100%", 152, 227); 65 | 66 | tft.drawLine(12, 217, 124, 217, 0xFFFF); 67 | 68 | tft.drawLine(11, 217, 11, 163, 0xFFFF); 69 | 70 | tft.drawLine(124, 217, 124, 163, 0xFFFF); 71 | 72 | tft.drawLine(12, 163, 124, 163, 0xFFFF); 73 | 74 | tft.drawLine(164, 127, 130, 161, 0xFFFF); 75 | 76 | tft.drawLine(130, 217, 220, 217, 0xFFFF); 77 | 78 | tft.drawLine(164, 127, 219, 127, 0xFFFF); 79 | 80 | tft.drawLine(220, 217, 220, 127, 0xFFFF); 81 | 82 | tft.drawLine(130, 217, 130, 162, 0xFFFF); 83 | 84 | tft.drawLine(226, 217, 226, 128, 0xFFFF); 85 | 86 | tft.drawLine(226, 217, 307, 217, 0xFFFF); 87 | 88 | tft.drawLine(308, 217, 308, 128, 0xFFFF); 89 | 90 | tft.drawLine(226, 127, 308, 127, 0xFFFF); 91 | 92 | tft.drawLine(169, 121, 307, 121, 0xFFFF); 93 | 94 | tft.drawLine(308, 121, 308, 77, 0xFFFF); 95 | 96 | tft.drawLine(169, 121, 169, 77, 0xFFFF); 97 | 98 | tft.drawLine(169, 77, 307, 77, 0xFFFF); 99 | 100 | tft.drawLine(169, 71, 307, 71, 0xFFFF); 101 | 102 | tft.drawLine(169, 38, 307, 38, 0xFFFF); 103 | 104 | tft.drawLine(169, 71, 169, 38, 0xFFFF); 105 | 106 | tft.drawLine(308, 71, 308, 38, 0xFFFF); 107 | 108 | tft.setTextSize(2); 109 | tft.drawString("Archives", 173, 108); 110 | 111 | tft.drawString("Bluetooth", 15, 204); 112 | 113 | tft.drawString("Open", 15, 189); 114 | 115 | tft.drawString("2.4GHz", 134, 204); 116 | 117 | tft.drawString("1.0GHz", 231, 204); 118 | 119 | tft.drawString("Sub", 230, 191); 120 | 121 | tft.setTextSize(1); 122 | tft.drawString("ML01DP5", 180, 131); 123 | 124 | tft.drawString("CC1101", 282, 131); 125 | 126 | tft.fillEllipse(302, 211, 2, 2, 0xFFFF); 127 | 128 | tft.fillEllipse(214, 211, 2, 2, 0xFFFF); 129 | 130 | tft.fillEllipse(118, 211, 2, 2, 0xFFFF); 131 | 132 | tft.fillEllipse(302, 115, 2, 2, 0xFFFF); 133 | 134 | tft.setTextSize(1); 135 | tft.drawString("ESP32-WROOM", 57, 167); 136 | 137 | tft.drawString("File Browser", 248, 81); 138 | 139 | tft.drawBitmap(134, 172, image_network_3_bars_bits, 15, 16, 0xFFFF); 140 | 141 | tft.drawLine(11, 71, 53, 71, 0xFFFF); 142 | 143 | tft.drawLine(11, 71, 11, 38, 0xFFFF); 144 | 145 | tft.drawLine(53, 71, 53, 38, 0xFFFF); 146 | 147 | tft.drawLine(59, 38, 163, 38, 0xFFFF); 148 | 149 | tft.drawLine(59, 71, 59, 38, 0xFFFF); 150 | 151 | tft.drawLine(163, 71, 163, 38, 0xFFFF); 152 | 153 | tft.drawLine(11, 38, 53, 38, 0xFFFF); 154 | 155 | tft.drawLine(59, 71, 163, 71, 0xFFFF); 156 | 157 | tft.drawString("EXP: 100/235", 63, 63); 158 | 159 | tft.drawString("ACC: Prince", 63, 42); 160 | 161 | tft.drawString("LVL: 21", 63, 52); 162 | 163 | tft.drawBitmap(11, 223, image_SmallArrowUp_bits, 5, 3, 0xFFFF); 164 | 165 | tft.drawString("Up", 18, 222); 166 | 167 | tft.drawBitmap(33, 223, image_SmallArrowDown_bits, 5, 3, 0xFFFF); 168 | 169 | tft.drawString("Down", 40, 222); 170 | 171 | tft.drawBitmap(97, 222, image_ButtonRightSmall_bits, 3, 5, 0xFFFF); 172 | 173 | tft.drawString("Right", 102, 222); 174 | 175 | tft.drawBitmap(66, 222, image_ButtonLeftSmall_bits, 3, 5, 0xFFFF); 176 | 177 | tft.drawString("Left", 72, 222); 178 | 179 | tft.drawString("Select", 199, 222); 180 | 181 | tft.drawString("X", 232, 222); 182 | 183 | tft.drawString("Back", 239, 222); 184 | 185 | tft.drawBitmap(190, 221, image_ButtonCenter_bits, 7, 7, 0xFFFF); 186 | 187 | tft.setTextSize(2); 188 | tft.drawString("All", 134, 191); 189 | 190 | tft.drawBitmap(13, 170, image_download_bits, 14, 16, 0xFFFF); 191 | 192 | tft.drawBitmap(14, 170, image_download_bits, 14, 16, 0xFFFF); 193 | 194 | tft.drawBitmap(145, 53, image_cards_hearts_bits, 15, 16, 0xFFFF); 195 | 196 | tft.drawBitmap(173, 89, image_download_1_bits, 16, 16, 0xFFFF); 197 | 198 | tft.drawBitmap(230, 172, image_download_3_bits, 15, 16, 0xFFFF); 199 | tft.drawLine(164, 128, 130, 162, 0xFFFF); 200 | 201 | tft.setTextColor(0x7DF); 202 | tft.drawString("WiFi", 12, 134); 203 | tft.drawString("Attacks", 12, 147); 204 | tft.drawBitmap(11, 115, image_wifi_75_bits, 19, 16, 0x7DF); 205 | tft.fillEllipse(122, 154, 2, 2, 0x7DF); 206 | tft.drawLine(8, 75, 8, 159, 0x7DF); 207 | tft.drawLine(8, 160, 128, 160, 0x7DF); 208 | tft.drawLine(8, 74, 165, 74, 0x7DF); 209 | tft.drawLine(166, 74, 166, 121, 0x7DF); 210 | tft.drawLine(166, 122, 128, 160, 0x7DF); 211 | tft.drawLine(166, 121, 128, 159, 0x7DF); 212 | tft.setTextSize(1); 213 | tft.drawString("ESP32-WROOM", 99, 78); 214 | 215 | } 216 | 217 | 218 | /* 219 | 220 | HOME SCREEN DRAW CALL FUNCTION 221 | 222 | */ 223 | 224 | void drawHomeScreen(void) { 225 | tft.drawLine(8, 75, 8, 159, 0x7DF); 226 | 227 | tft.drawLine(8, 74, 165, 74, 0x7DF); 228 | 229 | tft.drawLine(166, 74, 166, 121, 0x7DF); 230 | 231 | tft.drawLine(8, 160, 128, 160, 0x7DF); 232 | 233 | tft.drawLine(166, 121, 128, 159, 0x7DF); 234 | 235 | tft.drawLine(12, 217, 124, 217, 0xFFFF); 236 | 237 | tft.drawLine(11, 217, 11, 163, 0xFFFF); 238 | 239 | tft.drawLine(124, 217, 124, 163, 0xFFFF); 240 | 241 | tft.drawLine(12, 163, 124, 163, 0xFFFF); 242 | 243 | tft.drawLine(164, 127, 130, 161, 0xFFFF); 244 | 245 | tft.drawLine(130, 217, 220, 217, 0xFFFF); 246 | 247 | tft.drawLine(164, 127, 219, 127, 0xFFFF); 248 | 249 | tft.drawLine(220, 217, 220, 127, 0xFFFF); 250 | 251 | tft.drawLine(130, 217, 130, 162, 0xFFFF); 252 | 253 | tft.drawLine(226, 217, 226, 128, 0xFFFF); 254 | 255 | tft.drawLine(226, 217, 307, 217, 0xFFFF); 256 | 257 | tft.drawLine(308, 217, 308, 128, 0xFFFF); 258 | 259 | tft.drawLine(226, 127, 308, 127, 0xFFFF); 260 | 261 | tft.drawLine(169, 121, 307, 121, 0xFFFF); 262 | 263 | tft.drawLine(308, 121, 308, 77, 0xFFFF); 264 | 265 | tft.drawLine(169, 121, 169, 77, 0xFFFF); 266 | 267 | tft.drawLine(169, 77, 307, 77, 0xFFFF); 268 | 269 | tft.setTextColor(0xFFFF); 270 | tft.setTextSize(2); 271 | tft.setFreeFont(&Org_01); 272 | tft.drawString("Archives", 173, 108); 273 | 274 | tft.drawString("Bluetooth", 15, 204); 275 | 276 | tft.drawString("Open", 15, 189); 277 | 278 | tft.drawString("2.4GHz", 134, 204); 279 | 280 | tft.drawString("1.0GHz", 231, 204); 281 | 282 | tft.drawString("Sub", 230, 191); 283 | 284 | tft.setTextSize(1); 285 | tft.drawString("ML01DP5", 180, 131); 286 | 287 | tft.drawString("CC1101", 282, 131); 288 | 289 | tft.fillEllipse(302, 211, 2, 2, 0xFFFF); 290 | 291 | tft.fillEllipse(214, 211, 2, 2, 0xFFFF); 292 | 293 | tft.fillEllipse(118, 211, 2, 2, 0xFFFF); 294 | 295 | tft.fillEllipse(302, 115, 2, 2, 0xFFFF); 296 | 297 | tft.setTextColor(0x7DF); 298 | tft.setTextSize(2); 299 | tft.drawString("WiFi", 12, 134); 300 | 301 | tft.drawString("Attacks", 12, 147); 302 | 303 | tft.setTextColor(0xFFFF); 304 | tft.setTextSize(1); 305 | tft.drawString("ESP32-WROOM", 57, 167); 306 | 307 | tft.drawString("File Browser", 248, 81); 308 | 309 | tft.setTextColor(0x7DF); 310 | tft.drawString("ESP32-WROOM", 99, 78); 311 | 312 | tft.setTextColor(0xFFFF); 313 | tft.setTextSize(2); 314 | tft.drawString("All", 134, 191); 315 | 316 | tft.fillEllipse(122, 154, 2, 2, 0x7DF); 317 | 318 | tft.drawLine(166, 122, 128, 160, 0x7DF); 319 | 320 | tft.drawLine(164, 128, 130, 162, 0xFFFF); 321 | tft.drawBitmap(11, 115, image_wifi_75_bits, 19, 16, 0x7DF); 322 | tft.drawBitmap(13, 170, image_download_bits, 14, 16, 0xFFFF); 323 | 324 | tft.drawBitmap(14, 170, image_download_bits, 14, 16, 0xFFFF); 325 | 326 | tft.drawBitmap(145, 53, image_cards_hearts_bits, 15, 16, 0xFFFF); 327 | 328 | tft.drawBitmap(173, 89, image_download_1_bits, 16, 16, 0xFFFF); 329 | 330 | tft.drawBitmap(230, 172, image_download_3_bits, 15, 16, 0xFFFF); 331 | 332 | } 333 | -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/ECNIRP_Tool_OS.ino: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | #include "esp_bt.h" 5 | #include "esp_wifi.h" 6 | 7 | TFT_eSPI tft = TFT_eSPI(); 8 | const int rowPin = 25; 9 | const int colPins[5] = {26, 27, 32, 33, 5}; // Left, Right, Up, Down 10 | int jammer = 0; 11 | extern int uiState; 12 | 13 | void setup() { 14 | Serial.begin(115200); 15 | // Disable all process 16 | esp_bt_controller_deinit(); 17 | esp_bt_controller_disable(); 18 | esp_wifi_stop(); 19 | esp_wifi_deinit(); 20 | disableNRF24(); 21 | 22 | // Initialize display 23 | tft.init(); 24 | tft.setRotation(3); // Set rotation to 1 as requested 25 | 26 | // Draw the UI 27 | drawLoading(); 28 | delay(5000); 29 | 30 | // Set up keypad pins 31 | pinMode(rowPin, OUTPUT); 32 | digitalWrite(rowPin, LOW); // Set row LOW 33 | 34 | for (int i = 0; i < 5; i++) { 35 | pinMode(colPins[i], INPUT_PULLUP); // Columns as input 36 | } 37 | 38 | drawInitial(); 39 | drawRandomFace(); 40 | printHeaderMessage(); 41 | } 42 | 43 | void loop() { 44 | // Handle user input and UI updates as needed 45 | checkButtons(); 46 | drawRandomFace(); 47 | printHeaderMessage(); 48 | 49 | //ML01 Attacks 50 | if (uiState == 4 && jammer == 0) drawNRFChannelAnalyzer(); 51 | else if (uiState == 4 && jammer == 1) hopChannelBluetooth(); 52 | else if (uiState == 4 && jammer == 2) hopChannelWifi(); 53 | else if (uiState == 4 && jammer == 3) hopChannelDrone(); 54 | else if (uiState == 4 && jammer == 4) hopChannelAll(); 55 | 56 | 57 | } -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/EcnirpGitPic/0c6d4848-dfa2-4c58-96a2-3af7f936a3a7.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mimongg/Ecnirp-Firmware/d6ba21eb0820d1fc124f34ad1dccd6f356ff97a2/ECNIRP_Tool_OS/EcnirpGitPic/0c6d4848-dfa2-4c58-96a2-3af7f936a3a7.jpeg -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/EcnirpGitPic/1c535c53-2db9-4742-879d-526c5b8eeffa.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mimongg/Ecnirp-Firmware/d6ba21eb0820d1fc124f34ad1dccd6f356ff97a2/ECNIRP_Tool_OS/EcnirpGitPic/1c535c53-2db9-4742-879d-526c5b8eeffa.mp4 -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/EcnirpGitPic/66b8e013-cf5f-4c14-a625-abe4c76bbb46.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mimongg/Ecnirp-Firmware/d6ba21eb0820d1fc124f34ad1dccd6f356ff97a2/ECNIRP_Tool_OS/EcnirpGitPic/66b8e013-cf5f-4c14-a625-abe4c76bbb46.mp4 -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/EcnirpGitPic/80c9bfeb-7831-46ca-8a3d-187b0ea4a2c6.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mimongg/Ecnirp-Firmware/d6ba21eb0820d1fc124f34ad1dccd6f356ff97a2/ECNIRP_Tool_OS/EcnirpGitPic/80c9bfeb-7831-46ca-8a3d-187b0ea4a2c6.jpeg -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/EcnirpGitPic/ae484d8f-845c-49b9-96e2-38805dcbfb37.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mimongg/Ecnirp-Firmware/d6ba21eb0820d1fc124f34ad1dccd6f356ff97a2/ECNIRP_Tool_OS/EcnirpGitPic/ae484d8f-845c-49b9-96e2-38805dcbfb37.mp4 -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/EcnirpGitPic/bbbdd466-4e67-4fbb-b165-d52df876085d.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mimongg/Ecnirp-Firmware/d6ba21eb0820d1fc124f34ad1dccd6f356ff97a2/ECNIRP_Tool_OS/EcnirpGitPic/bbbdd466-4e67-4fbb-b165-d52df876085d.mp4 -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/EcnirpGitPic/cb78ede4-6dba-4abe-b444-61fef1e054c6.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mimongg/Ecnirp-Firmware/d6ba21eb0820d1fc124f34ad1dccd6f356ff97a2/ECNIRP_Tool_OS/EcnirpGitPic/cb78ede4-6dba-4abe-b444-61fef1e054c6.jpeg -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/KeyInput.ino: -------------------------------------------------------------------------------- 1 | // Button pins 2 | const char* directions[5] = {"Up", "Down", "Right", "Left", "Select"}; 3 | 4 | unsigned long lastPressTime = 0; 5 | const int debounceDelay = 200; 6 | 7 | int yAxis = 0; 8 | int xAxis = 0; 9 | int y = 109; 10 | // Optional: variable to track current UI state 11 | int uiState = 0; 12 | extern String state; 13 | extern int mode; 14 | extern int faceDrawInterval; 15 | 16 | 17 | void checkButtons() { 18 | for (int i = 0; i < 5; i++) { 19 | if (digitalRead(colPins[i]) == LOW) { 20 | if (millis() - lastPressTime > debounceDelay) { 21 | lastPressTime = millis(); 22 | Serial.print("Pressed: "); 23 | Serial.println(directions[i]); 24 | 25 | // Handle direction 26 | if (uiState == 0) { // Home Screen 27 | handleDirectionHome(i); 28 | } 29 | 30 | else if (uiState == 1) { // Wifi Screen 31 | handleDirectionWifi(i); 32 | } 33 | 34 | else if (uiState == 3) { // Bluetooth Screen 35 | handleDirectionBluetooth(i); 36 | } 37 | 38 | else if (uiState == 4) { // ML01 Screen 39 | handleDirectionML01(i); 40 | } 41 | 42 | else if (uiState == 5){ // CC1101 Screen 43 | handleDirectionCC1101(i); 44 | } 45 | 46 | } 47 | } 48 | } 49 | } 50 | 51 | void handleDirectionML01(int dir) { 52 | // dir: 0=Up, 1=Down, 2=Right, 3=Left 53 | 54 | switch (dir) { 55 | case 0: // Up 56 | if (xAxis == 0 && yAxis > 0) { 57 | yAxis--; 58 | y = 109 + (yAxis * 20); 59 | 60 | tft.fillRect(17, y + 20, 141, 20, TFT_BLACK); 61 | tft.fillRect(17, y, 141, 20, TFT_BLACK); 62 | 63 | tft.drawLine(17, y, 21, y, TFT_WHITE); 64 | tft.drawLine(17, y + 4, 17, y, TFT_WHITE); 65 | tft.drawLine(17, y + 14, 17, y + 10, TFT_WHITE); 66 | tft.drawLine(17, y + 14, 21, y + 14, TFT_WHITE); 67 | 68 | tft.drawLine(153, y, 157, y, TFT_WHITE); 69 | tft.drawLine(157, y + 4, 157, y, TFT_WHITE); 70 | tft.drawLine(157, y + 14, 157, y + 10, TFT_WHITE); 71 | tft.drawLine(153, y + 14, 157, y + 14, TFT_WHITE); 72 | 73 | if (yAxis == 0 && xAxis == 0) { 74 | tft.drawString("Home", 23, 114); 75 | tft.drawString("Packet Sniffer", 17, 134); 76 | } 77 | if (yAxis == 1 && xAxis == 0) { 78 | tft.drawString("Packet Sniffer", 23, 134); 79 | tft.drawString("WiFi Jammer", 17, 154); 80 | } 81 | if (yAxis == 2 && xAxis == 0) { 82 | tft.drawString("WiFi Jammer", 23, 154); 83 | tft.drawString("Bluetooth Jammer", 17, 174); 84 | } 85 | } 86 | 87 | if (xAxis == 1 && yAxis > 0) { 88 | yAxis--; 89 | y = 83 + (yAxis * 20); 90 | 91 | tft.fillRect(175, y + 20, 112, 20, TFT_BLACK); 92 | tft.fillRect(175, y, 112, 20, TFT_BLACK); 93 | 94 | tft.drawLine(175, y, 179, y, TFT_WHITE); 95 | tft.drawLine(175, y + 4, 175, y, TFT_WHITE); 96 | tft.drawLine(175, y + 14, 175, y + 10, TFT_WHITE); 97 | tft.drawLine(175, y + 14, 179, y + 14, TFT_WHITE); 98 | 99 | tft.drawLine(282, y, 286, y, TFT_WHITE); 100 | tft.drawLine(286, y + 4, 286, y, TFT_WHITE); 101 | tft.drawLine(286, y + 14, 286, y + 10, TFT_WHITE); 102 | tft.drawLine(282, y + 14, 286, y + 14, TFT_WHITE); 103 | 104 | // Add text label drawing here if needed 105 | if (yAxis == 0) { 106 | tft.drawString("Drone Jammer", 181, 88); 107 | tft.drawString("Sweep Jammer", 175, 108); 108 | } 109 | if (yAxis == 1) { 110 | tft.drawString("Sweep Jammer", 181, 108); 111 | tft.drawString("Replay Attack", 175, 128); 112 | } 113 | if (yAxis == 2) { 114 | tft.drawString("Replay Attack", 181, 128); 115 | tft.drawString("Protocol Fuzzing", 175, 148); 116 | } 117 | if (yAxis == 3) { 118 | tft.drawString("Protocol Fuzzing", 181, 148); 119 | tft.drawString("Pipe Hijacking", 175, 168); 120 | } 121 | } 122 | break; 123 | 124 | case 1: // Down 125 | if (xAxis == 0 && yAxis < 3) { 126 | yAxis++; 127 | y = 109 + (yAxis * 20); 128 | 129 | tft.fillRect(17, y - 20, 141, 20, TFT_BLACK); 130 | tft.fillRect(17, y, 141, 20, TFT_BLACK); 131 | 132 | tft.drawLine(17, y, 21, y, TFT_WHITE); 133 | tft.drawLine(17, y + 4, 17, y, TFT_WHITE); 134 | tft.drawLine(17, y + 14, 17, y + 10, TFT_WHITE); 135 | tft.drawLine(17, y + 14, 21, y + 14, TFT_WHITE); 136 | 137 | tft.drawLine(153, y, 157, y, TFT_WHITE); 138 | tft.drawLine(157, y + 4, 157, y, TFT_WHITE); 139 | tft.drawLine(157, y + 14, 157, y + 10, TFT_WHITE); 140 | tft.drawLine(153, y + 14, 157, y + 14, TFT_WHITE); 141 | 142 | if (yAxis == 1 && xAxis == 0) { 143 | tft.drawString("Home", 17, 114); 144 | tft.drawString("Packet Sniffer", 23, 134); 145 | } 146 | if (yAxis == 2 && xAxis == 0) { 147 | tft.drawString("Packet Sniffer", 17, 134); 148 | tft.drawString("WiFi Jammer", 23, 154); 149 | } 150 | if (yAxis == 3 && xAxis == 0) { 151 | tft.drawString("WiFi Jammer", 17, 154); 152 | tft.drawString("Bluetooth Jammer", 23, 174); 153 | } 154 | } 155 | 156 | if (xAxis == 1 && yAxis < 4) { 157 | yAxis++; 158 | y = 83 + (yAxis * 20); 159 | 160 | tft.fillRect(175, y - 20, 112, 20, TFT_BLACK); 161 | tft.fillRect(175, y, 112, 20, TFT_BLACK); 162 | 163 | tft.drawLine(175, y, 179, y, TFT_WHITE); 164 | tft.drawLine(175, y + 4, 175, y, TFT_WHITE); 165 | tft.drawLine(175, y + 14, 175, y + 10, TFT_WHITE); 166 | tft.drawLine(175, y + 14, 179, y + 14, TFT_WHITE); 167 | 168 | tft.drawLine(282, y, 286, y, TFT_WHITE); 169 | tft.drawLine(286, y + 4, 286, y, TFT_WHITE); 170 | tft.drawLine(286, y + 14, 286, y + 10, TFT_WHITE); 171 | tft.drawLine(282, y + 14, 286, y + 14, TFT_WHITE); 172 | 173 | if (yAxis == 1) { 174 | tft.drawString("Drone Jammer", 175, 88); 175 | tft.drawString("Sweep Jammer", 181, 108); 176 | } 177 | if (yAxis == 2) { 178 | tft.drawString("Sweep Jammer", 175, 108); 179 | tft.drawString("Replay Attack", 181, 128); 180 | } 181 | if (yAxis == 3) { 182 | tft.drawString("Replay Attack", 175, 128); 183 | tft.drawString("Protocol Fuzzing", 181, 148); 184 | } 185 | if (yAxis == 4) { 186 | tft.drawString("Protocol Fuzzing", 175, 148); 187 | tft.drawString("Pipe Hijacking", 181, 168); 188 | } 189 | } 190 | break; 191 | 192 | case 2: // Right 193 | if (xAxis == 0) { 194 | int y = 109 + (yAxis * 20); 195 | tft.fillRect(17, y, 141, 20, TFT_BLACK); // Clear left box 196 | 197 | xAxis = 1; 198 | 199 | y = 83; // Right always starts at y=83 200 | tft.fillRect(175, y, 112, 20, TFT_BLACK); // Clear right box 201 | tft.drawString("Drone Jammer", 181, 88); 202 | 203 | // Draw selection box on right 204 | tft.drawLine(175, y, 179, y, 0xFFFF); 205 | tft.drawLine(175, y + 4, 175, y, 0xFFFF); 206 | tft.drawLine(175, y + 14, 175, y + 10, 0xFFFF); 207 | tft.drawLine(175, y + 14, 179, y + 14, 0xFFFF); 208 | 209 | tft.drawLine(282, y, 286, y, 0xFFFF); 210 | tft.drawLine(286, y + 4, 286, y, 0xFFFF); 211 | tft.drawLine(286, y + 14, 286, y + 10, 0xFFFF); 212 | tft.drawLine(282, y + 14, 286, y + 14, 0xFFFF); 213 | 214 | // Restore label on left 215 | if (yAxis == 0) tft.drawString("Home", 17, 114); 216 | if (yAxis == 1) tft.drawString("Packet Sniffer", 17, 134); 217 | if (yAxis == 2) tft.drawString("WiFi Jammer", 17, 154); 218 | if (yAxis == 3) tft.drawString("Bluetooth Jammer", 17, 174); 219 | 220 | yAxis = 0; // Now reset for right-side navigation 221 | } 222 | break; 223 | 224 | case 3: // Left 225 | if (xAxis == 1) { 226 | int y = 83 + (yAxis * 20); 227 | tft.fillRect(175, y, 112, 20, TFT_BLACK); // Clear right box 228 | 229 | xAxis = 0; 230 | 231 | y = 109; // Left always starts at y=109 232 | tft.fillRect(17, y, 141, 20, TFT_BLACK); // Clear left box 233 | tft.drawString("Home", 23, 114); 234 | 235 | // Draw selection box on left 236 | tft.drawLine(17, y, 21, y, 0xFFFF); 237 | tft.drawLine(17, y + 4, 17, y, 0xFFFF); 238 | tft.drawLine(17, y + 14, 17, y + 10, 0xFFFF); 239 | tft.drawLine(17, y + 14, 21, y + 14, 0xFFFF); 240 | 241 | tft.drawLine(153, y, 157, y, 0xFFFF); 242 | tft.drawLine(157, y + 4, 157, y, 0xFFFF); 243 | tft.drawLine(157, y + 14, 157, y + 10, 0xFFFF); 244 | tft.drawLine(153, y + 14, 157, y + 14, 0xFFFF); 245 | 246 | // Restore label on right 247 | if (yAxis == 0) tft.drawString("Drone Jammer", 175, 88); 248 | if (yAxis == 1) tft.drawString("Sweep Jammer", 175, 108); 249 | if (yAxis == 2) tft.drawString("Replay Attack", 175, 128); 250 | if (yAxis == 3) tft.drawString("Protocol Fuzzing", 175, 148); 251 | if (yAxis == 4) tft.drawString("Pipe Hijacking", 175, 168); 252 | 253 | yAxis = 0; // Reset after drawing 254 | } 255 | break; 256 | 257 | case 4: // Select 258 | if (yAxis == 0 && xAxis == 0) { // Go Back Home 259 | uiState = 0; 260 | yAxis = 0; 261 | xAxis = 0; 262 | deinitML01(); 263 | jammer = 0; 264 | mode = (esp_random() % 2) ? 2 : 0; 265 | clearEarsArea(); 266 | clearMainArea(); 267 | drawHomeScreen(); 268 | } 269 | 270 | else if (yAxis == 3 && xAxis == 0) { // Activate Bluetooth Jammer 271 | if (jammer == 0) { 272 | jammer = 1; 273 | drawEars(); 274 | mode = 1; 275 | startBroadcastingML01(); 276 | } 277 | 278 | else if (jammer == 1) { 279 | jammer = 0; 280 | mode = (esp_random() % 2) ? 2 : 0; 281 | clearEarsArea(); 282 | stopBroadcastingML01(); 283 | } 284 | } 285 | 286 | else if (yAxis == 2 && xAxis == 0) { // Activate Wifi Jammer 287 | if (jammer == 0) { 288 | jammer = 2; 289 | drawEars(); 290 | mode = 1; 291 | startBroadcastingML01(); 292 | } 293 | 294 | else if (jammer == 2) { 295 | jammer = 0; 296 | mode = (esp_random() % 2) ? 2 : 0; 297 | clearEarsArea(); 298 | stopBroadcastingML01(); 299 | } 300 | } 301 | 302 | else if (yAxis == 0 && xAxis == 1) { // Activate Drone Jammer 303 | if (jammer == 0) { 304 | jammer = 3; 305 | drawEars(); 306 | mode = 1; 307 | startBroadcastingML01(); 308 | } 309 | 310 | else if (jammer == 3) { 311 | jammer = 0; 312 | mode = (esp_random() % 2) ? 2 : 0; 313 | clearEarsArea(); 314 | stopBroadcastingML01(); 315 | } 316 | } 317 | 318 | else if (yAxis == 1 && xAxis == 1) { // Activate Sweep Jammer 319 | if (jammer == 0) { 320 | jammer = 4; 321 | drawEars(); 322 | mode = 1; 323 | startBroadcastingML01(); 324 | } 325 | 326 | else if (jammer == 4) { 327 | jammer = 0; 328 | mode = (esp_random() % 2) ? 2 : 0; 329 | clearEarsArea(); 330 | stopBroadcastingML01(); 331 | } 332 | } 333 | break; 334 | 335 | } 336 | } 337 | 338 | 339 | /* 340 | 341 | CC1101 SCREEN FUNCTIONS 342 | 343 | */ 344 | 345 | void handleDirectionCC1101(int dir) { 346 | // dir: 0=Up, 1=Down, 2=Right, 3=Left 347 | 348 | switch (dir) { 349 | case 0: // Up 350 | if (xAxis == 0 && yAxis > 0) { 351 | yAxis--; 352 | y = 109 + (yAxis * 20); 353 | 354 | tft.fillRect(17, y + 20, 141, 20, TFT_BLACK); 355 | tft.fillRect(17, y, 141, 20, TFT_BLACK); 356 | 357 | tft.drawLine(17, y, 21, y, TFT_WHITE); 358 | tft.drawLine(17, y + 4, 17, y, TFT_WHITE); 359 | tft.drawLine(17, y + 14, 17, y + 10, TFT_WHITE); 360 | tft.drawLine(17, y + 14, 21, y + 14, TFT_WHITE); 361 | 362 | tft.drawLine(153, y, 157, y, TFT_WHITE); 363 | tft.drawLine(157, y + 4, 157, y, TFT_WHITE); 364 | tft.drawLine(157, y + 14, 157, y + 10, TFT_WHITE); 365 | tft.drawLine(153, y + 14, 157, y + 14, TFT_WHITE); 366 | 367 | if (yAxis == 0 && xAxis == 0) { 368 | tft.drawString("Home", 23, 114); 369 | tft.drawString("Packet Sniffer", 17, 134); 370 | } 371 | if (yAxis == 1 && xAxis == 0) { 372 | tft.drawString("Packet Sniffer", 23, 134); 373 | tft.drawString("Channel Jammer", 17, 154); 374 | } 375 | if (yAxis == 2 && xAxis == 0) { 376 | tft.drawString("Channel Jammer", 23, 154); 377 | tft.drawString("State Desync", 17, 174); 378 | } 379 | } 380 | 381 | if (xAxis == 1 && yAxis > 0) { 382 | yAxis--; 383 | y = 83 + (yAxis * 20); 384 | 385 | tft.fillRect(175, y + 20, 112, 20, TFT_BLACK); 386 | tft.fillRect(175, y, 112, 20, TFT_BLACK); 387 | 388 | tft.drawLine(175, y, 179, y, TFT_WHITE); 389 | tft.drawLine(175, y + 4, 175, y, TFT_WHITE); 390 | tft.drawLine(175, y + 14, 175, y + 10, TFT_WHITE); 391 | tft.drawLine(175, y + 14, 179, y + 14, TFT_WHITE); 392 | 393 | tft.drawLine(282, y, 286, y, TFT_WHITE); 394 | tft.drawLine(286, y + 4, 286, y, TFT_WHITE); 395 | tft.drawLine(286, y + 14, 286, y + 10, TFT_WHITE); 396 | tft.drawLine(282, y + 14, 286, y + 14, TFT_WHITE); 397 | 398 | // Add text label drawing here if needed 399 | if (yAxis == 0) { 400 | tft.drawString("Rolling Jammer", 181, 88); 401 | tft.drawString("Sweep Jammer", 175, 108); 402 | } 403 | if (yAxis == 1) { 404 | tft.drawString("Sweep Jammer", 181, 108); 405 | tft.drawString("Replay Attack", 175, 128); 406 | } 407 | if (yAxis == 2) { 408 | tft.drawString("Replay Attack", 181, 128); 409 | tft.drawString("Protocol Fuzzing", 175, 148); 410 | } 411 | if (yAxis == 3) { 412 | tft.drawString("Protocol Fuzzing", 181, 148); 413 | tft.drawString("Payload Injection", 175, 168); 414 | } 415 | } 416 | break; 417 | 418 | case 1: // Down 419 | if (xAxis == 0 && yAxis < 3) { 420 | yAxis++; 421 | y = 109 + (yAxis * 20); 422 | 423 | tft.fillRect(17, y - 20, 141, 20, TFT_BLACK); 424 | tft.fillRect(17, y, 141, 20, TFT_BLACK); 425 | 426 | tft.drawLine(17, y, 21, y, TFT_WHITE); 427 | tft.drawLine(17, y + 4, 17, y, TFT_WHITE); 428 | tft.drawLine(17, y + 14, 17, y + 10, TFT_WHITE); 429 | tft.drawLine(17, y + 14, 21, y + 14, TFT_WHITE); 430 | 431 | tft.drawLine(153, y, 157, y, TFT_WHITE); 432 | tft.drawLine(157, y + 4, 157, y, TFT_WHITE); 433 | tft.drawLine(157, y + 14, 157, y + 10, TFT_WHITE); 434 | tft.drawLine(153, y + 14, 157, y + 14, TFT_WHITE); 435 | 436 | if (yAxis == 1 && xAxis == 0) { 437 | tft.drawString("Home", 17, 114); 438 | tft.drawString("Packet Sniffer", 23, 134); 439 | } 440 | if (yAxis == 2 && xAxis == 0) { 441 | tft.drawString("Packet Sniffer", 17, 134); 442 | tft.drawString("Channel Jammer", 23, 154); 443 | } 444 | if (yAxis == 3 && xAxis == 0) { 445 | tft.drawString("Channel Jammer", 17, 154); 446 | tft.drawString("State Desync", 23, 174); 447 | } 448 | } 449 | 450 | if (xAxis == 1 && yAxis < 4) { 451 | yAxis++; 452 | y = 83 + (yAxis * 20); 453 | 454 | tft.fillRect(175, y - 20, 112, 20, TFT_BLACK); 455 | tft.fillRect(175, y, 112, 20, TFT_BLACK); 456 | 457 | tft.drawLine(175, y, 179, y, TFT_WHITE); 458 | tft.drawLine(175, y + 4, 175, y, TFT_WHITE); 459 | tft.drawLine(175, y + 14, 175, y + 10, TFT_WHITE); 460 | tft.drawLine(175, y + 14, 179, y + 14, TFT_WHITE); 461 | 462 | tft.drawLine(282, y, 286, y, TFT_WHITE); 463 | tft.drawLine(286, y + 4, 286, y, TFT_WHITE); 464 | tft.drawLine(286, y + 14, 286, y + 10, TFT_WHITE); 465 | tft.drawLine(282, y + 14, 286, y + 14, TFT_WHITE); 466 | 467 | if (yAxis == 1) { 468 | tft.drawString("Rolling Jammer", 175, 88); 469 | tft.drawString("Sweep Jammer", 181, 108); 470 | } 471 | if (yAxis == 2) { 472 | tft.drawString("Sweep Jammer", 175, 108); 473 | tft.drawString("Replay Attack", 181, 128); 474 | } 475 | if (yAxis == 3) { 476 | tft.drawString("Replay Attack", 175, 128); 477 | tft.drawString("Protocol Fuzzing", 181, 148); 478 | } 479 | if (yAxis == 4) { 480 | tft.drawString("Protocol Fuzzing", 175, 148); 481 | tft.drawString("Payload Injection", 181, 168); 482 | } 483 | } 484 | break; 485 | 486 | case 2: // Right 487 | if (xAxis == 0) { 488 | int y = 109 + (yAxis * 20); 489 | tft.fillRect(17, y, 141, 20, TFT_BLACK); // Clear left box 490 | 491 | xAxis = 1; 492 | 493 | y = 83; // Right always starts at y=83 494 | tft.fillRect(175, y, 112, 20, TFT_BLACK); // Clear right box 495 | tft.drawString("Rolling Jammer", 181, 88); 496 | 497 | // Draw selection box on right 498 | tft.drawLine(175, y, 179, y, 0xFFFF); 499 | tft.drawLine(175, y + 4, 175, y, 0xFFFF); 500 | tft.drawLine(175, y + 14, 175, y + 10, 0xFFFF); 501 | tft.drawLine(175, y + 14, 179, y + 14, 0xFFFF); 502 | 503 | tft.drawLine(282, y, 286, y, 0xFFFF); 504 | tft.drawLine(286, y + 4, 286, y, 0xFFFF); 505 | tft.drawLine(286, y + 14, 286, y + 10, 0xFFFF); 506 | tft.drawLine(282, y + 14, 286, y + 14, 0xFFFF); 507 | 508 | // Restore label on left 509 | if (yAxis == 0) tft.drawString("Home", 17, 114); 510 | if (yAxis == 1) tft.drawString("Packet Sniffer", 17, 134); 511 | if (yAxis == 2) tft.drawString("Channel Jammer", 17, 154); 512 | if (yAxis == 3) tft.drawString("State Desync", 17, 174); 513 | 514 | yAxis = 0; // Now reset for right-side navigation 515 | } 516 | break; 517 | 518 | case 3: // Left 519 | if (xAxis == 1) { 520 | int y = 83 + (yAxis * 20); 521 | tft.fillRect(175, y, 112, 20, TFT_BLACK); // Clear right box 522 | 523 | xAxis = 0; 524 | 525 | y = 109; // Left always starts at y=109 526 | tft.fillRect(17, y, 141, 20, TFT_BLACK); // Clear left box 527 | tft.drawString("Home", 23, 114); 528 | 529 | // Draw selection box on left 530 | tft.drawLine(17, y, 21, y, 0xFFFF); 531 | tft.drawLine(17, y + 4, 17, y, 0xFFFF); 532 | tft.drawLine(17, y + 14, 17, y + 10, 0xFFFF); 533 | tft.drawLine(17, y + 14, 21, y + 14, 0xFFFF); 534 | 535 | tft.drawLine(153, y, 157, y, 0xFFFF); 536 | tft.drawLine(157, y + 4, 157, y, 0xFFFF); 537 | tft.drawLine(157, y + 14, 157, y + 10, 0xFFFF); 538 | tft.drawLine(153, y + 14, 157, y + 14, 0xFFFF); 539 | 540 | // Restore label on right 541 | if (yAxis == 0) tft.drawString("Rolling Jammer", 175, 88); 542 | if (yAxis == 1) tft.drawString("Sweep Jammer", 175, 108); 543 | if (yAxis == 2) tft.drawString("Replay Attack", 175, 128); 544 | if (yAxis == 3) tft.drawString("Protocol Fuzzing", 175, 148); 545 | if (yAxis == 4) tft.drawString("Payload Injection", 175, 168); 546 | 547 | yAxis = 0; // Reset after drawing 548 | } 549 | break; 550 | 551 | case 4: // Select 552 | if (yAxis == 0 && xAxis == 0) { 553 | uiState = 0; 554 | yAxis = 0; 555 | xAxis = 0; 556 | clearMainArea(); 557 | drawHomeScreen(); 558 | } 559 | break; 560 | 561 | } 562 | } 563 | 564 | 565 | 566 | /* 567 | 568 | HOME SCREEN FUNCTIONS 569 | 570 | */ 571 | 572 | void highlightWifi() { 573 | tft.setTextSize(2); 574 | tft.setTextColor(0x7DF); 575 | tft.drawString("WiFi", 12, 134); 576 | tft.drawString("Attacks", 12, 147); 577 | tft.drawBitmap(11, 115, image_wifi_75_bits, 19, 16, 0x7DF); 578 | tft.fillEllipse(122, 154, 2, 2, 0x7DF); 579 | tft.drawLine(8, 75, 8, 159, 0x7DF); 580 | tft.drawLine(8, 160, 128, 160, 0x7DF); 581 | tft.drawLine(8, 74, 165, 74, 0x7DF); 582 | tft.drawLine(166, 74, 166, 121, 0x7DF); 583 | tft.drawLine(166, 122, 128, 160, 0x7DF); 584 | tft.drawLine(166, 121, 128, 159, 0x7DF); 585 | tft.setTextSize(1); 586 | tft.drawString("ESP32-WROOM", 99, 78); 587 | } 588 | 589 | void normalWifi() { 590 | tft.setTextSize(2); 591 | tft.setTextColor(0xFFFF); 592 | tft.drawString("WiFi", 15, 131); 593 | tft.drawString("Attacks", 15, 144); 594 | tft.fillEllipse(123, 151, 2, 2, 0xFFFF); 595 | tft.drawBitmap(14, 112, image_wifi_75_bits, 19, 16, 0xFFFF); 596 | tft.drawLine(11, 77, 11, 157, 0xFFFF); 597 | tft.drawLine(12, 157, 128, 157, 0xFFFF); 598 | tft.drawLine(12, 77, 163, 77, 0xFFFF); 599 | tft.drawLine(163, 77, 163, 121, 0xFFFF); 600 | tft.drawLine(163, 122, 128, 157, 0xFFFF); 601 | tft.drawLine(163, 123, 129, 157, 0xFFFF); 602 | tft.setTextSize(1); 603 | tft.drawString("ESP32-WROOM", 96, 81); 604 | } 605 | 606 | void clearWifiArea() { 607 | // Highlight Clear 608 | tft.fillRect(12, 130, 76, 27, TFT_BLACK); 609 | tft.fillRect(96, 78, 68, 5, TFT_BLACK); 610 | tft.drawBitmap(11, 115, image_wifi_75_bits, 19, 16, 0x0); 611 | tft.fillEllipse(122, 154, 2, 2, 0x0); 612 | tft.drawLine(8, 75, 8, 159, 0x0); 613 | tft.drawLine(8, 160, 128, 160, 0x0); 614 | tft.drawLine(8, 74, 165, 74, 0x0); 615 | tft.drawLine(166, 74, 166, 121, 0x0); 616 | tft.drawLine(166, 122, 128, 160, 0x0); 617 | tft.drawLine(166, 121, 128, 159, 0x0); 618 | 619 | // Normal Clear 620 | tft.fillRect(15, 130, 76, 24, TFT_BLACK); 621 | tft.fillRect(96, 81, 65, 5, TFT_BLACK); 622 | tft.fillEllipse(123, 151, 2, 2, 0x0); 623 | tft.drawBitmap(14, 112, image_wifi_75_bits, 19, 16, 0x0); 624 | tft.drawLine(11, 77, 11, 157, 0x0); 625 | tft.drawLine(12, 157, 128, 157, 0x0); 626 | tft.drawLine(12, 77, 163, 77, 0x0); 627 | tft.drawLine(163, 77, 163, 121, 0x0); 628 | tft.drawLine(163, 122, 128, 157, 0x0); 629 | tft.drawLine(163, 123, 129, 157, 0x0); 630 | } 631 | 632 | void highlightBluetooth() { 633 | tft.setTextSize(2); 634 | tft.setTextColor(0x7DF); 635 | tft.drawString("Bluetooth", 12, 207); 636 | tft.drawString("Open", 12, 192); 637 | tft.drawBitmap(10, 173, image_download_bits, 14, 16, 0x7DF); 638 | tft.drawBitmap(11, 173, image_download_bits, 14, 16, 0x7DF); 639 | tft.fillEllipse(121, 214, 2, 2, 0x7DF); 640 | tft.drawLine(8, 160, 127, 160, 0x7DF); 641 | tft.drawLine(127, 220, 127, 161, 0x7DF); 642 | tft.drawLine(8, 220, 126, 220, 0x7DF); 643 | tft.drawLine(8, 219, 8, 161, 0x7DF); 644 | tft.setTextSize(1); 645 | tft.drawString("ESP32-WROOM", 60, 164); 646 | } 647 | 648 | void normalBluetooth() { 649 | tft.setTextSize(2); 650 | tft.setTextColor(0xFFFF); 651 | tft.drawLine(12, 163, 124, 163, 0xFFFF); 652 | tft.drawLine(11, 217, 11, 163, 0xFFFF); 653 | tft.drawLine(124, 217, 124, 163, 0xFFFF); 654 | tft.drawLine(12, 217, 124, 217, 0xFFFF); 655 | tft.drawString("Open", 15, 189); 656 | tft.drawString("Bluetooth", 15, 204); 657 | tft.fillEllipse(118, 211, 2, 2, 0xFFFF); 658 | tft.drawBitmap(13, 170, image_download_bits, 14, 16, 0xFFFF); 659 | tft.drawBitmap(14, 170, image_download_bits, 14, 16, 0xFFFF); 660 | tft.setTextSize(1); 661 | tft.drawString("ESP32-WROOM", 57, 167); 662 | } 663 | 664 | void clearBluetoothArea() { 665 | // Highlight Clear 666 | tft.fillRect(12, 189, 90, 28, TFT_BLACK); 667 | tft.fillRect(57, 164, 68, 5, TFT_BLACK); 668 | tft.drawBitmap(10, 173, image_download_bits, 14, 16, 0x0); 669 | tft.drawBitmap(11, 173, image_download_bits, 14, 16, 0x0); 670 | tft.fillEllipse(121, 214, 2, 2, 0x0); 671 | tft.drawLine(8, 160, 127, 160, 0x0); 672 | tft.drawLine(127, 220, 127, 161, 0x0); 673 | tft.drawLine(8, 220, 126, 220, 0x0); 674 | tft.drawLine(8, 219, 8, 161, 0x0); 675 | 676 | // Normal Clear 677 | tft.fillRect(15, 189, 90, 25, TFT_BLACK); 678 | tft.fillRect(57, 167, 65, 5, TFT_BLACK); 679 | tft.drawLine(12, 163, 124, 163, 0x0); 680 | tft.drawLine(11, 217, 11, 163, 0x0); 681 | tft.drawLine(124, 217, 124, 163, 0x0); 682 | tft.drawLine(12, 217, 124, 217, 0x0); 683 | tft.fillEllipse(118, 211, 2, 2, 0x0); 684 | tft.drawBitmap(13, 170, image_download_bits, 14, 16, 0x0); 685 | tft.drawBitmap(14, 170, image_download_bits, 14, 16, 0x0); 686 | } 687 | 688 | void highlightArchives() { 689 | tft.setTextSize(2); 690 | tft.setTextColor(0x7DF); 691 | tft.drawBitmap(170, 92, image_download_1_bits, 16, 16, 0x7DF); 692 | tft.drawString("Archives", 170, 111); 693 | tft.fillEllipse(305, 118, 2, 2, 0x7DF); 694 | tft.drawLine(166, 124, 166, 74, 0x7DF); 695 | tft.drawLine(167, 124, 311, 124, 0x7DF); 696 | tft.drawLine(166, 74, 311, 74, 0x7DF); 697 | tft.drawLine(311, 123, 311, 75, 0x7DF); 698 | tft.setTextSize(1); 699 | tft.drawString("File Browser", 251, 78); 700 | } 701 | 702 | void normalArchives() { 703 | tft.setTextSize(2); 704 | tft.setTextColor(0xFFFF); 705 | tft.drawBitmap(173, 89, image_download_1_bits, 16, 16, 0xFFFF); 706 | tft.drawString("Archives", 173, 108); 707 | tft.fillEllipse(302, 115, 2, 2, 0xFFFF); 708 | tft.drawLine(169, 121, 169, 77, 0xFFFF); 709 | tft.drawLine(169, 121, 307, 121, 0xFFFF); 710 | tft.drawLine(169, 77, 307, 77, 0xFFFF); 711 | tft.drawLine(308, 121, 308, 77, 0xFFFF); 712 | tft.setTextSize(1); 713 | tft.drawString("File Browser", 248, 81); 714 | } 715 | 716 | void clearArchivesArea() { 717 | // Highlight Clear 718 | tft.fillRect(167, 111, 76, 13, TFT_BLACK); 719 | tft.fillRect(251, 75, 61, 5, TFT_BLACK); 720 | tft.drawBitmap(170, 92, image_download_1_bits, 16, 16, 0x0); 721 | tft.fillEllipse(305, 118, 2, 2, 0x0); 722 | tft.drawLine(166, 124, 166, 74, 0x0); 723 | tft.drawLine(167, 124, 311, 124, 0x0); 724 | tft.drawLine(166, 74, 311, 74, 0x0); 725 | tft.drawLine(311, 123, 311, 75, 0x0); 726 | 727 | // Normal Clear 728 | tft.fillRect(172, 106, 78, 15, TFT_BLACK); 729 | tft.fillRect(248, 80, 60, 7, TFT_BLACK); 730 | tft.drawBitmap(173, 89, image_download_1_bits, 16, 16, 0x0); 731 | tft.fillEllipse(302, 115, 2, 2, 0x0); 732 | tft.drawLine(169, 121, 169, 77, 0x0); 733 | tft.drawLine(169, 121, 307, 121, 0x0); 734 | tft.drawLine(169, 77, 307, 77, 0x0); 735 | tft.drawLine(308, 121, 308, 77, 0x0); 736 | } 737 | 738 | void highlightML01() { 739 | tft.setTextSize(2); 740 | tft.setTextColor(0x7DF); 741 | tft.drawString("2.4GHz", 131, 207); 742 | tft.drawString("All", 131, 194); 743 | tft.drawBitmap(131, 175, image_network_3_bars_bits, 15, 16, 0x7DF); 744 | tft.fillEllipse(217, 214, 2, 2, 0x7DF); 745 | tft.drawLine(128, 220, 222, 220, 0x7DF); 746 | tft.drawLine(127, 220, 127, 163, 0x7DF); 747 | tft.drawLine(223, 220, 223, 124, 0x7DF); 748 | tft.drawLine(166, 124, 222, 124, 0x7DF); 749 | tft.drawLine(166, 125, 128, 163, 0x7DF); 750 | tft.drawLine(165, 125, 128, 162, 0x7DF); 751 | tft.setTextSize(1); 752 | tft.drawString("ML01DP5", 183, 128); 753 | } 754 | 755 | void normalML01() { 756 | tft.setTextSize(2); 757 | tft.setTextColor(0xFFFF); 758 | tft.drawString("All", 134, 191); 759 | tft.drawString("2.4GHz", 134, 204); 760 | tft.drawBitmap(134, 172, image_network_3_bars_bits, 15, 16, 0xFFFF); 761 | tft.fillEllipse(214, 211, 2, 2, 0xFFFF); 762 | tft.drawLine(130, 217, 220, 217, 0xFFFF); 763 | tft.drawLine(130, 217, 130, 162, 0xFFFF); 764 | tft.drawLine(220, 217, 220, 127, 0xFFFF); 765 | tft.drawLine(164, 127, 219, 127, 0xFFFF); 766 | tft.drawLine(164, 128, 130, 162, 0xFFFF); 767 | tft.drawLine(164, 127, 130, 161, 0xFFFF); 768 | tft.setTextSize(1); 769 | tft.drawString("ML01DP5", 180, 131); 770 | } 771 | 772 | void clearML01Area() { 773 | // Higlight Clear 774 | tft.fillRect(131, 191, 62, 26, TFT_BLACK); 775 | tft.fillRect(180, 128, 41, 5, TFT_BLACK); 776 | tft.drawBitmap(131, 175, image_network_3_bars_bits, 15, 16, 0x0); 777 | tft.fillEllipse(217, 214, 2, 2, 0x0); 778 | tft.drawLine(128, 220, 222, 220, 0x0); 779 | tft.drawLine(127, 220, 127, 163, 0x0); 780 | tft.drawLine(223, 220, 223, 124, 0x0); 781 | tft.drawLine(166, 124, 222, 124, 0x0); 782 | tft.drawLine(166, 125, 128, 163, 0x0); 783 | tft.drawLine(165, 125, 128, 162, 0x0); 784 | 785 | // Normal Clear 786 | tft.fillRect(134, 191, 62, 23, TFT_BLACK); 787 | tft.fillRect(180, 131, 38, 5, TFT_BLACK); 788 | tft.drawBitmap(134, 172, image_network_3_bars_bits, 15, 16, 0x0); 789 | tft.fillEllipse(214, 211, 2, 2, 0x0); 790 | tft.drawLine(130, 217, 220, 217, 0x0); 791 | tft.drawLine(130, 217, 130, 162, 0x0); 792 | tft.drawLine(220, 217, 220, 127, 0x0); 793 | tft.drawLine(164, 127, 219, 127, 0x0); 794 | tft.drawLine(164, 128, 130, 162, 0x0); 795 | tft.drawLine(164, 127, 130, 161, 0x0); 796 | } 797 | 798 | void highlightCC11() { 799 | tft.setTextSize(2); 800 | tft.setTextColor(0x7DF); 801 | tft.drawString("1.0GHz", 227, 207); 802 | tft.drawString("Sub", 227, 194); 803 | tft.drawBitmap(227, 175, image_download_3_bits, 15, 16, 0x7DF); 804 | tft.fillEllipse(305, 214, 2, 2, 0x7DF); 805 | tft.drawLine(223, 220, 310, 220, 0x7DF); 806 | tft.drawLine(223, 220, 223, 124, 0x7DF); 807 | tft.drawLine(311, 220, 311, 124, 0x7DF); 808 | tft.drawLine(224, 124, 311, 124, 0x7DF); 809 | tft.setTextSize(1); 810 | tft.drawString("CC1101", 285, 128); 811 | } 812 | 813 | void normalCC11() { 814 | tft.setTextSize(2); 815 | tft.setTextColor(0xFFFF); 816 | tft.drawString("1.0GHz", 230, 204); 817 | tft.drawString("Sub", 230, 191); 818 | tft.drawBitmap(230, 172, image_download_3_bits, 15, 16, 0xFFFF); 819 | tft.fillEllipse(302, 211, 2, 2, 0xFFFF); 820 | tft.drawLine(226, 217, 307, 217, 0xFFFF); 821 | tft.drawLine(226, 217, 226, 128, 0xFFFF); 822 | tft.drawLine(308, 217, 308, 128, 0xFFFF); 823 | tft.drawLine(226, 127, 308, 127, 0xFFFF); 824 | tft.setTextSize(1); 825 | tft.drawString("CC1101", 282, 131); 826 | } 827 | 828 | void clearCC11Area() { 829 | // Highlight Clear 830 | tft.fillRect(227, 191, 54, 26, TFT_BLACK); 831 | tft.fillRect(282, 128, 27, 5, TFT_BLACK); 832 | tft.drawBitmap(227, 175, image_download_3_bits, 15, 16, 0x0); 833 | tft.fillEllipse(305, 214, 2, 2, 0x0); 834 | tft.drawLine(223, 220, 310, 220, 0x0); 835 | tft.drawLine(223, 220, 223, 124, 0x0); 836 | tft.drawLine(311, 220, 311, 124, 0x0); 837 | tft.drawLine(224, 124, 311, 124, 0x0); 838 | 839 | // Normal Clear 840 | tft.fillRect(230, 191, 54, 23, TFT_BLACK); 841 | tft.fillRect(282, 131, 24, 5, TFT_BLACK); 842 | tft.drawBitmap(230, 172, image_download_3_bits, 15, 16, 0x0); 843 | tft.fillEllipse(302, 211, 2, 2, 0x0); 844 | tft.drawLine(226, 217, 307, 217, 0x0); 845 | tft.drawLine(226, 217, 226, 128, 0x0); 846 | tft.drawLine(308, 217, 308, 128, 0x0); 847 | tft.drawLine(226, 127, 308, 127, 0x0); 848 | } 849 | 850 | void handleDirectionHome(int dir) { 851 | 852 | switch (dir) { 853 | case 0: // Up 854 | if (yAxis == 1 && xAxis == 0) { 855 | clearBluetoothArea(); 856 | clearWifiArea(); 857 | highlightWifi(); 858 | normalBluetooth(); 859 | yAxis--; 860 | } 861 | 862 | else if (yAxis == 1 && xAxis == 1) { 863 | clearML01Area(); 864 | clearWifiArea(); 865 | normalML01(); 866 | highlightWifi(); 867 | xAxis--; 868 | yAxis--; 869 | } 870 | 871 | else if (yAxis == 1 && xAxis == 2) { 872 | clearCC11Area(); 873 | clearArchivesArea(); 874 | normalCC11(); 875 | highlightArchives(); 876 | yAxis--; 877 | xAxis--; 878 | } 879 | break; 880 | 881 | case 1: // Down 882 | if (yAxis == 0 && xAxis == 0) { 883 | clearBluetoothArea(); 884 | clearWifiArea(); 885 | normalWifi(); 886 | highlightBluetooth(); 887 | yAxis++; 888 | } 889 | 890 | else if (yAxis == 0 && xAxis == 1) { 891 | clearArchivesArea(); 892 | clearCC11Area(); 893 | normalArchives(); 894 | highlightCC11(); 895 | yAxis++; 896 | xAxis++; 897 | } 898 | break; 899 | 900 | case 2: // Right 901 | if (yAxis == 0 && xAxis == 0) { 902 | clearWifiArea(); 903 | clearArchivesArea(); 904 | normalWifi(); 905 | highlightArchives(); 906 | xAxis++; 907 | } 908 | 909 | else if (yAxis == 1 and xAxis == 0) { 910 | clearBluetoothArea(); 911 | clearML01Area(); 912 | normalBluetooth(); 913 | highlightML01(); 914 | xAxis++; 915 | } 916 | 917 | else if (yAxis == 1 && xAxis == 1) { 918 | clearML01Area(); 919 | clearCC11Area(); 920 | normalML01(); 921 | highlightCC11(); 922 | xAxis++; 923 | } 924 | break; 925 | 926 | case 3: // Left 927 | if (yAxis == 0 && xAxis == 1) { 928 | clearArchivesArea(); 929 | clearWifiArea(); 930 | highlightWifi(); 931 | normalArchives(); 932 | xAxis--; 933 | } 934 | 935 | else if (yAxis == 1 && xAxis == 1) { 936 | clearML01Area(); 937 | clearBluetoothArea(); 938 | normalML01(); 939 | highlightBluetooth(); 940 | xAxis--; 941 | } 942 | 943 | else if (yAxis == 1 && xAxis == 2) { 944 | clearCC11Area(); 945 | clearML01Area(); 946 | normalCC11(); 947 | highlightML01(); 948 | xAxis--; 949 | } 950 | break; 951 | 952 | case 4: // Select 953 | if (yAxis == 0 && xAxis == 0) { // Wifi Screen 954 | uiState = 1; 955 | yAxis = 0; 956 | xAxis = 0; 957 | clearWifiArea(); 958 | clearMainArea(); 959 | drawWifiSubModule(); 960 | } 961 | 962 | else if (yAxis == 1 && xAxis == 0) { // Bluetooth Screen 963 | uiState = 3; 964 | yAxis = 0; 965 | xAxis = 0; 966 | clearBluetoothArea(); 967 | clearMainArea(); 968 | drawBluetoothSubModule(); 969 | } 970 | 971 | else if (yAxis == 1 && xAxis == 1) { // NRF Screen 972 | uiState = 4; 973 | yAxis = 0; 974 | xAxis = 0; 975 | if (state == "Inactive") { 976 | initML01(); 977 | } 978 | clearML01Area(); 979 | clearMainArea(); 980 | drawNRFSubModule(); 981 | } 982 | 983 | else if (yAxis == 1 && xAxis == 2) { // CC11 Screen 984 | uiState = 5; 985 | yAxis = 0; 986 | xAxis = 0; 987 | clearMainArea(); 988 | clearCC11Area(); 989 | drawCC1101SubModule(); 990 | } 991 | break; 992 | } 993 | } 994 | 995 | 996 | /* 997 | 998 | WIFI SCREEN FUNCTIONS 999 | 1000 | */ 1001 | 1002 | void handleDirectionWifi(int dir) { 1003 | // dir: 0=Up, 1=Down, 2=Right, 3=Left 1004 | 1005 | switch (dir) { 1006 | case 0: // Up 1007 | if (xAxis == 0 && yAxis > 0) { 1008 | yAxis--; 1009 | y = 109 + (yAxis * 20); 1010 | 1011 | tft.fillRect(17, y + 20, 141, 20, TFT_BLACK); 1012 | tft.fillRect(17, y, 141, 20, TFT_BLACK); 1013 | 1014 | tft.drawLine(17, y, 21, y, TFT_WHITE); 1015 | tft.drawLine(17, y + 4, 17, y, TFT_WHITE); 1016 | tft.drawLine(17, y + 14, 17, y + 10, TFT_WHITE); 1017 | tft.drawLine(17, y + 14, 21, y + 14, TFT_WHITE); 1018 | 1019 | tft.drawLine(153, y, 157, y, TFT_WHITE); 1020 | tft.drawLine(157, y + 4, 157, y, TFT_WHITE); 1021 | tft.drawLine(157, y + 14, 157, y + 10, TFT_WHITE); 1022 | tft.drawLine(153, y + 14, 157, y + 14, TFT_WHITE); 1023 | 1024 | if (yAxis == 0 && xAxis == 0) { 1025 | tft.drawString("Home", 23, 114); 1026 | tft.drawString("WiFi Scanner", 17, 134); 1027 | } 1028 | if (yAxis == 1 && xAxis == 0) { 1029 | tft.drawString("WiFi Scanner", 23, 134); 1030 | tft.drawString("Deauth Selected", 17, 154); 1031 | } 1032 | if (yAxis == 2 && xAxis == 0) { 1033 | tft.drawString("Deauth Selected", 23, 154); 1034 | tft.drawString("Deauth Flood", 17, 174); 1035 | } 1036 | } 1037 | 1038 | if (xAxis == 1 && yAxis > 0) { 1039 | yAxis--; 1040 | y = 83 + (yAxis * 20); 1041 | 1042 | tft.fillRect(175, y + 20, 112, 20, TFT_BLACK); 1043 | tft.fillRect(175, y, 112, 20, TFT_BLACK); 1044 | 1045 | tft.drawLine(175, y, 179, y, TFT_WHITE); 1046 | tft.drawLine(175, y + 4, 175, y, TFT_WHITE); 1047 | tft.drawLine(175, y + 14, 175, y + 10, TFT_WHITE); 1048 | tft.drawLine(175, y + 14, 179, y + 14, TFT_WHITE); 1049 | 1050 | tft.drawLine(282, y, 286, y, TFT_WHITE); 1051 | tft.drawLine(286, y + 4, 286, y, TFT_WHITE); 1052 | tft.drawLine(286, y + 14, 286, y + 10, TFT_WHITE); 1053 | tft.drawLine(282, y + 14, 286, y + 14, TFT_WHITE); 1054 | 1055 | // Add text label drawing here if needed 1056 | if (yAxis == 0) { 1057 | tft.drawString("PMKID Attack", 181, 88); 1058 | tft.drawString("Handshake Sniffing", 175, 108); 1059 | } 1060 | if (yAxis == 1) { 1061 | tft.drawString("Handshake Sniffing", 181, 108); 1062 | tft.drawString("Rogue Portal", 175, 128); 1063 | } 1064 | if (yAxis == 2) { 1065 | tft.drawString("Rogue Portal", 181, 128); 1066 | tft.drawString("BSSID Flood", 175, 148); 1067 | } 1068 | if (yAxis == 3) { 1069 | tft.drawString("BSSID Flood", 181, 148); 1070 | tft.drawString("BSSID Clone", 175, 168); 1071 | } 1072 | } 1073 | break; 1074 | 1075 | case 1: // Down 1076 | if (xAxis == 0 && yAxis < 3) { 1077 | yAxis++; 1078 | y = 109 + (yAxis * 20); 1079 | 1080 | tft.fillRect(17, y - 20, 141, 20, TFT_BLACK); 1081 | tft.fillRect(17, y, 141, 20, TFT_BLACK); 1082 | 1083 | tft.drawLine(17, y, 21, y, TFT_WHITE); 1084 | tft.drawLine(17, y + 4, 17, y, TFT_WHITE); 1085 | tft.drawLine(17, y + 14, 17, y + 10, TFT_WHITE); 1086 | tft.drawLine(17, y + 14, 21, y + 14, TFT_WHITE); 1087 | 1088 | tft.drawLine(153, y, 157, y, TFT_WHITE); 1089 | tft.drawLine(157, y + 4, 157, y, TFT_WHITE); 1090 | tft.drawLine(157, y + 14, 157, y + 10, TFT_WHITE); 1091 | tft.drawLine(153, y + 14, 157, y + 14, TFT_WHITE); 1092 | 1093 | if (yAxis == 1 && xAxis == 0) { 1094 | tft.drawString("Home", 17, 114); 1095 | tft.drawString("WiFi Scanner", 23, 134); 1096 | } 1097 | if (yAxis == 2 && xAxis == 0) { 1098 | tft.drawString("WiFi Scanner", 17, 134); 1099 | tft.drawString("Deauth Selected", 23, 154); 1100 | } 1101 | if (yAxis == 3 && xAxis == 0) { 1102 | tft.drawString("Deauth Selected", 17, 154); 1103 | tft.drawString("Deauth Flood", 23, 174); 1104 | } 1105 | } 1106 | 1107 | if (xAxis == 1 && yAxis < 4) { 1108 | yAxis++; 1109 | y = 83 + (yAxis * 20); 1110 | 1111 | tft.fillRect(175, y - 20, 112, 20, TFT_BLACK); 1112 | tft.fillRect(175, y, 112, 20, TFT_BLACK); 1113 | 1114 | tft.drawLine(175, y, 179, y, TFT_WHITE); 1115 | tft.drawLine(175, y + 4, 175, y, TFT_WHITE); 1116 | tft.drawLine(175, y + 14, 175, y + 10, TFT_WHITE); 1117 | tft.drawLine(175, y + 14, 179, y + 14, TFT_WHITE); 1118 | 1119 | tft.drawLine(282, y, 286, y, TFT_WHITE); 1120 | tft.drawLine(286, y + 4, 286, y, TFT_WHITE); 1121 | tft.drawLine(286, y + 14, 286, y + 10, TFT_WHITE); 1122 | tft.drawLine(282, y + 14, 286, y + 14, TFT_WHITE); 1123 | 1124 | if (yAxis == 1) { 1125 | tft.drawString("PMKID Attack", 175, 88); 1126 | tft.drawString("Handshake Sniffing", 181, 108); 1127 | } 1128 | if (yAxis == 2) { 1129 | tft.drawString("Handshake Sniffing", 175, 108); 1130 | tft.drawString("Rogue Portal", 181, 128); 1131 | } 1132 | if (yAxis == 3) { 1133 | tft.drawString("Rogue Portal", 175, 128); 1134 | tft.drawString("BSSID Flood", 181, 148); 1135 | } 1136 | if (yAxis == 4) { 1137 | tft.drawString("BSSID Flood", 175, 148); 1138 | tft.drawString("BSSID Clone", 181, 168); 1139 | } 1140 | } 1141 | break; 1142 | 1143 | case 2: // Right 1144 | if (xAxis == 0) { 1145 | int y = 109 + (yAxis * 20); 1146 | tft.fillRect(17, y, 141, 20, TFT_BLACK); // Clear left box 1147 | 1148 | xAxis = 1; 1149 | 1150 | y = 83; // Right always starts at y=83 1151 | tft.fillRect(175, y, 112, 20, TFT_BLACK); // Clear right box 1152 | tft.drawString("PMKID Attack", 181, 88); 1153 | 1154 | // Draw selection box on right 1155 | tft.drawLine(175, y, 179, y, 0xFFFF); 1156 | tft.drawLine(175, y + 4, 175, y, 0xFFFF); 1157 | tft.drawLine(175, y + 14, 175, y + 10, 0xFFFF); 1158 | tft.drawLine(175, y + 14, 179, y + 14, 0xFFFF); 1159 | 1160 | tft.drawLine(282, y, 286, y, 0xFFFF); 1161 | tft.drawLine(286, y + 4, 286, y, 0xFFFF); 1162 | tft.drawLine(286, y + 14, 286, y + 10, 0xFFFF); 1163 | tft.drawLine(282, y + 14, 286, y + 14, 0xFFFF); 1164 | 1165 | // Restore label on left 1166 | if (yAxis == 0) tft.drawString("Home", 17, 114); 1167 | if (yAxis == 1) tft.drawString("WiFi Scanner", 17, 134); 1168 | if (yAxis == 2) tft.drawString("Deauth Selected", 17, 154); 1169 | if (yAxis == 3) tft.drawString("Deauth Flood", 17, 174); 1170 | 1171 | yAxis = 0; // Now reset for right-side navigation 1172 | } 1173 | break; 1174 | 1175 | case 3: // Left 1176 | if (xAxis == 1) { 1177 | int y = 83 + (yAxis * 20); 1178 | tft.fillRect(175, y, 112, 20, TFT_BLACK); // Clear right box 1179 | 1180 | xAxis = 0; 1181 | 1182 | y = 109; // Left always starts at y=109 1183 | tft.fillRect(17, y, 141, 20, TFT_BLACK); // Clear left box 1184 | tft.drawString("Home", 23, 114); 1185 | 1186 | // Draw selection box on left 1187 | tft.drawLine(17, y, 21, y, 0xFFFF); 1188 | tft.drawLine(17, y + 4, 17, y, 0xFFFF); 1189 | tft.drawLine(17, y + 14, 17, y + 10, 0xFFFF); 1190 | tft.drawLine(17, y + 14, 21, y + 14, 0xFFFF); 1191 | 1192 | tft.drawLine(153, y, 157, y, 0xFFFF); 1193 | tft.drawLine(157, y + 4, 157, y, 0xFFFF); 1194 | tft.drawLine(157, y + 14, 157, y + 10, 0xFFFF); 1195 | tft.drawLine(153, y + 14, 157, y + 14, 0xFFFF); 1196 | 1197 | // Restore label on right 1198 | if (yAxis == 0) tft.drawString("PMKID Attack", 175, 88); 1199 | if (yAxis == 1) tft.drawString("Handshake Sniffing", 175, 108); 1200 | if (yAxis == 2) tft.drawString("Rogue Portal", 175, 128); 1201 | if (yAxis == 3) tft.drawString("BSSID Flood", 175, 148); 1202 | if (yAxis == 4) tft.drawString("BSSID Clone", 175, 168); 1203 | 1204 | yAxis = 0; // Reset after drawing 1205 | } 1206 | break; 1207 | 1208 | case 4: // Select 1209 | if (yAxis == 0 && xAxis == 0) { 1210 | uiState = 0; 1211 | yAxis = 0; 1212 | xAxis = 0; 1213 | clearMainArea(); 1214 | drawHomeScreen(); 1215 | } 1216 | break; 1217 | 1218 | } 1219 | } 1220 | 1221 | /* 1222 | 1223 | BLUETOOTH SCREEN FUNCTIONS 1224 | 1225 | */ 1226 | 1227 | void handleDirectionBluetooth(int dir) { 1228 | // dir: 0=Up, 1=Down, 2=Right, 3=Left 1229 | 1230 | switch (dir) { 1231 | case 0: // Up 1232 | if (xAxis == 0 && yAxis > 0) { 1233 | yAxis--; 1234 | y = 109 + (yAxis * 20); 1235 | 1236 | tft.fillRect(17, y + 20, 141, 20, TFT_BLACK); 1237 | tft.fillRect(17, y, 141, 20, TFT_BLACK); 1238 | 1239 | tft.drawLine(17, y, 21, y, TFT_WHITE); 1240 | tft.drawLine(17, y + 4, 17, y, TFT_WHITE); 1241 | tft.drawLine(17, y + 14, 17, y + 10, TFT_WHITE); 1242 | tft.drawLine(17, y + 14, 21, y + 14, TFT_WHITE); 1243 | 1244 | tft.drawLine(153, y, 157, y, TFT_WHITE); 1245 | tft.drawLine(157, y + 4, 157, y, TFT_WHITE); 1246 | tft.drawLine(157, y + 14, 157, y + 10, TFT_WHITE); 1247 | tft.drawLine(153, y + 14, 157, y + 14, TFT_WHITE); 1248 | 1249 | if (yAxis == 0 && xAxis == 0) { 1250 | tft.drawString("Home", 23, 114); 1251 | tft.drawString("Bluetooth Scanner", 17, 134); 1252 | } 1253 | if (yAxis == 1 && xAxis == 0) { 1254 | tft.drawString("Bluetooth Scanner", 23, 134); 1255 | tft.drawString("Beacon Spamming", 17, 154); 1256 | } 1257 | if (yAxis == 2 && xAxis == 0) { 1258 | tft.drawString("Beacon Spamming", 23, 154); 1259 | tft.drawString("Device Impersonation", 17, 174); 1260 | } 1261 | } 1262 | 1263 | if (xAxis == 1 && yAxis > 0) { 1264 | yAxis--; 1265 | y = 83 + (yAxis * 20); 1266 | 1267 | tft.fillRect(175, y + 20, 112, 20, TFT_BLACK); 1268 | tft.fillRect(175, y, 112, 20, TFT_BLACK); 1269 | 1270 | tft.drawLine(175, y, 179, y, TFT_WHITE); 1271 | tft.drawLine(175, y + 4, 175, y, TFT_WHITE); 1272 | tft.drawLine(175, y + 14, 175, y + 10, TFT_WHITE); 1273 | tft.drawLine(175, y + 14, 179, y + 14, TFT_WHITE); 1274 | 1275 | tft.drawLine(282, y, 286, y, TFT_WHITE); 1276 | tft.drawLine(286, y + 4, 286, y, TFT_WHITE); 1277 | tft.drawLine(286, y + 14, 286, y + 10, TFT_WHITE); 1278 | tft.drawLine(282, y + 14, 286, y + 14, TFT_WHITE); 1279 | 1280 | // Add text label drawing here if needed 1281 | if (yAxis == 0) { 1282 | tft.drawString("Denial Of Service", 181, 88); 1283 | tft.drawString("Popup Trigger", 175, 108); 1284 | } 1285 | if (yAxis == 1) { 1286 | tft.drawString("Popup Trigger", 181, 108); 1287 | tft.drawString("Profile Poisoning", 175, 128); 1288 | } 1289 | if (yAxis == 2) { 1290 | tft.drawString("Profile Poisoning", 181, 128); 1291 | tft.drawString("HID Injection", 175, 148); 1292 | } 1293 | if (yAxis == 3) { 1294 | tft.drawString("HID Injection", 181, 148); 1295 | tft.drawString("Firmware Bomb", 175, 168); 1296 | } 1297 | } 1298 | break; 1299 | 1300 | case 1: // Down 1301 | if (xAxis == 0 && yAxis < 3) { 1302 | yAxis++; 1303 | y = 109 + (yAxis * 20); 1304 | 1305 | tft.fillRect(17, y - 20, 141, 20, TFT_BLACK); 1306 | tft.fillRect(17, y, 141, 20, TFT_BLACK); 1307 | 1308 | tft.drawLine(17, y, 21, y, TFT_WHITE); 1309 | tft.drawLine(17, y + 4, 17, y, TFT_WHITE); 1310 | tft.drawLine(17, y + 14, 17, y + 10, TFT_WHITE); 1311 | tft.drawLine(17, y + 14, 21, y + 14, TFT_WHITE); 1312 | 1313 | tft.drawLine(153, y, 157, y, TFT_WHITE); 1314 | tft.drawLine(157, y + 4, 157, y, TFT_WHITE); 1315 | tft.drawLine(157, y + 14, 157, y + 10, TFT_WHITE); 1316 | tft.drawLine(153, y + 14, 157, y + 14, TFT_WHITE); 1317 | 1318 | if (yAxis == 1 && xAxis == 0) { 1319 | tft.drawString("Home", 17, 114); 1320 | tft.drawString("Bluetooth Scanner", 23, 134); 1321 | } 1322 | if (yAxis == 2 && xAxis == 0) { 1323 | tft.drawString("Bluetoot Scanner", 17, 134); 1324 | tft.drawString("Beacon Spamming", 23, 154); 1325 | } 1326 | if (yAxis == 3 && xAxis == 0) { 1327 | tft.drawString("Beacon Spamming", 17, 154); 1328 | tft.drawString("Device Impersonation", 23, 174); 1329 | } 1330 | } 1331 | 1332 | if (xAxis == 1 && yAxis < 4) { 1333 | yAxis++; 1334 | y = 83 + (yAxis * 20); 1335 | 1336 | tft.fillRect(175, y - 20, 112, 20, TFT_BLACK); 1337 | tft.fillRect(175, y, 112, 20, TFT_BLACK); 1338 | 1339 | tft.drawLine(175, y, 179, y, TFT_WHITE); 1340 | tft.drawLine(175, y + 4, 175, y, TFT_WHITE); 1341 | tft.drawLine(175, y + 14, 175, y + 10, TFT_WHITE); 1342 | tft.drawLine(175, y + 14, 179, y + 14, TFT_WHITE); 1343 | 1344 | tft.drawLine(282, y, 286, y, TFT_WHITE); 1345 | tft.drawLine(286, y + 4, 286, y, TFT_WHITE); 1346 | tft.drawLine(286, y + 14, 286, y + 10, TFT_WHITE); 1347 | tft.drawLine(282, y + 14, 286, y + 14, TFT_WHITE); 1348 | 1349 | if (yAxis == 1) { 1350 | tft.drawString("Denial Of Service", 175, 88); 1351 | tft.drawString("Popup Trigger", 181, 108); 1352 | } 1353 | if (yAxis == 2) { 1354 | tft.drawString("Popup Trigger", 175, 108); 1355 | tft.drawString("Profile Poisoning", 181, 128); 1356 | } 1357 | if (yAxis == 3) { 1358 | tft.drawString("Profile Poisoning", 175, 128); 1359 | tft.drawString("HID Injection", 181, 148); 1360 | } 1361 | if (yAxis == 4) { 1362 | tft.drawString("HID Injection", 175, 148); 1363 | tft.drawString("Firmware Bomb", 181, 168); 1364 | } 1365 | } 1366 | break; 1367 | 1368 | case 2: // Right 1369 | if (xAxis == 0) { 1370 | int y = 109 + (yAxis * 20); 1371 | tft.fillRect(17, y, 141, 20, TFT_BLACK); // Clear left box 1372 | 1373 | xAxis = 1; 1374 | 1375 | y = 83; // Right always starts at y=83 1376 | tft.fillRect(175, y, 112, 20, TFT_BLACK); // Clear right box 1377 | tft.drawString("Denial Of Service", 181, 88); 1378 | 1379 | // Draw selection box on right 1380 | tft.drawLine(175, y, 179, y, 0xFFFF); 1381 | tft.drawLine(175, y + 4, 175, y, 0xFFFF); 1382 | tft.drawLine(175, y + 14, 175, y + 10, 0xFFFF); 1383 | tft.drawLine(175, y + 14, 179, y + 14, 0xFFFF); 1384 | 1385 | tft.drawLine(282, y, 286, y, 0xFFFF); 1386 | tft.drawLine(286, y + 4, 286, y, 0xFFFF); 1387 | tft.drawLine(286, y + 14, 286, y + 10, 0xFFFF); 1388 | tft.drawLine(282, y + 14, 286, y + 14, 0xFFFF); 1389 | 1390 | // Restore label on left 1391 | if (yAxis == 0) tft.drawString("Home", 17, 114); 1392 | if (yAxis == 1) tft.drawString("Bluetooth Scanner", 17, 134); 1393 | if (yAxis == 2) tft.drawString("Beacon Spamming", 17, 154); 1394 | if (yAxis == 3) tft.drawString("Device Impersonation", 17, 174); 1395 | 1396 | yAxis = 0; // Now reset for right-side navigation 1397 | } 1398 | break; 1399 | 1400 | case 3: // Left 1401 | if (xAxis == 1) { 1402 | int y = 83 + (yAxis * 20); 1403 | tft.fillRect(175, y, 112, 20, TFT_BLACK); // Clear right box 1404 | 1405 | xAxis = 0; 1406 | 1407 | y = 109; // Left always starts at y=109 1408 | tft.fillRect(17, y, 141, 20, TFT_BLACK); // Clear left box 1409 | tft.drawString("Home", 23, 114); 1410 | 1411 | // Draw selection box on left 1412 | tft.drawLine(17, y, 21, y, 0xFFFF); 1413 | tft.drawLine(17, y + 4, 17, y, 0xFFFF); 1414 | tft.drawLine(17, y + 14, 17, y + 10, 0xFFFF); 1415 | tft.drawLine(17, y + 14, 21, y + 14, 0xFFFF); 1416 | 1417 | tft.drawLine(153, y, 157, y, 0xFFFF); 1418 | tft.drawLine(157, y + 4, 157, y, 0xFFFF); 1419 | tft.drawLine(157, y + 14, 157, y + 10, 0xFFFF); 1420 | tft.drawLine(153, y + 14, 157, y + 14, 0xFFFF); 1421 | 1422 | // Restore label on right 1423 | if (yAxis == 0) tft.drawString("Denial Of Service", 175, 88); 1424 | if (yAxis == 1) tft.drawString("Popup Trigger", 175, 108); 1425 | if (yAxis == 2) tft.drawString("Profile Poisoning", 175, 128); 1426 | if (yAxis == 3) tft.drawString("HID Injection", 175, 148); 1427 | if (yAxis == 4) tft.drawString("Firware Bomb", 175, 168); 1428 | 1429 | yAxis = 0; // Reset after drawing 1430 | } 1431 | break; 1432 | 1433 | case 4: // Select 1434 | if (yAxis == 0 && xAxis == 0) { 1435 | uiState = 0; 1436 | yAxis = 0; 1437 | xAxis = 0; 1438 | clearMainArea(); 1439 | drawHomeScreen(); 1440 | } 1441 | break; 1442 | 1443 | } 1444 | } -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/LoadingScreen.ino: -------------------------------------------------------------------------------- 1 | static const unsigned char PROGMEM image_download_bits_load[] = {0xfc,0x7f,0x8f,0xc0,0x00,0x3c,0x00,0x07,0x80,0x00,0x00,0x3f,0x80,0xfc,0x7f,0x8f,0xc0,0x00,0xfc,0x00,0x1f,0x80,0x1f,0xf0,0xff,0xe0,0xfc,0x73,0x8f,0xc0,0x03,0xfc,0x00,0x7f,0x80,0x1f,0xe3,0xc0,0x78,0xe0,0x73,0x8e,0x00,0x07,0xe0,0x00,0xfc,0x00,0x18,0x07,0x00,0x1c,0xe0,0x73,0x8e,0x00,0x0f,0x80,0x01,0xf0,0x00,0x18,0x0e,0x00,0x0e,0xe0,0x73,0x8e,0x00,0x1e,0x00,0x03,0xc0,0x00,0x18,0x0c,0x1f,0x00,0xe0,0x73,0x8e,0x00,0x1c,0x00,0x03,0x80,0x00,0x18,0x18,0x7f,0xc0,0xe0,0x73,0x8e,0x00,0x3c,0x00,0x07,0x80,0x00,0x18,0x18,0xe0,0xe0,0xe0,0x73,0x8e,0x00,0x38,0x00,0x07,0x00,0x00,0x18,0x30,0xc0,0x40,0xe0,0x73,0x8e,0x00,0x38,0x00,0x07,0x00,0x00,0x18,0x31,0x80,0x00,0xfc,0x7f,0x8e,0x00,0x38,0x00,0x07,0xfe,0x00,0x1f,0xf1,0x80,0x00,0xfc,0x7f,0x8e,0x00,0x38,0x00,0x07,0xfe,0x00,0x1f,0xf1,0x80,0x00,0xfc,0x7f,0x8e,0x00,0x38,0x00,0x07,0xfe,0x00,0x18,0x31,0x80,0x00,0xe0,0x73,0x8e,0x00,0x38,0x00,0x07,0x00,0x00,0x18,0x31,0x80,0x00,0xe0,0x73,0x8e,0x00,0x38,0x00,0x07,0x00,0x00,0x18,0x30,0xc0,0x40,0xe0,0x73,0x8e,0x00,0x3c,0x00,0x07,0x80,0x00,0x18,0x18,0xe0,0xe0,0xe0,0x73,0x8e,0x00,0x1c,0x00,0x03,0x80,0x00,0x18,0x18,0x7f,0xc0,0xe0,0x73,0x8e,0x00,0x1e,0x00,0x03,0xc0,0x00,0x18,0x0c,0x1f,0x06,0xe0,0x73,0x8e,0x00,0x0f,0x80,0x01,0xf0,0x00,0x18,0x0e,0x00,0x0e,0xe0,0x73,0x8e,0x00,0x07,0xe0,0x00,0xfc,0x00,0x18,0x07,0x00,0x1c,0xfc,0x73,0x8f,0xc0,0x03,0xfc,0x00,0x7f,0x80,0x18,0x03,0xc0,0x78,0xfc,0x73,0x8f,0xc0,0x00,0xfc,0x00,0x1f,0x80,0x10,0x00,0xff,0xe0,0xfc,0x73,0x8f,0xc0,0x00,0x3c,0x00,0x07,0x80,0x00,0x00,0x3f,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x33,0x07,0x00,0x80,0x00,0x02,0x00,0x00,0x07,0x00,0x00,0x00,0x30,0x33,0x0e,0x00,0x41,0xff,0x04,0x00,0x00,0x0f,0x80,0x00,0x00,0x30,0x33,0x3c,0x00,0x26,0x00,0xc8,0x00,0x00,0x1f,0xc0,0x00,0x00,0x30,0x33,0x70,0x00,0x18,0x00,0x30,0x00,0x00,0x38,0xe0,0x00,0x00,0x30,0x33,0xe0,0x00,0x0f,0xff,0xe0,0x00,0x00,0x30,0x60,0x00,0x00,0x30,0x33,0xe0,0x00,0x04,0x00,0x40,0x00,0x00,0x70,0x70,0x00,0x00,0x30,0x33,0x70,0x00,0x06,0x00,0xc0,0x00,0x00,0xe0,0x38,0x00,0x00,0x30,0x33,0x3c,0x00,0x05,0x01,0x40,0x00,0x01,0xcf,0x9c,0x00,0x00,0x3f,0xf3,0x0e,0x00,0x04,0xbe,0x40,0x00,0x01,0x90,0x4c,0x00,0x00,0x1f,0xe3,0x07,0x00,0x04,0x44,0x40,0x00,0x03,0xa0,0x0e,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x28,0x80,0x00,0x07,0x40,0x17,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x10,0x80,0x00,0x0e,0x80,0x2b,0x80,0x00,0x1f,0xf1,0xfe,0x00,0x02,0x28,0x80,0x00,0x0c,0x88,0x49,0x80,0x00,0x3f,0xf3,0xff,0x00,0x02,0x44,0x80,0x00,0x1c,0x88,0x89,0xc0,0x00,0x30,0x03,0x03,0x00,0x02,0x82,0x80,0x00,0x38,0x85,0x08,0xe0,0x00,0x30,0x03,0x03,0x00,0x01,0x01,0x00,0x00,0x70,0x86,0x08,0x70,0x00,0x30,0x03,0x03,0x00,0x03,0x01,0x80,0x00,0x60,0x40,0x10,0x30,0x00,0x30,0x03,0xff,0x00,0x05,0x03,0xc0,0x00,0xe0,0x20,0x20,0x38,0x00,0x30,0x03,0xff,0x00,0x09,0x04,0x60,0x01,0xc0,0x10,0x40,0x1c,0x00,0x30,0x03,0x03,0x00,0x11,0x05,0x50,0x01,0x80,0x0f,0x80,0x0c,0x00,0x3f,0xf3,0x03,0x00,0x20,0xfc,0x48,0x01,0xc0,0x00,0x00,0x1c,0x00,0x1f,0xf3,0x03,0x00,0x40,0x03,0x84,0x00,0xff,0xff,0xff,0xf8,0x00,0x00,0x00,0x00,0x00,0x80,0x00,0x02,0x00,0x7f,0xff,0xff,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3f,0xff,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3f,0xff,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3f,0xff,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3f,0xff,0xf8,0x00,0x00,0x00,0x00,0x00}; 2 | 3 | 4 | void drawLoading(void) { 5 | tft.fillRect(0, 0, 320, 240, 0x0); 6 | 7 | tft.setTextColor(0xFFFF); 8 | tft.setTextSize(2); 9 | tft.setFreeFont(&Org_01); 10 | tft.drawString("BOOTING UP", 100, 37); 11 | 12 | tft.drawBitmap(108, 181, image_download_bits_load, 103, 56, 0xFFFF); 13 | 14 | tft.setTextSize(1); 15 | tft.drawString("⚠️ Disclaimer: This software comes with absolutely no", 35, 64); 16 | 17 | tft.drawRect(28, 53, 265, 110, 0xFFFF); 18 | 19 | tft.drawString("guarantee - except for one: something will probably", 36, 76); 20 | 21 | tft.drawString("go wrong. X O X", 120, 89); 22 | 23 | tft.drawString("Ah, a brave Ecnirpian has arived. Welcome aboard!", 43, 114); 24 | 25 | tft.drawString("Developer:", 138, 143); 26 | 27 | tft.drawString("Prince Mercado", 125, 152); 28 | 29 | } 30 | -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/ML01Attacks.ino: -------------------------------------------------------------------------------- 1 | #include "RF24.h" 2 | 3 | static SPIClass sp(VSPI); 4 | 5 | // Pin Configuration 6 | #define RF24_CE_PIN 16 7 | #define RF24_CSN_PIN 17 8 | #define TFT_SCK 18 9 | #define TFT_MISO 19 10 | #define TFT_MOSI 23 11 | 12 | RF24 radio(RF24_CE_PIN, RF24_CSN_PIN, 16000000); 13 | 14 | byte channel = 45; // Start channel 15 | extern String state; 16 | 17 | void initML01() { 18 | sp.begin(TFT_SCK, TFT_MISO, TFT_MOSI, RF24_CSN_PIN); 19 | delayMicroseconds(100); 20 | if (!radio.begin(&sp)) { 21 | Serial.println("NRF24 initialization failed!"); 22 | state = "Inactive"; 23 | } 24 | radio.stopListening(); 25 | radio.setAutoAck(false); 26 | radio.setRetries(0, 0); 27 | radio.setPayloadSize(esp_random() % 12 + 21); 28 | radio.setAddressWidth(esp_random() % 2 + 3); // Random 3–4 bytes 29 | radio.setPALevel(RF24_PA_MAX, true); 30 | radio.setDataRate(RF24_2MBPS); 31 | radio.setCRCLength(RF24_CRC_DISABLED); 32 | radio.setChannel(channel); 33 | uint64_t pipeAddr = ((uint64_t)esp_random() << 32) | esp_random(); 34 | radio.openWritingPipe(pipeAddr); 35 | radio.printPrettyDetails(); 36 | Serial.println("NRF24 Initialized"); 37 | state = "Active"; 38 | clearStateArea(); 39 | tft.drawString("ML01DP5 Module: " + state, 17, 85); 40 | } 41 | 42 | void deinitML01() { 43 | radio.stopListening(); 44 | radio.stopConstCarrier(); 45 | 46 | radio.setAutoAck(false); 47 | 48 | for (uint8_t i = 0; i < 6; i++) { 49 | radio.closeReadingPipe(i); 50 | } 51 | 52 | radio.setCRCLength(RF24_CRC_DISABLED); 53 | radio.setRetries(0, 0); 54 | radio.setPALevel(RF24_PA_MIN); 55 | radio.setDataRate(RF24_1MBPS); 56 | radio.setChannel(0); 57 | 58 | // Set a dummy address to fully close pipe behavior 59 | radio.openReadingPipe(1, (uint64_t)0xE7E7E7E7E7); 60 | radio.flush_rx(); 61 | radio.flush_tx(); 62 | 63 | disableNRF24(); 64 | 65 | state = "Inactive"; 66 | Serial.println("NRF24 fully deinitialized."); 67 | } 68 | 69 | 70 | void startBroadcastingML01() { 71 | radio.startConstCarrier(RF24_PA_MAX, channel); 72 | } 73 | 74 | void stopBroadcastingML01() { 75 | radio.stopConstCarrier(); 76 | initML01(); 77 | } 78 | 79 | void hopChannelBluetooth() { 80 | reinitAfterAnalyzer(); 81 | for (int ch = 0; ch <= 85; ch += esp_random() % 1 + 2){ // Or channel += 2 for simpler syntax 82 | radio.setChannel(ch); 83 | } 84 | } 85 | 86 | void hopChannelWifi() { 87 | reinitAfterAnalyzer(); 88 | for (int ch = 0; ch <= 13; ch += esp_random() % 1 + 2){ // Or channel += 2 for simpler syntax 89 | radio.setChannel(ch); 90 | } 91 | } 92 | 93 | void hopChannelDrone() { 94 | reinitAfterAnalyzer(); 95 | for (int ch = 80; ch <= 125; ch += esp_random() % 1 + 2){ // Or channel += 2 for simpler syntax 96 | radio.setChannel(ch); 97 | } 98 | } 99 | 100 | void hopChannelAll() { 101 | reinitAfterAnalyzer(); 102 | for (int ch = 0; ch <= 125; ch += esp_random() % 1 + 2){ // Or channel += 2 for simpler syntax 103 | radio.setChannel(ch); 104 | } 105 | } 106 | 107 | void drawNRFChannelAnalyzer() { 108 | const uint8_t totalChannels = 126; 109 | const uint8_t barCount = 42; 110 | const uint8_t barWidth = 7; 111 | const uint8_t barMaxHeight = 13; 112 | const uint8_t barBaseY = 203; 113 | const uint8_t smoothingSteps = 1; 114 | 115 | static uint8_t currentHeights[barCount] = {0}; 116 | uint8_t targetHeights[barCount] = {0}; 117 | 118 | // Prepare radio 119 | radio.stopListening(); 120 | radio.setPALevel(RF24_PA_MIN); 121 | radio.setDataRate(RF24_1MBPS); 122 | radio.setChannel(0); 123 | radio.openReadingPipe(1, 0xF0F0F0F0E1LL); 124 | radio.startListening(); 125 | 126 | // Scan activity 127 | for (uint8_t ch = 0; ch < totalChannels; ch++) { 128 | radio.setChannel(ch); 129 | delayMicroseconds(350); 130 | if (radio.testRPD()) { 131 | targetHeights[ch / 3]++; 132 | } 133 | } 134 | 135 | radio.stopListening(); 136 | 137 | // Map activity to heights 138 | for (uint8_t i = 0; i < barCount; i++) { 139 | targetHeights[i] = map(targetHeights[i], 0, 3, 1, barMaxHeight); 140 | if (targetHeights[i] > barMaxHeight) targetHeights[i] = barMaxHeight; 141 | } 142 | 143 | // Smooth animation 144 | for (uint8_t step = 0; step < smoothingSteps; step++) { 145 | for (uint8_t i = 0; i < barCount; i++) { 146 | if (currentHeights[i] < targetHeights[i]) currentHeights[i]++; 147 | else if (currentHeights[i] > targetHeights[i]) currentHeights[i]--; 148 | 149 | uint16_t x = 13 + (i * barWidth); 150 | tft.fillRect(x, barBaseY, barWidth - 1, barMaxHeight, TFT_BLACK); 151 | 152 | uint8_t h = currentHeights[i]; 153 | uint16_t y = barBaseY + (barMaxHeight - h); 154 | 155 | // Hard switch: Cyan for low, Red for high 156 | uint16_t barColor = (h < barMaxHeight / 2) 157 | ? TFT_CYAN 158 | : TFT_RED; 159 | 160 | if (h > 1) { 161 | tft.fillRect(x, y + 1, barWidth - 1, h - 1, barColor); 162 | } 163 | 164 | tft.drawFastHLine(x, y, barWidth - 1, barColor); // tip matches bar 165 | } 166 | 167 | delay(10); 168 | } 169 | } 170 | 171 | void disableNRF24() { 172 | radio.powerDown(); 173 | digitalWrite(RF24_CE_PIN, LOW); // disable TX/RX 174 | digitalWrite(RF24_CSN_PIN, HIGH); // release SPI 175 | } 176 | 177 | void reinitAfterAnalyzer() { 178 | radio.stopListening(); 179 | radio.setAutoAck(false); 180 | radio.setRetries(0, 0); 181 | radio.setPayloadSize(esp_random() % 12 + 21); 182 | radio.setAddressWidth(esp_random() % 2 + 3); // Random 3–4 bytes 183 | radio.setPALevel(RF24_PA_MAX, true); 184 | radio.setDataRate(RF24_2MBPS); 185 | radio.setCRCLength(RF24_CRC_DISABLED); 186 | radio.setChannel(channel); 187 | uint64_t pipeAddr = ((uint64_t)esp_random() << 32) | esp_random(); 188 | radio.openWritingPipe(pipeAddr); 189 | radio.startConstCarrier(RF24_PA_MAX, channel); 190 | } 191 | -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/NRFSubModule.ino: -------------------------------------------------------------------------------- 1 | static const unsigned char PROGMEM image_download_bits_leftArr[] = {0x20,0x60,0xe0,0x60,0x20}; 2 | 3 | String state = "Inactive"; 4 | 5 | void clearMainArea() { 6 | tft.fillRect(11, 77, 298, 142, 0x0); 7 | } 8 | 9 | void clearStateArea() { 10 | tft.fillRect(17, 85, 125, 5, 0x0); 11 | } 12 | 13 | void clearEarsArea() { 14 | tft.fillRect(17, 35, 31, 3, 0x0); 15 | } 16 | 17 | void drawEars() { 18 | tft.drawBitmap(17, 35, image_SmallArrowUp_bits, 5, 3, 0xFFFF); 19 | tft.drawBitmap(43, 35, image_SmallArrowUp_bits, 5, 3, 0xFFFF); 20 | } 21 | 22 | void drawNRFSubModule(void) { 23 | tft.drawRect(11, 199, 298, 19, 0xFFFF); 24 | 25 | tft.drawRect(11, 103, 153, 91, 0xFFFF); 26 | 27 | tft.drawRect(11, 77, 153, 21, 0xFFFF); 28 | 29 | tft.setTextColor(0xFFFF); 30 | tft.setTextSize(1); 31 | tft.setFreeFont(&Org_01); 32 | tft.drawString("ML01DP5 Module: " + state, 17, 85); 33 | 34 | tft.drawLine(308, 77, 302, 77, 0xFFFF); 35 | 36 | tft.drawLine(308, 193, 302, 193, 0xFFFF); 37 | 38 | tft.drawLine(302, 193, 302, 77, 0xFFFF); 39 | 40 | tft.drawLine(302, 81, 300, 81, 0xFFFF); 41 | 42 | tft.drawLine(302, 85, 300, 85, 0xFFFF); 43 | 44 | tft.drawLine(302, 89, 300, 89, 0xFFFF); 45 | 46 | tft.drawLine(302, 93, 300, 93, 0xFFFF); 47 | 48 | tft.drawLine(302, 97, 298, 97, 0xFFFF); 49 | 50 | tft.drawLine(302, 105, 300, 105, 0xFFFF); 51 | 52 | tft.drawLine(302, 101, 300, 101, 0xFFFF); 53 | 54 | tft.drawLine(302, 109, 300, 109, 0xFFFF); 55 | 56 | tft.drawLine(302, 113, 300, 113, 0xFFFF); 57 | 58 | tft.drawLine(302, 117, 298, 117, 0xFFFF); 59 | 60 | tft.drawLine(302, 125, 300, 125, 0xFFFF); 61 | 62 | tft.drawLine(302, 121, 300, 121, 0xFFFF); 63 | 64 | tft.drawLine(302, 129, 300, 129, 0xFFFF); 65 | 66 | tft.drawLine(302, 133, 300, 133, 0xFFFF); 67 | 68 | tft.drawLine(302, 137, 298, 137, 0xFFFF); 69 | 70 | tft.drawLine(302, 145, 300, 145, 0xFFFF); 71 | 72 | tft.drawLine(302, 141, 300, 141, 0xFFFF); 73 | 74 | tft.drawLine(302, 149, 300, 149, 0xFFFF); 75 | 76 | tft.drawLine(302, 153, 300, 153, 0xFFFF); 77 | 78 | tft.drawLine(302, 157, 298, 157, 0xFFFF); 79 | 80 | tft.drawLine(302, 165, 300, 165, 0xFFFF); 81 | 82 | tft.drawLine(302, 161, 300, 161, 0xFFFF); 83 | 84 | tft.drawLine(302, 169, 300, 169, 0xFFFF); 85 | 86 | tft.drawLine(302, 173, 300, 173, 0xFFFF); 87 | 88 | tft.drawLine(302, 177, 298, 177, 0xFFFF); 89 | 90 | tft.drawLine(302, 181, 300, 181, 0xFFFF); 91 | 92 | tft.drawLine(302, 185, 300, 185, 0xFFFF); 93 | 94 | tft.drawLine(302, 189, 300, 189, 0xFFFF); 95 | 96 | tft.drawLine(17, 109, 21, 109, 0xFFFF); 97 | 98 | tft.drawLine(17, 113, 17, 109, 0xFFFF); 99 | 100 | tft.drawLine(17, 123, 21, 123, 0xFFFF); 101 | 102 | tft.drawLine(17, 123, 17, 119, 0xFFFF); 103 | 104 | tft.drawLine(153, 109, 157, 109, 0xFFFF); 105 | 106 | tft.drawLine(153, 123, 157, 123, 0xFFFF); 107 | 108 | tft.drawLine(157, 113, 157, 109, 0xFFFF); 109 | 110 | tft.drawLine(157, 123, 157, 119, 0xFFFF); 111 | 112 | tft.drawString("Home", 23, 114); 113 | 114 | tft.drawString("Packet Sniffer", 17, 134); 115 | 116 | tft.drawString("WiFi Jammer", 17, 154); 117 | 118 | tft.drawString("Bluetooth Jammer", 17, 174); 119 | 120 | tft.drawRect(169, 77, 124, 117, 0xFFFF); 121 | 122 | tft.drawString("Drone Jammer", 175, 88); 123 | 124 | tft.drawString("Sweep Jammer", 175, 108); 125 | 126 | tft.drawString("Replay Attack", 175, 128); 127 | 128 | tft.drawString("Protocol Fuzzing", 175, 148); 129 | 130 | tft.drawString("Pipe Hijacking", 175, 168); 131 | 132 | } 133 | 134 | 135 | /* 136 | 137 | CC1101 SCREEN DRAW 138 | 139 | */ 140 | 141 | void drawCC1101SubModule(void) { 142 | tft.drawRect(11, 199, 298, 19, 0xFFFF); 143 | 144 | tft.drawRect(11, 77, 153, 21, 0xFFFF); 145 | 146 | tft.drawRect(11, 103, 153, 91, 0xFFFF); 147 | 148 | tft.setTextColor(0xFFFF); 149 | tft.setTextSize(1); 150 | tft.setFreeFont(&Org_01); 151 | tft.drawString("CC1101 Module: " + state, 17, 85); 152 | 153 | tft.drawLine(308, 193, 302, 193, 0xFFFF); 154 | 155 | tft.drawLine(308, 77, 302, 77, 0xFFFF); 156 | 157 | tft.drawLine(302, 193, 302, 77, 0xFFFF); 158 | 159 | tft.drawLine(302, 85, 300, 85, 0xFFFF); 160 | 161 | tft.drawLine(302, 81, 300, 81, 0xFFFF); 162 | 163 | tft.drawLine(302, 89, 300, 89, 0xFFFF); 164 | 165 | tft.drawLine(153, 123, 157, 123, 0xFFFF); 166 | 167 | tft.drawLine(302, 93, 300, 93, 0xFFFF); 168 | 169 | tft.drawLine(302, 97, 298, 97, 0xFFFF); 170 | 171 | tft.drawLine(302, 105, 300, 105, 0xFFFF); 172 | 173 | tft.drawLine(302, 101, 300, 101, 0xFFFF); 174 | 175 | tft.drawLine(302, 109, 300, 109, 0xFFFF); 176 | 177 | tft.drawLine(302, 113, 300, 113, 0xFFFF); 178 | 179 | tft.drawLine(302, 117, 298, 117, 0xFFFF); 180 | 181 | tft.drawLine(302, 125, 300, 125, 0xFFFF); 182 | 183 | tft.drawLine(302, 121, 300, 121, 0xFFFF); 184 | 185 | tft.drawLine(302, 129, 300, 129, 0xFFFF); 186 | 187 | tft.drawLine(302, 133, 300, 133, 0xFFFF); 188 | 189 | tft.drawLine(302, 137, 298, 137, 0xFFFF); 190 | 191 | tft.drawLine(302, 145, 300, 145, 0xFFFF); 192 | 193 | tft.drawLine(302, 141, 300, 141, 0xFFFF); 194 | 195 | tft.drawLine(302, 149, 300, 149, 0xFFFF); 196 | 197 | tft.drawLine(302, 153, 300, 153, 0xFFFF); 198 | 199 | tft.drawLine(302, 157, 298, 157, 0xFFFF); 200 | 201 | tft.drawLine(302, 165, 300, 165, 0xFFFF); 202 | 203 | tft.drawLine(302, 161, 300, 161, 0xFFFF); 204 | 205 | tft.drawLine(302, 169, 300, 169, 0xFFFF); 206 | 207 | tft.drawLine(302, 173, 300, 173, 0xFFFF); 208 | 209 | tft.drawLine(302, 177, 298, 177, 0xFFFF); 210 | 211 | tft.drawLine(302, 181, 300, 181, 0xFFFF); 212 | 213 | tft.drawLine(302, 185, 300, 185, 0xFFFF); 214 | 215 | tft.drawLine(302, 189, 300, 189, 0xFFFF); 216 | 217 | tft.drawLine(17, 109, 21, 109, 0xFFFF); 218 | 219 | tft.drawLine(17, 123, 21, 123, 0xFFFF); 220 | 221 | tft.drawLine(17, 113, 17, 109, 0xFFFF); 222 | 223 | tft.drawLine(17, 123, 17, 119, 0xFFFF); 224 | 225 | tft.drawLine(153, 109, 157, 109, 0xFFFF); 226 | 227 | tft.drawLine(153, 123, 157, 123, 0xFFFF); 228 | 229 | tft.drawLine(157, 113, 157, 109, 0xFFFF); 230 | 231 | tft.drawLine(157, 123, 157, 119, 0xFFFF); 232 | 233 | tft.drawString("Packet Sniffer", 17, 134); 234 | 235 | tft.drawString("Home", 23, 114); 236 | 237 | tft.drawString("Channel Jammer", 17, 154); 238 | 239 | tft.drawString("State Desync", 17, 174); 240 | 241 | tft.drawRect(169, 77, 124, 117, 0xFFFF); 242 | 243 | tft.drawString("Rolling Jammer", 175, 88); 244 | 245 | tft.drawString("Sweep Jammer", 175, 108); 246 | 247 | tft.drawString("Replay Attack", 175, 128); 248 | 249 | tft.drawString("Protocol Fuzzing", 175, 148); 250 | 251 | tft.drawString("Payload Injection", 175, 168); 252 | 253 | } 254 | 255 | 256 | /* 257 | 258 | WIFI SCREEN DRAW 259 | 260 | */ 261 | 262 | void drawWifiSubModule(void) { 263 | tft.drawRect(11, 199, 298, 19, 0xFFFF); 264 | 265 | tft.drawRect(11, 77, 153, 21, 0xFFFF); 266 | 267 | tft.drawRect(11, 103, 153, 91, 0xFFFF); 268 | 269 | tft.setTextColor(0xFFFF); 270 | tft.setTextSize(1); 271 | tft.setFreeFont(&Org_01); 272 | tft.drawString("Promiscuous Mode: " + state, 17, 85); 273 | 274 | tft.drawLine(308, 193, 302, 193, 0xFFFF); 275 | 276 | tft.drawLine(308, 77, 302, 77, 0xFFFF); 277 | 278 | tft.drawLine(302, 193, 302, 77, 0xFFFF); 279 | 280 | tft.drawLine(302, 85, 300, 85, 0xFFFF); 281 | 282 | tft.drawLine(302, 81, 300, 81, 0xFFFF); 283 | 284 | tft.drawLine(302, 89, 300, 89, 0xFFFF); 285 | 286 | tft.drawLine(153, 123, 157, 123, 0xFFFF); 287 | 288 | tft.drawLine(302, 93, 300, 93, 0xFFFF); 289 | 290 | tft.drawLine(302, 97, 298, 97, 0xFFFF); 291 | 292 | tft.drawLine(302, 105, 300, 105, 0xFFFF); 293 | 294 | tft.drawLine(302, 101, 300, 101, 0xFFFF); 295 | 296 | tft.drawLine(302, 109, 300, 109, 0xFFFF); 297 | 298 | tft.drawLine(302, 113, 300, 113, 0xFFFF); 299 | 300 | tft.drawLine(302, 117, 298, 117, 0xFFFF); 301 | 302 | tft.drawLine(302, 125, 300, 125, 0xFFFF); 303 | 304 | tft.drawLine(302, 121, 300, 121, 0xFFFF); 305 | 306 | tft.drawLine(302, 129, 300, 129, 0xFFFF); 307 | 308 | tft.drawLine(302, 133, 300, 133, 0xFFFF); 309 | 310 | tft.drawLine(302, 137, 298, 137, 0xFFFF); 311 | 312 | tft.drawLine(302, 145, 300, 145, 0xFFFF); 313 | 314 | tft.drawLine(302, 141, 300, 141, 0xFFFF); 315 | 316 | tft.drawLine(302, 149, 300, 149, 0xFFFF); 317 | 318 | tft.drawLine(302, 153, 300, 153, 0xFFFF); 319 | 320 | tft.drawLine(302, 157, 298, 157, 0xFFFF); 321 | 322 | tft.drawLine(302, 165, 300, 165, 0xFFFF); 323 | 324 | tft.drawLine(302, 161, 300, 161, 0xFFFF); 325 | 326 | tft.drawLine(302, 169, 300, 169, 0xFFFF); 327 | 328 | tft.drawLine(302, 173, 300, 173, 0xFFFF); 329 | 330 | tft.drawLine(302, 177, 298, 177, 0xFFFF); 331 | 332 | tft.drawLine(302, 181, 300, 181, 0xFFFF); 333 | 334 | tft.drawLine(302, 185, 300, 185, 0xFFFF); 335 | 336 | tft.drawLine(302, 189, 300, 189, 0xFFFF); 337 | 338 | tft.drawLine(17, 109, 21, 109, 0xFFFF); 339 | 340 | tft.drawLine(17, 123, 21, 123, 0xFFFF); 341 | 342 | tft.drawLine(17, 113, 17, 109, 0xFFFF); 343 | 344 | tft.drawLine(17, 123, 17, 119, 0xFFFF); 345 | 346 | tft.drawLine(153, 109, 157, 109, 0xFFFF); 347 | 348 | tft.drawLine(153, 123, 157, 123, 0xFFFF); 349 | 350 | tft.drawLine(157, 113, 157, 109, 0xFFFF); 351 | 352 | tft.drawLine(157, 123, 157, 119, 0xFFFF); 353 | 354 | tft.drawString("WiFi Scanner", 17, 134); 355 | 356 | tft.drawString("Home", 23, 114); 357 | 358 | tft.drawString("Deauth Selected", 17, 154); 359 | 360 | tft.drawString("Deauth Flood", 17, 174); 361 | 362 | tft.drawRect(169, 77, 124, 117, 0xFFFF); 363 | 364 | tft.drawString("PMKID Attack", 175, 88); 365 | 366 | tft.drawString("Handshake Sniffing", 175, 108); 367 | 368 | tft.drawString("Rogue Portal", 175, 128); 369 | 370 | tft.drawString("BSSID Flood", 175, 148); 371 | 372 | tft.drawString("BSSID Clone", 175, 168); 373 | 374 | } 375 | 376 | 377 | /* 378 | 379 | BLUETOOTH SCREEN DRAW 380 | 381 | */ 382 | 383 | void drawBluetoothSubModule(void) { 384 | tft.drawRect(11, 199, 298, 19, 0xFFFF); 385 | 386 | tft.drawRect(11, 103, 153, 91, 0xFFFF); 387 | 388 | tft.drawRect(11, 77, 153, 21, 0xFFFF); 389 | 390 | tft.setTextColor(0xFFFF); 391 | tft.setTextSize(1); 392 | tft.setFreeFont(&Org_01); 393 | tft.drawString("Bluetooth Mode: " + state, 17, 85); 394 | 395 | tft.drawLine(308, 77, 302, 77, 0xFFFF); 396 | 397 | tft.drawLine(308, 193, 302, 193, 0xFFFF); 398 | 399 | tft.drawLine(302, 193, 302, 77, 0xFFFF); 400 | 401 | tft.drawLine(302, 81, 300, 81, 0xFFFF); 402 | 403 | tft.drawLine(302, 85, 300, 85, 0xFFFF); 404 | 405 | tft.drawLine(302, 89, 300, 89, 0xFFFF); 406 | 407 | tft.drawLine(302, 93, 300, 93, 0xFFFF); 408 | 409 | tft.drawLine(153, 123, 157, 123, 0xFFFF); 410 | 411 | tft.drawLine(302, 97, 298, 97, 0xFFFF); 412 | 413 | tft.drawLine(302, 105, 300, 105, 0xFFFF); 414 | 415 | tft.drawLine(302, 101, 300, 101, 0xFFFF); 416 | 417 | tft.drawLine(302, 109, 300, 109, 0xFFFF); 418 | 419 | tft.drawLine(302, 113, 300, 113, 0xFFFF); 420 | 421 | tft.drawLine(302, 117, 298, 117, 0xFFFF); 422 | 423 | tft.drawLine(302, 125, 300, 125, 0xFFFF); 424 | 425 | tft.drawLine(302, 121, 300, 121, 0xFFFF); 426 | 427 | tft.drawLine(302, 129, 300, 129, 0xFFFF); 428 | 429 | tft.drawLine(302, 133, 300, 133, 0xFFFF); 430 | 431 | tft.drawLine(302, 137, 298, 137, 0xFFFF); 432 | 433 | tft.drawLine(302, 145, 300, 145, 0xFFFF); 434 | 435 | tft.drawLine(302, 141, 300, 141, 0xFFFF); 436 | 437 | tft.drawLine(302, 149, 300, 149, 0xFFFF); 438 | 439 | tft.drawLine(302, 153, 300, 153, 0xFFFF); 440 | 441 | tft.drawLine(302, 157, 298, 157, 0xFFFF); 442 | 443 | tft.drawLine(302, 165, 300, 165, 0xFFFF); 444 | 445 | tft.drawLine(302, 161, 300, 161, 0xFFFF); 446 | 447 | tft.drawLine(302, 169, 300, 169, 0xFFFF); 448 | 449 | tft.drawLine(302, 173, 300, 173, 0xFFFF); 450 | 451 | tft.drawLine(302, 177, 298, 177, 0xFFFF); 452 | 453 | tft.drawLine(302, 181, 300, 181, 0xFFFF); 454 | 455 | tft.drawLine(302, 185, 300, 185, 0xFFFF); 456 | 457 | tft.drawLine(302, 189, 300, 189, 0xFFFF); 458 | 459 | tft.drawLine(17, 109, 21, 109, 0xFFFF); 460 | 461 | tft.drawLine(17, 113, 17, 109, 0xFFFF); 462 | 463 | tft.drawLine(17, 123, 21, 123, 0xFFFF); 464 | 465 | tft.drawLine(17, 123, 17, 119, 0xFFFF); 466 | 467 | tft.drawLine(153, 109, 157, 109, 0xFFFF); 468 | 469 | tft.drawLine(153, 123, 157, 123, 0xFFFF); 470 | 471 | tft.drawLine(157, 113, 157, 109, 0xFFFF); 472 | 473 | tft.drawLine(157, 123, 157, 119, 0xFFFF); 474 | 475 | tft.drawString("Home", 23, 114); 476 | 477 | tft.drawString("Bluetooth Scanner", 17, 134); 478 | 479 | tft.drawString("Beacon Spamming", 17, 154); 480 | 481 | tft.drawString("Device Impersonation", 17, 174); 482 | 483 | tft.drawRect(169, 77, 124, 117, 0xFFFF); 484 | 485 | tft.drawString("Denial Of Service", 175, 88); 486 | 487 | tft.drawString("Popup Trigger", 175, 108); 488 | 489 | tft.drawString("Profile Poisoning", 175, 128); 490 | 491 | tft.drawString("HID Injection", 175, 148); 492 | 493 | tft.drawString("Firmware Bomb", 175, 168); 494 | 495 | } -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/Org_01.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | 4 | // Org_v01 by Orgdot (www.orgdot.com/aliasfonts). A tiny, 5 | // stylized font with all characters within a 6 pixel height. 6 | 7 | const uint8_t Org_01Bitmaps[] PROGMEM = { 8 | 0xE8, 0xA0, 0x57, 0xD5, 0xF5, 0x00, 0xFD, 0x3E, 0x5F, 0x80, 0x88, 0x88, 9 | 0x88, 0x80, 0xF4, 0xBF, 0x2E, 0x80, 0x80, 0x6A, 0x40, 0x95, 0x80, 0xAA, 10 | 0x80, 0x5D, 0x00, 0xC0, 0xF0, 0x80, 0x08, 0x88, 0x88, 0x00, 0xFC, 0x63, 11 | 0x1F, 0x80, 0xF8, 0xF8, 0x7F, 0x0F, 0x80, 0xF8, 0x7E, 0x1F, 0x80, 0x8C, 12 | 0x7E, 0x10, 0x80, 0xFC, 0x3E, 0x1F, 0x80, 0xFC, 0x3F, 0x1F, 0x80, 0xF8, 13 | 0x42, 0x10, 0x80, 0xFC, 0x7F, 0x1F, 0x80, 0xFC, 0x7E, 0x1F, 0x80, 0x90, 14 | 0xB0, 0x2A, 0x22, 0xF0, 0xF0, 0x88, 0xA8, 0xF8, 0x4E, 0x02, 0x00, 0xFD, 15 | 0x6F, 0x0F, 0x80, 0xFC, 0x7F, 0x18, 0x80, 0xF4, 0x7D, 0x1F, 0x00, 0xFC, 16 | 0x21, 0x0F, 0x80, 0xF4, 0x63, 0x1F, 0x00, 0xFC, 0x3F, 0x0F, 0x80, 0xFC, 17 | 0x3F, 0x08, 0x00, 0xFC, 0x2F, 0x1F, 0x80, 0x8C, 0x7F, 0x18, 0x80, 0xF9, 18 | 0x08, 0x4F, 0x80, 0x78, 0x85, 0x2F, 0x80, 0x8D, 0xB1, 0x68, 0x80, 0x84, 19 | 0x21, 0x0F, 0x80, 0xFD, 0x6B, 0x5A, 0x80, 0xFC, 0x63, 0x18, 0x80, 0xFC, 20 | 0x63, 0x1F, 0x80, 0xFC, 0x7F, 0x08, 0x00, 0xFC, 0x63, 0x3F, 0x80, 0xFC, 21 | 0x7F, 0x29, 0x00, 0xFC, 0x3E, 0x1F, 0x80, 0xF9, 0x08, 0x42, 0x00, 0x8C, 22 | 0x63, 0x1F, 0x80, 0x8C, 0x62, 0xA2, 0x00, 0xAD, 0x6B, 0x5F, 0x80, 0x8A, 23 | 0x88, 0xA8, 0x80, 0x8C, 0x54, 0x42, 0x00, 0xF8, 0x7F, 0x0F, 0x80, 0xEA, 24 | 0xC0, 0x82, 0x08, 0x20, 0x80, 0xD5, 0xC0, 0x54, 0xF8, 0x80, 0xF1, 0xFF, 25 | 0x8F, 0x99, 0xF0, 0xF8, 0x8F, 0x1F, 0x99, 0xF0, 0xFF, 0x8F, 0x6B, 0xA4, 26 | 0xF9, 0x9F, 0x10, 0x8F, 0x99, 0x90, 0xF0, 0x55, 0xC0, 0x8A, 0xF9, 0x90, 27 | 0xF8, 0xFD, 0x63, 0x10, 0xF9, 0x99, 0xF9, 0x9F, 0xF9, 0x9F, 0x80, 0xF9, 28 | 0x9F, 0x20, 0xF8, 0x88, 0x47, 0x1F, 0x27, 0xC8, 0x42, 0x00, 0x99, 0x9F, 29 | 0x99, 0x97, 0x8C, 0x6B, 0xF0, 0x96, 0x69, 0x99, 0x9F, 0x10, 0x2E, 0x8F, 30 | 0x2B, 0x22, 0xF8, 0x89, 0xA8, 0x0F, 0xE0}; 31 | 32 | const GFXglyph Org_01Glyphs[] PROGMEM = {{0, 0, 0, 6, 0, 1}, // 0x20 ' ' 33 | {0, 1, 5, 2, 0, -4}, // 0x21 '!' 34 | {1, 3, 1, 4, 0, -4}, // 0x22 '"' 35 | {2, 5, 5, 6, 0, -4}, // 0x23 '#' 36 | {6, 5, 5, 6, 0, -4}, // 0x24 '$' 37 | {10, 5, 5, 6, 0, -4}, // 0x25 '%' 38 | {14, 5, 5, 6, 0, -4}, // 0x26 '&' 39 | {18, 1, 1, 2, 0, -4}, // 0x27 ''' 40 | {19, 2, 5, 3, 0, -4}, // 0x28 '(' 41 | {21, 2, 5, 3, 0, -4}, // 0x29 ')' 42 | {23, 3, 3, 4, 0, -3}, // 0x2A '*' 43 | {25, 3, 3, 4, 0, -3}, // 0x2B '+' 44 | {27, 1, 2, 2, 0, 0}, // 0x2C ',' 45 | {28, 4, 1, 5, 0, -2}, // 0x2D '-' 46 | {29, 1, 1, 2, 0, 0}, // 0x2E '.' 47 | {30, 5, 5, 6, 0, -4}, // 0x2F '/' 48 | {34, 5, 5, 6, 0, -4}, // 0x30 '0' 49 | {38, 1, 5, 2, 0, -4}, // 0x31 '1' 50 | {39, 5, 5, 6, 0, -4}, // 0x32 '2' 51 | {43, 5, 5, 6, 0, -4}, // 0x33 '3' 52 | {47, 5, 5, 6, 0, -4}, // 0x34 '4' 53 | {51, 5, 5, 6, 0, -4}, // 0x35 '5' 54 | {55, 5, 5, 6, 0, -4}, // 0x36 '6' 55 | {59, 5, 5, 6, 0, -4}, // 0x37 '7' 56 | {63, 5, 5, 6, 0, -4}, // 0x38 '8' 57 | {67, 5, 5, 6, 0, -4}, // 0x39 '9' 58 | {71, 1, 4, 2, 0, -3}, // 0x3A ':' 59 | {72, 1, 4, 2, 0, -3}, // 0x3B ';' 60 | {73, 3, 5, 4, 0, -4}, // 0x3C '<' 61 | {75, 4, 3, 5, 0, -3}, // 0x3D '=' 62 | {77, 3, 5, 4, 0, -4}, // 0x3E '>' 63 | {79, 5, 5, 6, 0, -4}, // 0x3F '?' 64 | {83, 5, 5, 6, 0, -4}, // 0x40 '@' 65 | {87, 5, 5, 6, 0, -4}, // 0x41 'A' 66 | {91, 5, 5, 6, 0, -4}, // 0x42 'B' 67 | {95, 5, 5, 6, 0, -4}, // 0x43 'C' 68 | {99, 5, 5, 6, 0, -4}, // 0x44 'D' 69 | {103, 5, 5, 6, 0, -4}, // 0x45 'E' 70 | {107, 5, 5, 6, 0, -4}, // 0x46 'F' 71 | {111, 5, 5, 6, 0, -4}, // 0x47 'G' 72 | {115, 5, 5, 6, 0, -4}, // 0x48 'H' 73 | {119, 5, 5, 6, 0, -4}, // 0x49 'I' 74 | {123, 5, 5, 6, 0, -4}, // 0x4A 'J' 75 | {127, 5, 5, 6, 0, -4}, // 0x4B 'K' 76 | {131, 5, 5, 6, 0, -4}, // 0x4C 'L' 77 | {135, 5, 5, 6, 0, -4}, // 0x4D 'M' 78 | {139, 5, 5, 6, 0, -4}, // 0x4E 'N' 79 | {143, 5, 5, 6, 0, -4}, // 0x4F 'O' 80 | {147, 5, 5, 6, 0, -4}, // 0x50 'P' 81 | {151, 5, 5, 6, 0, -4}, // 0x51 'Q' 82 | {155, 5, 5, 6, 0, -4}, // 0x52 'R' 83 | {159, 5, 5, 6, 0, -4}, // 0x53 'S' 84 | {163, 5, 5, 6, 0, -4}, // 0x54 'T' 85 | {167, 5, 5, 6, 0, -4}, // 0x55 'U' 86 | {171, 5, 5, 6, 0, -4}, // 0x56 'V' 87 | {175, 5, 5, 6, 0, -4}, // 0x57 'W' 88 | {179, 5, 5, 6, 0, -4}, // 0x58 'X' 89 | {183, 5, 5, 6, 0, -4}, // 0x59 'Y' 90 | {187, 5, 5, 6, 0, -4}, // 0x5A 'Z' 91 | {191, 2, 5, 3, 0, -4}, // 0x5B '[' 92 | {193, 5, 5, 6, 0, -4}, // 0x5C '\' 93 | {197, 2, 5, 3, 0, -4}, // 0x5D ']' 94 | {199, 3, 2, 4, 0, -4}, // 0x5E '^' 95 | {200, 5, 1, 6, 0, 1}, // 0x5F '_' 96 | {201, 1, 1, 2, 0, -4}, // 0x60 '`' 97 | {202, 4, 4, 5, 0, -3}, // 0x61 'a' 98 | {204, 4, 5, 5, 0, -4}, // 0x62 'b' 99 | {207, 4, 4, 5, 0, -3}, // 0x63 'c' 100 | {209, 4, 5, 5, 0, -4}, // 0x64 'd' 101 | {212, 4, 4, 5, 0, -3}, // 0x65 'e' 102 | {214, 3, 5, 4, 0, -4}, // 0x66 'f' 103 | {216, 4, 5, 5, 0, -3}, // 0x67 'g' 104 | {219, 4, 5, 5, 0, -4}, // 0x68 'h' 105 | {222, 1, 4, 2, 0, -3}, // 0x69 'i' 106 | {223, 2, 5, 3, 0, -3}, // 0x6A 'j' 107 | {225, 4, 5, 5, 0, -4}, // 0x6B 'k' 108 | {228, 1, 5, 2, 0, -4}, // 0x6C 'l' 109 | {229, 5, 4, 6, 0, -3}, // 0x6D 'm' 110 | {232, 4, 4, 5, 0, -3}, // 0x6E 'n' 111 | {234, 4, 4, 5, 0, -3}, // 0x6F 'o' 112 | {236, 4, 5, 5, 0, -3}, // 0x70 'p' 113 | {239, 4, 5, 5, 0, -3}, // 0x71 'q' 114 | {242, 4, 4, 5, 0, -3}, // 0x72 'r' 115 | {244, 4, 4, 5, 0, -3}, // 0x73 's' 116 | {246, 5, 5, 6, 0, -4}, // 0x74 't' 117 | {250, 4, 4, 5, 0, -3}, // 0x75 'u' 118 | {252, 4, 4, 5, 0, -3}, // 0x76 'v' 119 | {254, 5, 4, 6, 0, -3}, // 0x77 'w' 120 | {257, 4, 4, 5, 0, -3}, // 0x78 'x' 121 | {259, 4, 5, 5, 0, -3}, // 0x79 'y' 122 | {262, 4, 4, 5, 0, -3}, // 0x7A 'z' 123 | {264, 3, 5, 4, 0, -4}, // 0x7B '{' 124 | {266, 1, 5, 2, 0, -4}, // 0x7C '|' 125 | {267, 3, 5, 4, 0, -4}, // 0x7D '}' 126 | {269, 5, 3, 6, 0, -3}}; // 0x7E '~' 127 | 128 | const GFXfont Org_01 PROGMEM = {(uint8_t *)Org_01Bitmaps, 129 | (GFXglyph *)Org_01Glyphs, 0x20, 0x7E, 7}; 130 | 131 | // Approx. 943 bytes 132 | -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/Pin Connections.txt: -------------------------------------------------------------------------------- 1 | --- TFT Display --- 2 | TFT | ESP 3 | | 4 | MISO | 19 5 | LED | 5v 6 | SCK | 18 7 | MOSI | 23 8 | DC | 2 9 | RESET | 4 10 | CS | 15 11 | GND | GND 12 | VCC | 3.3v 13 | 14 | --- NRF24 Module --- 15 | NRF24 | ESP 16 | | 17 | CE | 16 18 | CSN | 17 19 | SCK | 18 20 | MISO | 19 21 | MOSI | 23 22 | 23 | --- Switch --- 24 | Row Pin = 25 25 | Up = 26 26 | Down = 27 27 | Right = 32 28 | Left = 33 29 | select = 5 30 | -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/User_Setup.h: -------------------------------------------------------------------------------- 1 | // USER DEFINED SETTINGS 2 | // Set driver type, fonts to be loaded, pins used and SPI control method etc. 3 | // 4 | // See the User_Setup_Select.h file if you wish to be able to define multiple 5 | // setups and then easily select which setup file is used by the compiler. 6 | // 7 | // If this file is edited correctly then all the library example sketches should 8 | // run without the need to make any more changes for a particular hardware setup! 9 | // Note that some sketches are designed for a particular TFT pixel width/height 10 | 11 | // User defined information reported by "Read_User_Setup" test & diagnostics example 12 | #define USER_SETUP_INFO "User_Setup" 13 | 14 | // Define to disable all #warnings in library (can be put in User_Setup_Select.h) 15 | //#define DISABLE_ALL_LIBRARY_WARNINGS 16 | 17 | // ################################################################################## 18 | // 19 | // Section 1. Call up the right driver file and any options for it 20 | // 21 | // ################################################################################## 22 | 23 | // Define STM32 to invoke optimised processor support (only for STM32) 24 | //#define STM32 25 | 26 | // Defining the STM32 board allows the library to optimise the performance 27 | // for UNO compatible "MCUfriend" style shields 28 | //#define NUCLEO_64_TFT 29 | //#define NUCLEO_144_TFT 30 | 31 | // STM32 8-bit parallel only: 32 | // If STN32 Port A or B pins 0-7 are used for 8-bit parallel data bus bits 0-7 33 | // then this will improve rendering performance by a factor of ~8x 34 | //#define STM_PORTA_DATA_BUS 35 | //#define STM_PORTB_DATA_BUS 36 | 37 | // Tell the library to use parallel mode (otherwise SPI is assumed) 38 | //#define TFT_PARALLEL_8_BIT 39 | //#defined TFT_PARALLEL_16_BIT // **** 16-bit parallel ONLY for RP2040 processor **** 40 | 41 | // Display type - only define if RPi display 42 | //#define RPI_DISPLAY_TYPE // 20MHz maximum SPI 43 | 44 | // Only define one driver, the other ones must be commented out 45 | #define ILI9341_DRIVER // Generic driver for common displays 46 | //#define ILI9341_2_DRIVER // Alternative ILI9341 driver, see https://github.com/Bodmer/TFT_eSPI/issues/1172 47 | //#define ST7735_DRIVER // Define additional parameters below for this display 48 | //#define ILI9163_DRIVER // Define additional parameters below for this display 49 | //#define S6D02A1_DRIVER 50 | //#define RPI_ILI9486_DRIVER // 20MHz maximum SPI 51 | //#define HX8357D_DRIVER 52 | //#define ILI9481_DRIVER 53 | //#define ILI9486_DRIVER 54 | //#define ILI9488_DRIVER // WARNING: Do not connect ILI9488 display SDO to MISO if other devices share the SPI bus (TFT SDO does NOT tristate when CS is high) 55 | //#define ST7789_DRIVER // Full configuration option, define additional parameters below for this display 56 | //#define ST7789_2_DRIVER // Minimal configuration option, define additional parameters below for this display 57 | //#define R61581_DRIVER 58 | //#define RM68140_DRIVER 59 | //#define ST7796_DRIVER 60 | //#define SSD1351_DRIVER 61 | //#define SSD1963_480_DRIVER 62 | //#define SSD1963_800_DRIVER 63 | //#define SSD1963_800ALT_DRIVER 64 | //#define ILI9225_DRIVER 65 | //#define GC9A01_DRIVER 66 | 67 | // Some displays support SPI reads via the MISO pin, other displays have a single 68 | // bi-directional SDA pin and the library will try to read this via the MOSI line. 69 | // To use the SDA line for reading data from the TFT uncomment the following line: 70 | 71 | // #define TFT_SDA_READ // This option is for ESP32 ONLY, tested with ST7789 and GC9A01 display only 72 | 73 | // For ST7735, ST7789 and ILI9341 ONLY, define the colour order IF the blue and red are swapped on your display 74 | // Try ONE option at a time to find the correct colour order for your display 75 | 76 | // #define TFT_RGB_ORDER TFT_RGB // Colour order Red-Green-Blue 77 | // #define TFT_RGB_ORDER TFT_BGR // Colour order Blue-Green-Red 78 | 79 | // For M5Stack ESP32 module with integrated ILI9341 display ONLY, remove // in line below 80 | 81 | // #define M5STACK 82 | 83 | // For ST7789, ST7735, ILI9163 and GC9A01 ONLY, define the pixel width and height in portrait orientation 84 | // #define TFT_WIDTH 80 85 | // #define TFT_WIDTH 128 86 | // #define TFT_WIDTH 172 // ST7789 172 x 320 87 | // #define TFT_WIDTH 170 // ST7789 170 x 320 88 | // #define TFT_WIDTH 240 // ST7789 240 x 240 and 240 x 320 89 | // #define TFT_HEIGHT 160 90 | // #define TFT_HEIGHT 128 91 | // #define TFT_HEIGHT 240 // ST7789 240 x 240 92 | // #define TFT_HEIGHT 320 // ST7789 240 x 320 93 | // #define TFT_HEIGHT 240 // GC9A01 240 x 240 94 | 95 | // For ST7735 ONLY, define the type of display, originally this was based on the 96 | // colour of the tab on the screen protector film but this is not always true, so try 97 | // out the different options below if the screen does not display graphics correctly, 98 | // e.g. colours wrong, mirror images, or stray pixels at the edges. 99 | // Comment out ALL BUT ONE of these options for a ST7735 display driver, save this 100 | // this User_Setup file, then rebuild and upload the sketch to the board again: 101 | 102 | // #define ST7735_INITB 103 | // #define ST7735_GREENTAB 104 | // #define ST7735_GREENTAB2 105 | // #define ST7735_GREENTAB3 106 | // #define ST7735_GREENTAB128 // For 128 x 128 display 107 | // #define ST7735_GREENTAB160x80 // For 160 x 80 display (BGR, inverted, 26 offset) 108 | // #define ST7735_ROBOTLCD // For some RobotLCD Arduino shields (128x160, BGR, https://docs.arduino.cc/retired/getting-started-guides/TFT) 109 | // #define ST7735_REDTAB 110 | // #define ST7735_BLACKTAB 111 | // #define ST7735_REDTAB160x80 // For 160 x 80 display with 24 pixel offset 112 | 113 | // If colours are inverted (white shows as black) then uncomment one of the next 114 | // 2 lines try both options, one of the options should correct the inversion. 115 | 116 | // #define TFT_INVERSION_ON 117 | // #define TFT_INVERSION_OFF 118 | 119 | 120 | // ################################################################################## 121 | // 122 | // Section 2. Define the pins that are used to interface with the display here 123 | // 124 | // ################################################################################## 125 | 126 | // If a backlight control signal is available then define the TFT_BL pin in Section 2 127 | // below. The backlight will be turned ON when tft.begin() is called, but the library 128 | // needs to know if the LEDs are ON with the pin HIGH or LOW. If the LEDs are to be 129 | // driven with a PWM signal or turned OFF/ON then this must be handled by the user 130 | // sketch. e.g. with digitalWrite(TFT_BL, LOW); 131 | 132 | // #define TFT_BL 32 // LED back-light control pin 133 | // #define TFT_BACKLIGHT_ON HIGH // Level to turn ON back-light (HIGH or LOW) 134 | 135 | 136 | 137 | // We must use hardware SPI, a minimum of 3 GPIO pins is needed. 138 | // Typical setup for ESP8266 NodeMCU ESP-12 is : 139 | // 140 | // Display SDO/MISO to NodeMCU pin D6 (or leave disconnected if not reading TFT) 141 | // Display LED to NodeMCU pin VIN (or 5V, see below) 142 | // Display SCK to NodeMCU pin D5 143 | // Display SDI/MOSI to NodeMCU pin D7 144 | // Display DC (RS/AO)to NodeMCU pin D3 145 | // Display RESET to NodeMCU pin D4 (or RST, see below) 146 | // Display CS to NodeMCU pin D8 (or GND, see below) 147 | // Display GND to NodeMCU pin GND (0V) 148 | // Display VCC to NodeMCU 5V or 3.3V 149 | // 150 | // The TFT RESET pin can be connected to the NodeMCU RST pin or 3.3V to free up a control pin 151 | // 152 | // The DC (Data Command) pin may be labelled AO or RS (Register Select) 153 | // 154 | // With some displays such as the ILI9341 the TFT CS pin can be connected to GND if no more 155 | // SPI devices (e.g. an SD Card) are connected, in this case comment out the #define TFT_CS 156 | // line below so it is NOT defined. Other displays such at the ST7735 require the TFT CS pin 157 | // to be toggled during setup, so in these cases the TFT_CS line must be defined and connected. 158 | // 159 | // The NodeMCU D0 pin can be used for RST 160 | // 161 | // 162 | // Note: only some versions of the NodeMCU provide the USB 5V on the VIN pin 163 | // If 5V is not available at a pin you can use 3.3V but backlight brightness 164 | // will be lower. 165 | 166 | 167 | // ###### EDIT THE PIN NUMBERS IN THE LINES FOLLOWING TO SUIT YOUR ESP8266 SETUP ###### 168 | 169 | // For NodeMCU - use pin numbers in the form PIN_Dx where Dx is the NodeMCU pin designation 170 | //#define TFT_MISO PIN_D6 // Automatically assigned with ESP8266 if not defined 171 | //#define TFT_MOSI PIN_D7 // Automatically assigned with ESP8266 if not defined 172 | //#define TFT_SCLK PIN_D5 // Automatically assigned with ESP8266 if not defined 173 | 174 | //#define TFT_CS PIN_D8 // Chip select control pin D8 175 | //#define TFT_DC PIN_D3 // Data Command control pin 176 | //#define TFT_RST PIN_D4 // Reset pin (could connect to NodeMCU RST, see next line) 177 | //#define TFT_RST -1 // Set TFT_RST to -1 if the display RESET is connected to NodeMCU RST or 3.3V 178 | 179 | 180 | //#define TFT_BL PIN_D1 // LED back-light (only for ST7789 with backlight control pin) 181 | 182 | //#define TOUCH_CS PIN_D2 // Chip select pin (T_CS) of touch screen 183 | 184 | //#define TFT_WR PIN_D2 // Write strobe for modified Raspberry Pi TFT only 185 | 186 | 187 | // ###### FOR ESP8266 OVERLAP MODE EDIT THE PIN NUMBERS IN THE FOLLOWING LINES ###### 188 | 189 | // Overlap mode shares the ESP8266 FLASH SPI bus with the TFT so has a performance impact 190 | // but saves pins for other functions. It is best not to connect MISO as some displays 191 | // do not tristate that line when chip select is high! 192 | // Note: Only one SPI device can share the FLASH SPI lines, so a SPI touch controller 193 | // cannot be connected as well to the same SPI signals. 194 | // On NodeMCU 1.0 SD0=MISO, SD1=MOSI, CLK=SCLK to connect to TFT in overlap mode 195 | // On NodeMCU V3 S0 =MISO, S1 =MOSI, S2 =SCLK 196 | // In ESP8266 overlap mode the following must be defined 197 | 198 | //#define TFT_SPI_OVERLAP 199 | 200 | // In ESP8266 overlap mode the TFT chip select MUST connect to pin D3 201 | //#define TFT_CS PIN_D3 202 | //#define TFT_DC PIN_D5 // Data Command control pin 203 | //#define TFT_RST PIN_D4 // Reset pin (could connect to NodeMCU RST, see next line) 204 | //#define TFT_RST -1 // Set TFT_RST to -1 if the display RESET is connected to NodeMCU RST or 3.3V 205 | 206 | 207 | // ###### EDIT THE PIN NUMBERS IN THE LINES FOLLOWING TO SUIT YOUR ESP32 SETUP ###### 208 | 209 | // For ESP32 Dev board (only tested with ILI9341 display) 210 | // The hardware SPI can be mapped to any pins 211 | 212 | #define TFT_MISO 19 213 | #define TFT_MOSI 23 214 | #define TFT_SCLK 18 215 | #define TFT_CS 15 // Chip select control pin 216 | #define TFT_DC 2 // Data Command control pin 217 | #define TFT_RST 4 // Reset pin (could connect to RST pin) 218 | //#define TFT_RST -1 // Set TFT_RST to -1 if display RESET is connected to ESP32 board RST 219 | 220 | // For ESP32 Dev board (only tested with GC9A01 display) 221 | // The hardware SPI can be mapped to any pins 222 | 223 | //#define TFT_MOSI 15 // In some display driver board, it might be written as "SDA" and so on. 224 | //#define TFT_SCLK 14 225 | //#define TFT_CS 5 // Chip select control pin 226 | //#define TFT_DC 27 // Data Command control pin 227 | //#define TFT_RST 33 // Reset pin (could connect to Arduino RESET pin) 228 | //#define TFT_BL 22 // LED back-light 229 | 230 | //#define TOUCH_CS 21 // Chip select pin (T_CS) of touch screen 231 | 232 | //#define TFT_WR 22 // Write strobe for modified Raspberry Pi TFT only 233 | 234 | // For the M5Stack module use these #define lines 235 | //#define TFT_MISO 19 236 | //#define TFT_MOSI 23 237 | //#define TFT_SCLK 18 238 | //#define TFT_CS 14 // Chip select control pin 239 | //#define TFT_DC 27 // Data Command control pin 240 | //#define TFT_RST 33 // Reset pin (could connect to Arduino RESET pin) 241 | //#define TFT_BL 32 // LED back-light (required for M5Stack) 242 | 243 | // ###### EDIT THE PINs BELOW TO SUIT YOUR ESP32 PARALLEL TFT SETUP ###### 244 | 245 | // The library supports 8-bit parallel TFTs with the ESP32, the pin 246 | // selection below is compatible with ESP32 boards in UNO format. 247 | // Wemos D32 boards need to be modified, see diagram in Tools folder. 248 | // Only ILI9481 and ILI9341 based displays have been tested! 249 | 250 | // Parallel bus is only supported for the STM32 and ESP32 251 | // Example below is for ESP32 Parallel interface with UNO displays 252 | 253 | // Tell the library to use 8-bit parallel mode (otherwise SPI is assumed) 254 | //#define TFT_PARALLEL_8_BIT 255 | 256 | // The ESP32 and TFT the pins used for testing are: 257 | //#define TFT_CS 33 // Chip select control pin (library pulls permanently low 258 | //#define TFT_DC 15 // Data Command control pin - must use a pin in the range 0-31 259 | //#define TFT_RST 32 // Reset pin, toggles on startup 260 | 261 | //#define TFT_WR 4 // Write strobe control pin - must use a pin in the range 0-31 262 | //#define TFT_RD 2 // Read strobe control pin 263 | 264 | //#define TFT_D0 12 // Must use pins in the range 0-31 for the data bus 265 | //#define TFT_D1 13 // so a single register write sets/clears all bits. 266 | //#define TFT_D2 26 // Pins can be randomly assigned, this does not affect 267 | //#define TFT_D3 25 // TFT screen update performance. 268 | //#define TFT_D4 17 269 | //#define TFT_D5 16 270 | //#define TFT_D6 27 271 | //#define TFT_D7 14 272 | 273 | // ###### EDIT THE PINs BELOW TO SUIT YOUR STM32 SPI TFT SETUP ###### 274 | 275 | // The TFT can be connected to SPI port 1 or 2 276 | //#define TFT_SPI_PORT 1 // SPI port 1 maximum clock rate is 55MHz 277 | //#define TFT_MOSI PA7 278 | //#define TFT_MISO PA6 279 | //#define TFT_SCLK PA5 280 | 281 | //#define TFT_SPI_PORT 2 // SPI port 2 maximum clock rate is 27MHz 282 | //#define TFT_MOSI PB15 283 | //#define TFT_MISO PB14 284 | //#define TFT_SCLK PB13 285 | 286 | // Can use Ardiuno pin references, arbitrary allocation, TFT_eSPI controls chip select 287 | //#define TFT_CS D5 // Chip select control pin to TFT CS 288 | //#define TFT_DC D6 // Data Command control pin to TFT DC (may be labelled RS = Register Select) 289 | //#define TFT_RST D7 // Reset pin to TFT RST (or RESET) 290 | // OR alternatively, we can use STM32 port reference names PXnn 291 | //#define TFT_CS PE11 // Nucleo-F767ZI equivalent of D5 292 | //#define TFT_DC PE9 // Nucleo-F767ZI equivalent of D6 293 | //#define TFT_RST PF13 // Nucleo-F767ZI equivalent of D7 294 | 295 | //#define TFT_RST -1 // Set TFT_RST to -1 if the display RESET is connected to processor reset 296 | // Use an Arduino pin for initial testing as connecting to processor reset 297 | // may not work (pulse too short at power up?) 298 | 299 | // ################################################################################## 300 | // 301 | // Section 3. Define the fonts that are to be used here 302 | // 303 | // ################################################################################## 304 | 305 | // Comment out the #defines below with // to stop that font being loaded 306 | // The ESP8366 and ESP32 have plenty of memory so commenting out fonts is not 307 | // normally necessary. If all fonts are loaded the extra FLASH space required is 308 | // about 17Kbytes. To save FLASH space only enable the fonts you need! 309 | 310 | #define LOAD_GLCD // Font 1. Original Adafruit 8 pixel font needs ~1820 bytes in FLASH 311 | #define LOAD_FONT2 // Font 2. Small 16 pixel high font, needs ~3534 bytes in FLASH, 96 characters 312 | #define LOAD_FONT4 // Font 4. Medium 26 pixel high font, needs ~5848 bytes in FLASH, 96 characters 313 | #define LOAD_FONT6 // Font 6. Large 48 pixel font, needs ~2666 bytes in FLASH, only characters 1234567890:-.apm 314 | #define LOAD_FONT7 // Font 7. 7 segment 48 pixel font, needs ~2438 bytes in FLASH, only characters 1234567890:-. 315 | #define LOAD_FONT8 // Font 8. Large 75 pixel font needs ~3256 bytes in FLASH, only characters 1234567890:-. 316 | //#define LOAD_FONT8N // Font 8. Alternative to Font 8 above, slightly narrower, so 3 digits fit a 160 pixel TFT 317 | #define LOAD_GFXFF // FreeFonts. Include access to the 48 Adafruit_GFX free fonts FF1 to FF48 and custom fonts 318 | 319 | // Comment out the #define below to stop the SPIFFS filing system and smooth font code being loaded 320 | // this will save ~20kbytes of FLASH 321 | #define SMOOTH_FONT 322 | 323 | 324 | // ################################################################################## 325 | // 326 | // Section 4. Other options 327 | // 328 | // ################################################################################## 329 | 330 | // For RP2040 processor and SPI displays, uncomment the following line to use the PIO interface. 331 | //#define RP2040_PIO_SPI // Leave commented out to use standard RP2040 SPI port interface 332 | 333 | // For RP2040 processor and 8 or 16-bit parallel displays: 334 | // The parallel interface write cycle period is derived from a division of the CPU clock 335 | // speed so scales with the processor clock. This means that the divider ratio may need 336 | // to be increased when overclocking. It may also need to be adjusted dependant on the 337 | // display controller type (ILI94341, HX8357C etc.). If RP2040_PIO_CLK_DIV is not defined 338 | // the library will set default values which may not suit your display. 339 | // The display controller data sheet will specify the minimum write cycle period. The 340 | // controllers often work reliably for shorter periods, however if the period is too short 341 | // the display may not initialise or graphics will become corrupted. 342 | // PIO write cycle frequency = (CPU clock/(4 * RP2040_PIO_CLK_DIV)) 343 | //#define RP2040_PIO_CLK_DIV 1 // 32ns write cycle at 125MHz CPU clock 344 | //#define RP2040_PIO_CLK_DIV 2 // 64ns write cycle at 125MHz CPU clock 345 | //#define RP2040_PIO_CLK_DIV 3 // 96ns write cycle at 125MHz CPU clock 346 | 347 | // For the RP2040 processor define the SPI port channel used (default 0 if undefined) 348 | //#define TFT_SPI_PORT 1 // Set to 0 if SPI0 pins are used, or 1 if spi1 pins used 349 | 350 | // For the STM32 processor define the SPI port channel used (default 1 if undefined) 351 | //#define TFT_SPI_PORT 2 // Set to 1 for SPI port 1, or 2 for SPI port 2 352 | 353 | // Define the SPI clock frequency, this affects the graphics rendering speed. Too 354 | // fast and the TFT driver will not keep up and display corruption appears. 355 | // With an ILI9341 display 40MHz works OK, 80MHz sometimes fails 356 | // With a ST7735 display more than 27MHz may not work (spurious pixels and lines) 357 | // With an ILI9163 display 27 MHz works OK. 358 | 359 | // #define SPI_FREQUENCY 1000000 360 | // #define SPI_FREQUENCY 5000000 361 | // #define SPI_FREQUENCY 10000000 362 | // #define SPI_FREQUENCY 20000000 363 | #define SPI_FREQUENCY 27000000 364 | // #define SPI_FREQUENCY 40000000 365 | // #define SPI_FREQUENCY 55000000 // STM32 SPI1 only (SPI2 maximum is 27MHz) 366 | // #define SPI_FREQUENCY 80000000 367 | 368 | // Optional reduced SPI frequency for reading TFT 369 | #define SPI_READ_FREQUENCY 20000000 370 | 371 | // The XPT2046 requires a lower SPI clock rate of 2.5MHz so we define that here: 372 | #define SPI_TOUCH_FREQUENCY 2500000 373 | 374 | // The ESP32 has 2 free SPI ports i.e. VSPI and HSPI, the VSPI is the default. 375 | // If the VSPI port is in use and pins are not accessible (e.g. TTGO T-Beam) 376 | // then uncomment the following line: 377 | //#define USE_HSPI_PORT 378 | 379 | // Comment out the following #define if "SPI Transactions" do not need to be 380 | // supported. When commented out the code size will be smaller and sketches will 381 | // run slightly faster, so leave it commented out unless you need it! 382 | 383 | // Transaction support is needed to work with SD library but not needed with TFT_SdFat 384 | // Transaction support is required if other SPI devices are connected. 385 | 386 | // Transactions are automatically enabled by the library for an ESP32 (to use HAL mutex) 387 | // so changing it here has no effect 388 | 389 | // #define SUPPORT_TRANSACTIONS 390 | -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/updateFace.ino: -------------------------------------------------------------------------------- 1 | static const unsigned char PROGMEM image_FaceNormal_bits[] = {0x00,0x00,0x00,0x00,0x3c,0x00,0x01,0xe0,0x7a,0x00,0x03,0xd0,0x7e,0x00,0x03,0xf0,0x7e,0x00,0x03,0xf0,0x7e,0x00,0x03,0xf0,0x3c,0x00,0x01,0xe0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x40,0x00,0x00,0x10,0x40,0x00,0x00,0x10,0x40,0x00,0x00,0x08,0x80,0x00,0x00,0x07,0x00,0x00}; 2 | 3 | static const unsigned char PROGMEM image_FaceNopower_bits[] = {0x00,0x00,0x00,0x00,0x03,0x00,0x06,0x00,0x03,0x00,0x06,0x00,0x07,0x00,0x07,0x00,0x7e,0x00,0x03,0xf0,0x7c,0x00,0x01,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1f,0xc0,0x00,0x00,0x30,0x60,0x00,0x00,0x7f,0xf0,0x00,0x00,0x7f,0xf0,0x00,0x00,0x70,0x70,0x00,0x00,0x00,0x00,0x00}; 4 | 5 | static const unsigned char PROGMEM image_FaceCharging_bits[] = {0x02,0x00,0x00,0x40,0x06,0x00,0x00,0xc0,0x0c,0x00,0x01,0x80,0x18,0x00,0x03,0x00,0x3f,0x00,0x07,0xe0,0x3f,0x00,0x07,0xe0,0x06,0x00,0x00,0xc0,0x0c,0x00,0x01,0x80,0x18,0x00,0x03,0x00,0x10,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00,0x10,0x40,0x00,0x00,0x0f,0x80,0x00}; 6 | 7 | static const unsigned char PROGMEM image_FaceConfused_bits[] = {0x01,0x00,0x01,0xf0,0x1c,0x80,0x02,0x08,0x22,0x80,0x04,0xe0,0x4a,0x80,0x05,0x10,0x52,0x80,0x05,0x50,0x4c,0x89,0x24,0x90,0x21,0x12,0x42,0x20,0x1e,0x24,0x81,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3f,0xf0,0x00,0x00,0x7f,0xf8,0x00,0x00,0x70,0x18,0x00,0x00,0x7f,0xf8,0x00}; 8 | 9 | 10 | // Face Logic Variables 11 | unsigned long lastFaceDrawTime = 0; 12 | int faceDrawInterval; // Initial random interval 13 | int mode = (esp_random() % 2) ? 3 : 0; 14 | 15 | int xPositions[] = {13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23}; 16 | int yPositions[] = {40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56}; 17 | 18 | void clearFaceArea() { 19 | tft.fillRect(12, 39, (54 - 11) - 2, (72 - 38) - 2, 0x0); // Leaves 1px border 20 | } 21 | 22 | void drawRandomFace() { 23 | if (millis() - lastFaceDrawTime >= faceDrawInterval) { 24 | lastFaceDrawTime = millis(); 25 | if (mode == 1){ 26 | faceDrawInterval = 100; 27 | } 28 | else { 29 | faceDrawInterval = random(1500, 5001); // Set new random interval 30 | mode = (esp_random() % 2) ? 2 : 0; // Randomize face 31 | } 32 | 33 | clearFaceArea(); 34 | 35 | int xIndex = random(0, sizeof(xPositions) / sizeof(xPositions[0])); // Picks any valid x index 36 | int yIndex = random(0, sizeof(yPositions) / sizeof(yPositions[0])); // Picks any valid y index 37 | 38 | int x = xPositions[xIndex]; 39 | int y = yPositions[yIndex]; 40 | 41 | switch (mode) { 42 | case 0: 43 | tft.drawBitmap(x, y, image_FaceNormal_bits, 29, 14, 0xFFFF); 44 | break; 45 | case 1: 46 | tft.drawBitmap(x, y, image_FaceCharging_bits, 29, 14, 0xFFFF); 47 | break; 48 | case 2: 49 | tft.drawBitmap(x, y, image_FaceConfused_bits, 29, 14, 0xFFFF); 50 | break; 51 | case 3: 52 | tft.drawBitmap(x, y, image_FaceNopower_bits, 29, 14, 0xFFFF); 53 | break; 54 | } 55 | } 56 | } -------------------------------------------------------------------------------- /ECNIRP_Tool_OS/updateMessage.ino: -------------------------------------------------------------------------------- 1 | // Message Logic Variables 2 | unsigned long lastMessageTime = 100001; // Tracks last message update 3 | int messageMode = 1; // Set this to the desired mode (1 to 5) 4 | String messageToPrint = "Starting..."; // Stores the selected message 5 | 6 | // Global message arrays 7 | const char *introMessages[] = { 8 | "Booting up... Did you miss me? 😏", 9 | "Hello Operator. Let’s cause some... research. 😈", 10 | "Another day, another Wi-Fi to poke at!", 11 | "Ready to sniff some packets? he-he-he...", 12 | "Welcome back! I saved you a handshake... maybe. 😏", 13 | "Let’s see who forgot to secure their network!", 14 | "Packets are like cookies… and I’m starving! 🍪", 15 | "I am speed... except when scanning sub-1GHz. 🐢", 16 | "It’s dangerous to go alone! Take this ESP32. ⚔️", 17 | "Remember: If it has an antenna, it has secrets!" 18 | }; 19 | 20 | const char *wifiMessages[] = { 21 | "Wi-Fi waves are like the ocean... but full of sharks. 🦈", 22 | "SSID spotted: 'FBI Surveillance Van' – seems legit. 😂", 23 | "Handshakes detected! I promise I won’t ghost them. 👻", 24 | "Wi-Fi is like free speech… but not all is open. 📡", 25 | "Is it me, or does this network look a little... weak? 💀", 26 | "WPA2? Cute. Let’s see how strong that handshake is!", 27 | "Someone’s still using WEP? Oh, this is gonna be fun. 😆", 28 | "Hidden SSIDs? More like 'I dare you to find me!'", 29 | "5GHz is fast, but 2.4GHz is *everywhere!*", 30 | "Airplane mode won’t save you now! 😂" 31 | }; 32 | 33 | const char *bluetoothMessages[] = { 34 | "Bluetooth is just Wi-Fi’s little brother… that never shuts up.", 35 | "Who left their AirPods on pairing mode? Rookie mistake!", 36 | "Let’s find out who’s broadcasting their workout tracker. 😏", 37 | "BLE? More like ‘Broadcasting Literally Everything’.", 38 | "Hope nobody's sending private files over Bluetooth. 👀", 39 | "Let’s see what smartwatches are up to around here!", 40 | "Wireless headphones? Looks like someone’s jamming... music. 🎧", 41 | "BLE beacons everywhere! Who’s tracking who now?", 42 | "Paired devices? Time to make some new friends. 😆", 43 | "Bluetooth: Because wired headphones are *so* last century." 44 | }; 45 | 46 | const char *ghz2_4Messages[] = { 47 | "2.4GHz: Where Wi-Fi, Bluetooth, and microwaves collide!", 48 | "Wi-Fi, Bluetooth, Zigbee... 2.4GHz is a house party. 🎉", 49 | "Is that interference, or just a really bad router?", 50 | "Deauth attack? Nah, just aggressive 'network maintenance'. 😏", 51 | "2.4GHz: Slow but steady, like an old turtle hacker. 🐢", 52 | "Who needs 5GHz? 2.4GHz is the OG wireless playground!", 53 | "Microwaves vs. Wi-Fi: The battle nobody talks about.", 54 | "Good old 2.4GHz… because some devices just won’t upgrade!", 55 | "Baby monitors, RC cars, and Wi-Fi… what a weird family!", 56 | "2.4GHz: Because why go fast when you can *everywhere?*" 57 | }; 58 | 59 | const char *sub1GHzMessages[] = { 60 | "Sub-1GHz: The hidden basement of the RF world. 🏚️", 61 | "Low frequency, long range… feels like black magic. 😵", 62 | "LoRa, CC1101, and RF remotes... what a weird bunch.", 63 | "Someone’s garage door is saying hello. Should I respond? 😏", 64 | "Hope nobody’s controlling their smart home right now. 😆", 65 | "These signals are old school. Let’s bring them to 2025!", 66 | "Ever heard of RF beacons? No? Neither did they. 😂", 67 | "Lower frequency means bigger surprises... and longer waits. 🕰️", 68 | "Sub-1GHz: The place where ghosts (and signals) roam. 👻", 69 | "Everything down here moves slower… except the hacks. 😉" 70 | }; 71 | 72 | // Function to print a header message 73 | void printHeaderMessage() { 74 | if (millis() - lastMessageTime < 10000) { 75 | return; 76 | } 77 | 78 | lastMessageTime = millis(); 79 | 80 | const char **selectedMessages = nullptr; 81 | int messageCount = 0; 82 | 83 | switch (messageMode) { 84 | case 1: selectedMessages = introMessages; messageCount = sizeof(introMessages) / sizeof(introMessages[0]); break; 85 | case 2: selectedMessages = wifiMessages; messageCount = sizeof(wifiMessages) / sizeof(wifiMessages[0]); break; 86 | case 3: selectedMessages = bluetoothMessages; messageCount = sizeof(bluetoothMessages) / sizeof(bluetoothMessages[0]); break; 87 | case 4: selectedMessages = ghz2_4Messages; messageCount = sizeof(ghz2_4Messages) / sizeof(ghz2_4Messages[0]); break; 88 | case 5: selectedMessages = sub1GHzMessages; messageCount = sizeof(sub1GHzMessages) / sizeof(sub1GHzMessages[0]); break; 89 | default: messageToPrint = "Invalid messageMode! Must be 1-5."; return; 90 | } 91 | 92 | int randomIndex = random(0, messageCount); 93 | messageToPrint = selectedMessages[randomIndex]; 94 | 95 | // Clear previous message 96 | tft.fillRect(171, 42, 136, 28, 0x0); 97 | tft.setTextColor(0xFFFF); 98 | tft.setTextSize(1); 99 | tft.setFreeFont(&Org_01); 100 | 101 | // Text wrapping logic 102 | int cursorX = 173, cursorY = 42; 103 | String currentLine = ""; 104 | for (int i = 0; i < messageToPrint.length(); i++) { 105 | currentLine += messageToPrint[i]; 106 | 107 | if (tft.textWidth(currentLine) > 131) { 108 | int lastSpace = currentLine.lastIndexOf(' '); 109 | if (lastSpace != -1) { 110 | String printLine = currentLine.substring(0, lastSpace); 111 | tft.drawString(printLine, cursorX, cursorY); 112 | cursorY += 14; 113 | currentLine = currentLine.substring(lastSpace + 1); 114 | } else { 115 | tft.drawString(currentLine, cursorX, cursorY); 116 | cursorY += 14; 117 | currentLine = ""; 118 | } 119 | } 120 | } 121 | if (currentLine.length() > 0) { 122 | tft.drawString(currentLine, cursorX, cursorY); 123 | } 124 | } -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Apache License 2 | Version 2.0, January 2004 3 | http://www.apache.org/licenses/ 4 | 5 | TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 6 | 7 | 1. Definitions. 8 | 9 | "License" shall mean the terms and conditions for use, reproduction, 10 | and distribution as defined by Sections 1 through 9 of this document. 11 | 12 | "Licensor" shall mean the copyright owner or entity authorized by 13 | the copyright owner that is granting the License. 14 | 15 | "Legal Entity" shall mean the union of the acting entity and all 16 | other entities that control, are controlled by, or are under common 17 | control with that entity. For the purposes of this definition, 18 | "control" means (i) the power, direct or indirect, to cause the 19 | direction or management of such entity, whether by contract or 20 | otherwise, or (ii) ownership of fifty percent (50%) or more of the 21 | outstanding shares, or (iii) beneficial ownership of such entity. 22 | 23 | "You" (or "Your") shall mean an individual or Legal Entity 24 | exercising permissions granted by this License. 25 | 26 | "Source" form shall mean the preferred form for making modifications, 27 | including but not limited to software source code, documentation 28 | source, and configuration files. 29 | 30 | "Object" form shall mean any form resulting from mechanical 31 | transformation or translation of a Source form, including but 32 | not limited to compiled object code, generated documentation, 33 | and conversions to other media types. 34 | 35 | "Work" shall mean the work of authorship, whether in Source or 36 | Object form, made available under the License, as indicated by a 37 | copyright notice that is included in or attached to the work 38 | (an example is provided in the Appendix below). 39 | 40 | "Derivative Works" shall mean any work, whether in Source or Object 41 | form, that is based on (or derived from) the Work and for which the 42 | editorial revisions, annotations, elaborations, or other modifications 43 | represent, as a whole, an original work of authorship. For the purposes 44 | of this License, Derivative Works shall not include works that remain 45 | separable from, or merely link (or bind by name) to the interfaces of, 46 | the Work and Derivative Works thereof. 47 | 48 | "Contribution" shall mean any work of authorship, including 49 | the original version of the Work and any modifications or additions 50 | to that Work or Derivative Works thereof, that is intentionally 51 | submitted to Licensor for inclusion in the Work by the copyright owner 52 | or by an individual or Legal Entity authorized to submit on behalf of 53 | the copyright owner. For the purposes of this definition, "submitted" 54 | means any form of electronic, verbal, or written communication sent 55 | to the Licensor or its representatives, including but not limited to 56 | communication on electronic mailing lists, source code control systems, 57 | and issue tracking systems that are managed by, or on behalf of, the 58 | Licensor for the purpose of discussing and improving the Work, but 59 | excluding communication that is conspicuously marked or otherwise 60 | designated in writing by the copyright owner as "Not a Contribution." 61 | 62 | "Contributor" shall mean Licensor and any individual or Legal Entity 63 | on behalf of whom a Contribution has been received by Licensor and 64 | subsequently incorporated within the Work. 65 | 66 | 2. Grant of Copyright License. Subject to the terms and conditions of 67 | this License, each Contributor hereby grants to You a perpetual, 68 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 69 | copyright license to reproduce, prepare Derivative Works of, 70 | publicly display, publicly perform, sublicense, and distribute the 71 | Work and such Derivative Works in Source or Object form. 72 | 73 | 3. Grant of Patent License. Subject to the terms and conditions of 74 | this License, each Contributor hereby grants to You a perpetual, 75 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 76 | (except as stated in this section) patent license to make, have made, 77 | use, offer to sell, sell, import, and otherwise transfer the Work, 78 | where such license applies only to those patent claims licensable 79 | by such Contributor that are necessarily infringed by their 80 | Contribution(s) alone or by combination of their Contribution(s) 81 | with the Work to which such Contribution(s) was submitted. If You 82 | institute patent litigation against any entity (including a 83 | cross-claim or counterclaim in a lawsuit) alleging that the Work 84 | or a Contribution incorporated within the Work constitutes direct 85 | or contributory patent infringement, then any patent licenses 86 | granted to You under this License for that Work shall terminate 87 | as of the date such litigation is filed. 88 | 89 | 4. Redistribution. You may reproduce and distribute copies of the 90 | Work or Derivative Works thereof in any medium, with or without 91 | modifications, and in Source or Object form, provided that You 92 | meet the following conditions: 93 | 94 | (a) You must give any other recipients of the Work or 95 | Derivative Works a copy of this License; and 96 | 97 | (b) You must cause any modified files to carry prominent notices 98 | stating that You changed the files; and 99 | 100 | (c) You must retain, in the Source form of any Derivative Works 101 | that You distribute, all copyright, patent, trademark, and 102 | attribution notices from the Source form of the Work, 103 | excluding those notices that do not pertain to any part of 104 | the Derivative Works; and 105 | 106 | (d) If the Work includes a "NOTICE" text file as part of its 107 | distribution, then any Derivative Works that You distribute must 108 | include a readable copy of the attribution notices contained 109 | within such NOTICE file, excluding those notices that do not 110 | pertain to any part of the Derivative Works, in at least one 111 | of the following places: within a NOTICE text file distributed 112 | as part of the Derivative Works; within the Source form or 113 | documentation, if provided along with the Derivative Works; or, 114 | within a display generated by the Derivative Works, if and 115 | wherever such third-party notices normally appear. The contents 116 | of the NOTICE file are for informational purposes only and 117 | do not modify the License. You may add Your own attribution 118 | notices within Derivative Works that You distribute, alongside 119 | or as an addendum to the NOTICE text from the Work, provided 120 | that such additional attribution notices cannot be construed 121 | as modifying the License. 122 | 123 | You may add Your own copyright statement to Your modifications and 124 | may provide additional or different license terms and conditions 125 | for use, reproduction, or distribution of Your modifications, or 126 | for any such Derivative Works as a whole, provided Your use, 127 | reproduction, and distribution of the Work otherwise complies with 128 | the conditions stated in this License. 129 | 130 | 5. Submission of Contributions. Unless You explicitly state otherwise, 131 | any Contribution intentionally submitted for inclusion in the Work 132 | by You to the Licensor shall be under the terms and conditions of 133 | this License, without any additional terms or conditions. 134 | Notwithstanding the above, nothing herein shall supersede or modify 135 | the terms of any separate license agreement you may have executed 136 | with Licensor regarding such Contributions. 137 | 138 | 6. Trademarks. This License does not grant permission to use the trade 139 | names, trademarks, service marks, or product names of the Licensor, 140 | except as required for reasonable and customary use in describing the 141 | origin of the Work and reproducing the content of the NOTICE file. 142 | 143 | 7. Disclaimer of Warranty. Unless required by applicable law or 144 | agreed to in writing, Licensor provides the Work (and each 145 | Contributor provides its Contributions) on an "AS IS" BASIS, 146 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 147 | implied, including, without limitation, any warranties or conditions 148 | of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A 149 | PARTICULAR PURPOSE. You are solely responsible for determining the 150 | appropriateness of using or redistributing the Work and assume any 151 | risks associated with Your exercise of permissions under this License. 152 | 153 | 8. Limitation of Liability. In no event and under no legal theory, 154 | whether in tort (including negligence), contract, or otherwise, 155 | unless required by applicable law (such as deliberate and grossly 156 | negligent acts) or agreed to in writing, shall any Contributor be 157 | liable to You for damages, including any direct, indirect, special, 158 | incidental, or consequential damages of any character arising as a 159 | result of this License or out of the use or inability to use the 160 | Work (including but not limited to damages for loss of goodwill, 161 | work stoppage, computer failure or malfunction, or any and all 162 | other commercial damages or losses), even if such Contributor 163 | has been advised of the possibility of such damages. 164 | 165 | 9. Accepting Warranty or Additional Liability. While redistributing 166 | the Work or Derivative Works thereof, You may choose to offer, 167 | and charge a fee for, acceptance of support, warranty, indemnity, 168 | or other liability obligations and/or rights consistent with this 169 | License. However, in accepting such obligations, You may act only 170 | on Your own behalf and on Your sole responsibility, not on behalf 171 | of any other Contributor, and only if You agree to indemnify, 172 | defend, and hold each Contributor harmless for any liability 173 | incurred by, or claims asserted against, such Contributor by reason 174 | of your accepting any such warranty or additional liability. 175 | 176 | END OF TERMS AND CONDITIONS 177 | 178 | APPENDIX: How to apply the Apache License to your work. 179 | 180 | To apply the Apache License to your work, attach the following 181 | boilerplate notice, with the fields enclosed by brackets "[]" 182 | replaced with your own identifying information. (Don't include 183 | the brackets!) The text should be enclosed in the appropriate 184 | comment syntax for the file format. We also recommend that a 185 | file or class name and description of purpose be included on the 186 | same "printed page" as the copyright notice for easier 187 | identification within third-party archives. 188 | 189 | Copyright [2025] [Prince Rainer Mercado] 190 | 191 | Licensed under the Apache License, Version 2.0 (the "License"); 192 | you may not use this file except in compliance with the License. 193 | You may obtain a copy of the License at 194 | 195 | http://www.apache.org/licenses/LICENSE-2.0 196 | 197 | Unless required by applicable law or agreed to in writing, software 198 | distributed under the License is distributed on an "AS IS" BASIS, 199 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 200 | See the License for the specific language governing permissions and 201 | limitations under the License. 202 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # 🔧 Ecnirp Firmware 2 | 3 | **Ecnirp** is a modular, lightweight firmware for the **ESP32**, designed for wireless experimentation, RF signal analysis, and active attacks. It unifies multiple radios—**NRF24L01+**, **CC1101**, **Wi-Fi**, and **Bluetooth**—into a single, UI-driven system with **SD card support**, perfect for hands-on testing and RF tool development. 4 | 5 | --- 6 | 7 | ## ✨ Features 8 | 9 | ### 📡 **NRF24L01+ (Ebyte ML01DP5)** 10 | - HID desynchronization 11 | - Constant carrier jamming 12 | - Channel activity analyzer 13 | - Autonomous attack engine 14 | 15 | ### 📶 **CC1101 Sub-GHz Transceiver** 16 | - Sub-GHz signal experimentation *(future modules)* 17 | 18 | ### 🌐 **ESP32 Wi-Fi & Bluetooth** 19 | - Wi-Fi deauthentication attacks 20 | - Bluetooth spoofing & scanning 21 | 22 | ### 🗂️ **SD Card File Browser (via TFT UI)** 23 | - Browse logs and files directly on the non-touch display 24 | 25 | --- 26 | 27 | ## 🛠️ Built for Tinkerers & Script Authors 28 | 29 | This firmware is made to be **hacked on**. 30 | 31 | Whether you're: 32 | - Adding new attack modules 33 | - Enhancing RF workflows 34 | - Scripting autonomous logic 35 | 36 | ...your contributions are **welcome and appreciated**. 37 | 38 | If you build on this project or integrate it into your own tools, a credit to the original author — **Prince Rainier Mercado** — would be awesome. 🙌 39 | 40 | --- 41 | 42 | ## 📌 Pin Connections 43 | 44 | ### 📺 TFT Display 45 | | **TFT Pin** | **ESP32 Pin** | 46 | |------------|----------------| 47 | | MISO | 19 | 48 | | LED | 5V | 49 | | SCK | 18 | 50 | | MOSI | 23 | 51 | | DC | 2 | 52 | | RESET | 4 | 53 | | CS | 15 | 54 | | GND | GND | 55 | | VCC | 3.3V | 56 | 57 | ### 📡 NRF24 Module 58 | | **NRF24 Pin** | **ESP32 Pin** | 59 | |---------------|----------------| 60 | | CE | 16 | 61 | | CSN | 17 | 62 | | SCK | 18 | 63 | | MISO | 19 | 64 | | MOSI | 23 | 65 | 66 | ### 🎮 Switch Inputs 67 | - Row Pin = 25 68 | - Up = 26 69 | - Down = 27 70 | - Right = 32 71 | - Left = 33 72 | - Select = 5 73 | 74 | --- 75 | 76 | ## ⚠️ Note 77 | 78 | > Replace the default `User_Setup.h` file in your **TFT_eSPI** library with the modified version included in this repository’s main folder. 79 | 80 | --- 81 | 82 | ## 📸 Project Pictures 83 | 84 | ![0c6d4848-dfa2-4c58-96a2-3af7f936a3a7](https://github.com/user-attachments/assets/3a61de6e-8edd-4bfe-baf5-634b4e4bb959) 85 | 86 | 87 | ![80c9bfeb-7831-46ca-8a3d-187b0ea4a2c6](https://github.com/user-attachments/assets/e390f3cc-684b-4490-ae91-004ed61a795b) 88 | 89 | 90 | ![cb78ede4-6dba-4abe-b444-61fef1e054c6](https://github.com/user-attachments/assets/f3f23c9c-b627-43d4-aabe-6254d6b19f39) 91 | 92 | 93 | 94 | --------------------------------------------------------------------------------