Skip to content

Commit

Permalink
tweak
Browse files Browse the repository at this point in the history
  • Loading branch information
lovyan03 committed May 30, 2021
1 parent 6ac5c4b commit 6d9c361
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 8 deletions.
2 changes: 1 addition & 1 deletion src/lgfx/v1/LGFXBase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2850,7 +2850,7 @@ namespace lgfx
static Panel_NULL nullobj;
_panel = (nullptr == panel)
? &nullobj
: reinterpret_cast<IPanel*>(panel);
: panel;
}

bool LGFX_Device::init_impl(bool use_reset, bool use_clear)
Expand Down
2 changes: 2 additions & 0 deletions src/lgfx/v1/platforms/esp32/Bus_Parallel8.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ namespace lgfx
#define SAFE_I2S_FIFO_WR_REG(i) (0x3FF4F000 + ((i)*0x1E000))
#define SAFE_I2S_FIFO_RD_REG(i) (0x3FF4F004 + ((i)*0x1E000))

static constexpr std::size_t CACHE_THRESH = 256;

static constexpr std::uint32_t _conf_reg_default = I2S_TX_MSB_RIGHT | I2S_TX_RIGHT_FIRST | I2S_RX_RIGHT_FIRST;
static constexpr std::uint32_t _conf_reg_start = _conf_reg_default | I2S_TX_START;
static constexpr std::uint32_t _conf_reg_reset = _conf_reg_default | I2S_TX_RESET;
Expand Down
1 change: 0 additions & 1 deletion src/lgfx/v1/platforms/esp32/Bus_Parallel8.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,6 @@ namespace lgfx
private:

static constexpr std::size_t CACHE_SIZE = 260;
static constexpr std::size_t CACHE_THRESH = 256;
// static constexpr std::size_t CACHE_SIZE = 68;
// static constexpr std::size_t CACHE_THRESH = 64;

Expand Down
8 changes: 2 additions & 6 deletions src/lgfx/v1/touch/Touch_FT5x06.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ namespace lgfx
std::uint8_t tmp[2] = { 0 };
_inited = _write_reg(0x00, 0x00)
&& _read_reg(FT5x06_VENDID_REG, tmp, 1)
&& _write_reg(FT5x06_INTMODE_REG, 0x00) // INT Polling mode
&& tmp[0]
;

Expand All @@ -70,12 +71,7 @@ namespace lgfx
lgfx::pinMode(_cfg.pin_int, pin_mode_t::input_pullup);
}

if (_check_init())
{
_write_reg(FT5x06_INTMODE_REG, 0x00); // INT Polling mode
return true;
}
return false;
return _check_init();
}

void Touch_FT5x06::wakeup(void)
Expand Down

0 comments on commit 6d9c361

Please sign in to comment.