Browse Source

Add Support TinyBoy2 OLED/Encoder panel

The OLED is driven by an SSD1306, connected to the board via
I2C, the rotary encoder is connected to 3 GPIO pins.

Signed-off-by: Stefan Brüns <stefan.bruens@rwth-aachen.de>
Stefan Brüns 7 years ago
parent
commit
0fe57ad4f5
25 changed files with 128 additions and 4 deletions
  1. 9
    1
      Marlin/Conditionals_LCD.h
  2. 5
    0
      Marlin/Configuration.h
  3. 4
    1
      Marlin/SanityCheck.h
  4. 5
    0
      Marlin/example_configurations/Cartesio/Configuration.h
  5. 5
    0
      Marlin/example_configurations/Felix/Configuration.h
  6. 5
    0
      Marlin/example_configurations/Felix/DUAL/Configuration.h
  7. 5
    0
      Marlin/example_configurations/Hephestos/Configuration.h
  8. 5
    0
      Marlin/example_configurations/Hephestos_2/Configuration.h
  9. 5
    0
      Marlin/example_configurations/K8200/Configuration.h
  10. 5
    0
      Marlin/example_configurations/K8400/Configuration.h
  11. 5
    0
      Marlin/example_configurations/K8400/Dual-head/Configuration.h
  12. 5
    0
      Marlin/example_configurations/RepRapWorld/Megatronics/Configuration.h
  13. 5
    0
      Marlin/example_configurations/RigidBot/Configuration.h
  14. 5
    0
      Marlin/example_configurations/SCARA/Configuration.h
  15. 5
    0
      Marlin/example_configurations/TAZ4/Configuration.h
  16. 5
    0
      Marlin/example_configurations/WITBOX/Configuration.h
  17. 5
    0
      Marlin/example_configurations/adafruit/ST7565/Configuration.h
  18. 5
    0
      Marlin/example_configurations/delta/flsun_kossel_mini/Configuration.h
  19. 5
    0
      Marlin/example_configurations/delta/generic/Configuration.h
  20. 5
    0
      Marlin/example_configurations/delta/kossel_mini/Configuration.h
  21. 5
    0
      Marlin/example_configurations/delta/kossel_pro/Configuration.h
  22. 5
    0
      Marlin/example_configurations/delta/kossel_xl/Configuration.h
  23. 5
    0
      Marlin/example_configurations/makibox/Configuration.h
  24. 5
    0
      Marlin/example_configurations/tvrrug/Round2/Configuration.h
  25. 5
    2
      Marlin/pins_SANGUINOLOLU_11.h

+ 9
- 1
Marlin/Conditionals_LCD.h View File

@@ -67,6 +67,14 @@
67 67
 
68 68
   #endif
69 69
 
70
+  #if ENABLED(OLED_PANEL_TINYBOY2)
71
+    #define U8GLIB_SSD1306
72
+    #define ULTIPANEL
73
+    #define NEWPANEL
74
+    #define REVERSE_ENCODER_DIRECTION
75
+    #define REVERSE_MENU_DIRECTION
76
+  #endif
77
+
70 78
   // Generic support for SSD1306 / SH1106 OLED based LCDs.
71 79
   #if ENABLED(U8GLIB_SSD1306) || ENABLED(U8GLIB_SH1106)
72 80
     #define ULTRA_LCD  //general LCD support, also 16x2
@@ -158,7 +166,7 @@
158 166
   #endif
159 167
 
160 168
   // Set encoder detents for well-known controllers
161
-  #if ENABLED(miniVIKI) || ENABLED(VIKI2) || ENABLED(ELB_FULL_GRAPHIC_CONTROLLER) \
169
+  #if ENABLED(miniVIKI) || ENABLED(VIKI2) || ENABLED(ELB_FULL_GRAPHIC_CONTROLLER) || ENABLED(OLED_PANEL_TINYBOY2) \
162 170
    || ENABLED(BQ_LCD_SMART_CONTROLLER) || ENABLED(LCD_I2C_PANELOLU2) || ENABLED(REPRAP_DISCOUNT_SMART_CONTROLLER)
163 171
     #ifndef ENCODER_PULSES_PER_STEP
