Add Touch Calibration screen (#20049)
This commit is contained in:
		@@ -22,7 +22,7 @@
 | 
			
		||||
 | 
			
		||||
#include "../../../inc/MarlinConfig.h"
 | 
			
		||||
 | 
			
		||||
#if HAS_TFT_XPT2046 || HAS_TOUCH_XPT2046
 | 
			
		||||
#if HAS_TFT_XPT2046 || HAS_TOUCH_BUTTONS
 | 
			
		||||
 | 
			
		||||
#include "xpt2046.h"
 | 
			
		||||
#include <SPI.h>
 | 
			
		||||
 
 | 
			
		||||
@@ -147,15 +147,15 @@ SPIClass::SPIClass(uint32_t spi_num) {
 | 
			
		||||
  _currentSetting->state = SPI_STATE_IDLE;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
SPIClass::SPIClass(int8_t mosi, int8_t miso, int8_t sclk, int8_t ssel) {
 | 
			
		||||
SPIClass::SPIClass(int8_t mosi, int8_t miso, int8_t sclk, int8_t ssel) : SPIClass(1) {
 | 
			
		||||
  #if BOARD_NR_SPI >= 1
 | 
			
		||||
    if (mosi == BOARD_SPI1_MOSI_PIN) SPIClass(1);
 | 
			
		||||
    if (mosi == BOARD_SPI1_MOSI_PIN) setModule(1);
 | 
			
		||||
  #endif
 | 
			
		||||
  #if BOARD_NR_SPI >= 2
 | 
			
		||||
    if (mosi == BOARD_SPI2_MOSI_PIN) SPIClass(2);
 | 
			
		||||
    if (mosi == BOARD_SPI2_MOSI_PIN) setModule(2);
 | 
			
		||||
  #endif
 | 
			
		||||
  #if BOARD_NR_SPI >= 3
 | 
			
		||||
    if (mosi == BOARD_SPI3_MOSI_PIN) SPIClass(3);
 | 
			
		||||
    if (mosi == BOARD_SPI3_MOSI_PIN) setModule(3);
 | 
			
		||||
  #endif
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -22,7 +22,7 @@
 | 
			
		||||
 | 
			
		||||
#include "../../../inc/MarlinConfig.h"
 | 
			
		||||
 | 
			
		||||
#if HAS_TFT_XPT2046 || HAS_TOUCH_XPT2046
 | 
			
		||||
#if HAS_TFT_XPT2046 || HAS_TOUCH_BUTTONS
 | 
			
		||||
 | 
			
		||||
#include "xpt2046.h"
 | 
			
		||||
#include <SPI.h>
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user