New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
drivers/stmpe811: add spi mode #17088
Conversation
drivers/include/stmpe811.h
Outdated
* @return 0 on success | ||
* @return -ENODEV when no valid device | ||
* @return -EIO when software reset failed | ||
* @return -EPROTO on any I2C error |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe change I2C
to bus
since now it can be either i2c or spi
drivers/include/stmpe811.h
Outdated
* @return STMPE811_OK on success | ||
* @return -STMPE811_ERR_I2C on any I2C error | ||
* @return 0 on success | ||
* @return -EPROTO on any I2C error |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe change I2C
to bus
since now it can be either i2c or spi
drivers/include/stmpe811.h
Outdated
* @return STMPE811_OK on success | ||
* @return -STMPE811_ERR_I2C on any I2C error | ||
* @return 0 on success | ||
* @return -EPROTO on any I2C error |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe change I2C
to bus
since now it can be either i2c or spi
May I squash? Does the i2c version still work for you @aabadie? |
Ping @aabadie! |
I won't be able to test before next week unfortunately. |
Just a remainder for you to test this one @aabadie :) |
will do tomorrow. There's a typo reported by codespell. |
The I2C version is still working:
|
6ffa12d
to
4e03025
Compare
4e03025
to
738db35
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK
Hmm, Murdock spotted an issue, you can squash the fix right away. |
738db35
to
e17fe0a
Compare
Thanks @aabadie! |
Contribution description
This PR adds the spi version for the
stmpe811
. It also changes to use error codes following driver guidelines.Testing procedure
Tested on Adafruit tft touch screen feather wing with the IRQ pin soldered in. https://learn.adafruit.com/adafruit-2-4-tft-touch-screen-featherwing, but this is not really needed for lvgl since the position is periodically queried.
DRIVER=stmpe811_spi make -C tests/pkg_lvgl_touch flash term
Test as well the i2c version.