164 172
       #define ENCODER_PULSES_PER_STEP 4

+ 5
- 0
Marlin/Configuration.h View File

@@ -1405,6 +1405,11 @@
1405 1405
 //
1406 1406
 //#define SAV_3DLCD
1407 1407
 
1408
+//
1409
+// TinyBoy2 128x64 OLED / Encoder Panel
1410
+//
1411
+//#define OLED_PANEL_TINYBOY2
1412
+
1408 1413
 //=============================================================================
1409 1414
 //=============================== Extra Features ==============================
1410 1415
 //=============================================================================

+ 4
- 1
Marlin/SanityCheck.h View File

@@ -1017,7 +1017,7 @@ static_assert(1 >= 0
1017 1017
   #if ENABLED(LCD_I2C_VIKI)
1018 1018
     + 1
1019 1019
   #endif
1020
-  #if ENABLED(U8GLIB_SSD1306)
1020
+  #if ENABLED(U8GLIB_SSD1306) && DISABLED(OLED_PANEL_TINYBOY2)
1021 1021
     + 1
1022 1022
   #endif
1023 1023
   #if ENABLED(SAV_3DLCD)
@@ -1029,5 +1029,8 @@ static_assert(1 >= 0
1029 1029
   #if ENABLED(SAV_3DGLCD)
1030 1030
     + 1
1031 1031
   #endif
1032
+  #if ENABLED(OLED_PANEL_TINYBOY2)
1033
+    + 1
1034
+  #endif
1032 1035
   , "Please select no more than one LCD controller option."
1033 1036
 );

+ 5
- 0
Marlin/example_configurations/Cartesio/Configuration.h View File

@@ -1406,6 +1406,11 @@
1406 1406
 //
1407 1407
 //#define SAV_3DLCD
1408 1408
 
1409
+//
1410
+// TinyBoy2 128x64 OLED / Encoder Panel
1411
+//
1412
+//#define OLED_PANEL_TINYBOY2
1413
+
1409 1414
 //=============================================================================
1410 1415
 //=============================== Extra Features ==============================
1411 1416
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/Felix/Configuration.h View File

@@ -1389,6 +1389,11 @@
1389 1389
 //
1390 1390
 //#define SAV_3DLCD
1391 1391
 
1392
+//
1393
+// TinyBoy2 128x64 OLED / Encoder Panel
1394
+//
1395
+//#define OLED_PANEL_TINYBOY2
1396
+
1392 1397
 //=============================================================================
1393 1398
 //=============================== Extra Features ==============================
1394 1399
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/Felix/DUAL/Configuration.h View File

@@ -1389,6 +1389,11 @@
1389 1389
 //
1390 1390
 //#define SAV_3DLCD
1391 1391
 
1392
+//
1393
+// TinyBoy2 128x64 OLED / Encoder Panel
1394
+//
1395
+//#define OLED_PANEL_TINYBOY2
1396
+
1392 1397
 //=============================================================================
1393 1398
 //=============================== Extra Features ==============================
1394 1399
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/Hephestos/Configuration.h View File

@@ -1398,6 +1398,11 @@
1398 1398
 //
1399 1399
 //#define SAV_3DLCD
1400 1400
 
1401
+//
1402
+// TinyBoy2 128x64 OLED / Encoder Panel
1403
+//
1404
+//#define OLED_PANEL_TINYBOY2
1405
+
1401 1406
 //=============================================================================
1402 1407
 //=============================== Extra Features ==============================
1403 1408
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/Hephestos_2/Configuration.h View File

@@ -1400,6 +1400,11 @@
1400 1400
 //
1401 1401
 //#define SAV_3DLCD
1402 1402
 
1403
+//
1404
+// TinyBoy2 128x64 OLED / Encoder Panel
1405
+//
1406
+//#define OLED_PANEL_TINYBOY2
1407
+
1403 1408
 //=============================================================================
1404 1409
 //=============================== Extra Features ==============================
1405 1410
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/K8200/Configuration.h View File

@@ -1438,6 +1438,11 @@
1438 1438
 //
1439 1439
 //#define SAV_3DLCD
1440 1440
 
1441
+//
1442
+// TinyBoy2 128x64 OLED / Encoder Panel
1443
+//
1444
+//#define OLED_PANEL_TINYBOY2
1445
+
1441 1446
 #endif // K8200_VM8201
1442 1447
 
1443 1448
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/K8400/Configuration.h View File

@@ -1406,6 +1406,11 @@
1406 1406
 //
1407 1407
 //#define SAV_3DLCD
1408 1408
 
1409
+//
1410
+// TinyBoy2 128x64 OLED / Encoder Panel
1411
+//
1412
+//#define OLED_PANEL_TINYBOY2
1413
+
1409 1414
 //=============================================================================
1410 1415
 //=============================== Extra Features ==============================
1411 1416
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/K8400/Dual-head/Configuration.h View File

@@ -1406,6 +1406,11 @@
1406 1406
 //
1407 1407
 //#define SAV_3DLCD
1408 1408
 
1409
+//
1410
+// TinyBoy2 128x64 OLED / Encoder Panel
1411
+//
1412
+//#define OLED_PANEL_TINYBOY2
1413
+
1409 1414
 //=============================================================================
1410 1415
 //=============================== Extra Features ==============================
1411 1416
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/RepRapWorld/Megatronics/Configuration.h View File

@@ -1406,6 +1406,11 @@
1406 1406
 //
1407 1407
 //#define SAV_3DLCD
1408 1408
 
1409
+//
1410
+// TinyBoy2 128x64 OLED / Encoder Panel
1411
+//
1412
+//#define OLED_PANEL_TINYBOY2
1413
+
1409 1414
 //=============================================================================
1410 1415
 //=============================== Extra Features ==============================
1411 1416
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/RigidBot/Configuration.h View File

@@ -1407,6 +1407,11 @@
1407 1407
 //
1408 1408
 //#define SAV_3DLCD
1409 1409
 
1410
+//
1411
+// TinyBoy2 128x64 OLED / Encoder Panel
1412
+//
1413
+//#define OLED_PANEL_TINYBOY2
1414
+
1410 1415
 //=============================================================================
1411 1416
 //=============================== Extra Features ==============================
1412 1417
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/SCARA/Configuration.h View File

@@ -1421,6 +1421,11 @@
1421 1421
 //
1422 1422
 //#define SAV_3DLCD
1423 1423
 
1424
+//
1425
+// TinyBoy2 128x64 OLED / Encoder Panel
1426
+//
1427
+//#define OLED_PANEL_TINYBOY2
1428
+
1424 1429
 //=============================================================================
1425 1430
 //=============================== Extra Features ==============================
1426 1431
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/TAZ4/Configuration.h View File

@@ -1427,6 +1427,11 @@
1427 1427
 //
1428 1428
 //#define SAV_3DLCD
1429 1429
 
1430
+//
1431
+// TinyBoy2 128x64 OLED / Encoder Panel
1432
+//
1433
+//#define OLED_PANEL_TINYBOY2
1434
+
1430 1435
 //=============================================================================
1431 1436
 //=============================== Extra Features ==============================
1432 1437
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/WITBOX/Configuration.h View File

@@ -1398,6 +1398,11 @@
1398 1398
 //
1399 1399
 //#define SAV_3DLCD
1400 1400
 
1401
+//
1402
+// TinyBoy2 128x64 OLED / Encoder Panel
1403
+//
1404
+//#define OLED_PANEL_TINYBOY2
1405
+
1401 1406
 //=============================================================================
1402 1407
 //=============================== Extra Features ==============================
1403 1408
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/adafruit/ST7565/Configuration.h View File

@@ -1406,6 +1406,11 @@
1406 1406
 //
1407 1407
 //#define SAV_3DLCD
1408 1408
 
1409
+//
1410
+// TinyBoy2 128x64 OLED / Encoder Panel
1411
+//
1412
+//#define OLED_PANEL_TINYBOY2
1413
+
1409 1414
 //=============================================================================
1410 1415
 //=============================== Extra Features ==============================
1411 1416
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/delta/flsun_kossel_mini/Configuration.h View File

@@ -1511,6 +1511,11 @@
1511 1511
 //
1512 1512
 //#define SAV_3DLCD
1513 1513
 
1514
+//
1515
+// TinyBoy2 128x64 OLED / Encoder Panel
1516
+//
1517
+//#define OLED_PANEL_TINYBOY2
1518
+
1514 1519
 //=============================================================================
1515 1520
 //=============================== Extra Features ==============================
1516 1521
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/delta/generic/Configuration.h View File

@@ -1496,6 +1496,11 @@
1496 1496
 //
1497 1497
 //#define SAV_3DLCD
1498 1498
 
1499
+//
1500
+// TinyBoy2 128x64 OLED / Encoder Panel
1501
+//
1502
+//#define OLED_PANEL_TINYBOY2
1503
+
1499 1504
 //=============================================================================
1500 1505
 //=============================== Extra Features ==============================
1501 1506
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/delta/kossel_mini/Configuration.h View File

@@ -1500,6 +1500,11 @@
1500 1500
 //
1501 1501
 //#define SAV_3DLCD
1502 1502
 
1503
+//
1504
+// TinyBoy2 128x64 OLED / Encoder Panel
1505
+//
1506
+//#define OLED_PANEL_TINYBOY2
1507
+
1503 1508
 //=============================================================================
1504 1509
 //=============================== Extra Features ==============================
1505 1510
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/delta/kossel_pro/Configuration.h View File

@@ -1499,6 +1499,11 @@
1499 1499
 //
1500 1500
 //#define SAV_3DLCD
1501 1501
 
1502
+//
1503
+// TinyBoy2 128x64 OLED / Encoder Panel
1504
+//
1505
+//#define OLED_PANEL_TINYBOY2
1506
+
1502 1507
 //=============================================================================
1503 1508
 //=============================== Extra Features ==============================
1504 1509
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/delta/kossel_xl/Configuration.h View File

@@ -1509,6 +1509,11 @@
1509 1509
 //
1510 1510
 //#define SAV_3DLCD
1511 1511
 
1512
+//
1513
+// TinyBoy2 128x64 OLED / Encoder Panel
1514
+//
1515
+//#define OLED_PANEL_TINYBOY2
1516
+
1512 1517
 //=============================================================================
1513 1518
 //=============================== Extra Features ==============================
1514 1519
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/makibox/Configuration.h View File

@@ -1409,6 +1409,11 @@
1409 1409
 //
1410 1410
 //#define SAV_3DLCD
1411 1411
 
1412
+//
1413
+// TinyBoy2 128x64 OLED / Encoder Panel
1414
+//
1415
+//#define OLED_PANEL_TINYBOY2
1416
+
1412 1417
 //=============================================================================
1413 1418
 //=============================== Extra Features ==============================
1414 1419
 //=============================================================================

+ 5
- 0
Marlin/example_configurations/tvrrug/Round2/Configuration.h View File

@@ -1402,6 +1402,11 @@
1402 1402
 //
1403 1403
 //#define SAV_3DLCD
1404 1404
 
1405
+//
1406
+// TinyBoy2 128x64 OLED / Encoder Panel
1407
+//
1408
+//#define OLED_PANEL_TINYBOY2
1409
+
1405 1410
 //=============================================================================
1406 1411
 //=============================== Extra Features ==============================
1407 1412
 //=============================================================================

+ 5
- 2
Marlin/pins_SANGUINOLOLU_11.h View File

@@ -188,10 +188,13 @@
188 188
     #else
189 189
       #define BTN_ENC           30
190 190
     #endif
191
-  #else  // !Panelolu2
191
+  #elif ENABLED(OLED_PANEL_TINYBOY2)
192
+    #define BTN_ENC             28
193
+    #define LCD_SDSS            -1
194
+  #else  // !Panelolu2, !TinyBoy2
192 195
     #define BTN_ENC             16
193 196
     #define LCD_SDSS            28 // Smart Controller SD card reader rather than the Melzi
194
-  #endif // !Panelolu2
197
+  #endif // !Panelolu2, !TinyBoy2
195 198
 
196 199
   #define SD_DETECT_PIN         -1
197 200
 

Loading…
Cancel
Save