Rei Vilo 695 Posted April 1, 2014 Share Posted April 1, 2014 v4 BoosterPacks use new display type, which has Y axis inverted when compared to the old one. @@username, @@Rei Vilo, could you suggest changes to make this work? I'm not sure to understand what "Y axis inverted" means. The library supports all the four orientations with (0,0) always on the top left corner of the screen for each of the 4 orientations. Quote Link to post Share on other sites
StupidPig 10 Posted April 1, 2014 Share Posted April 1, 2014 I'm not sure to understand what "Y axis inverted" means. The library supports all the four orientations with (0,0) always on the top left corner of the screen for each of the 4 orientations. May be the energia lib I got is an order version, as it doesn't include the setOrientation function, and that's why I added myself, plus making the getTouch() function aware of the orientation setting. For the "Y axis inverted", it just means when you touch the top, the Y result from getTouch() call is LCD_HEIGHT, and 0 when you touch the bottom (0,0 at bottom left corner). I tried both the energia lib, and the CCS one from Username, and both yield the same result. So it is very likely the v4 board got that part changed. Quote Link to post Share on other sites
PTB 27 Posted April 3, 2014 Share Posted April 3, 2014 The earlier versions of Robs board have the opposite direction for the touch panel. I had to change some code to flip the y direction and tweak the calibration. The old code works great with the old screens. But the new screens need a few lines changed. I'll dig out what i did just to throw it into the mix. These are fantastic boosterpacks. Absolutely love 'em. Cheers PTB RobG and GeekDoc 2 Quote Link to post Share on other sites
PTB 27 Posted April 3, 2014 Share Posted April 3, 2014 if (z>TOUCH_TRIM) { // x0 = check(x0, 311, 1632);//Old Style Screens from RobG (Green PCB) // y0 = check(y0, 195, 1859);//Old Style Screens from RobG (Green PCB) // // x = map(x0, 311, 1632, 0, LCD_WIDTH);//Old Style Screens from RobG (Green PCB) // y = map(y0, 195, 1859, LCD_HEIGHT, 0);//Old Style Screens from RobG (Green PCB) x0 = check(x0, 156, 1874); //Edited by PTB New Style Screens from RobG (Red PCB) y0 = check(y0, 120, 1859); //Edited by PTB New Style Screens from RobG (Red PCB) x = map(x0, 156, 1874, 0, LCD_WIDTH); //Edited by PTB New Style Screens from RobG (Red PCB) y = map(y0, 120, 1859, 0, LCD_HEIGHT); //Edited by PTB New Style Screens from RobG (Red PCB) return true; } else { return false; } } Here's the 4 lines of code change (to the old code) at the bottom of LCD_Touch.cpp I did to get touch working for me on the newer screens RobG and GeekDoc 2 Quote Link to post Share on other sites
StupidPig 10 Posted April 3, 2014 Share Posted April 3, 2014 @@PTB, Yeah this screen is great. It is strange that I just use the same (195,1859) range as the original lib y axis range for the x axis, and it works great, let me try the (156,1874) range tonight. And I think I just take it one step further by supporting the touch with all 4 screen orientation. BTW, here is what I used the screen with...... So many threads about making the MSP430 reflow oven kit, but almost none of them available for purchase, so I just got to make my own. bluehash, RobG, GeekDoc and 1 other 4 Quote Link to post Share on other sites
TDHofstetter 1 Posted December 18, 2016 Share Posted December 18, 2016 I realize I'm a little late on the scene... whatever happened to this project? The 43oh says they're out of stock, and your Tindie store doesn't seem to list them. I'd like to have one, possibly several. Quote Link to post Share on other sites
RobG 1,892 Posted December 18, 2016 Author Share Posted December 18, 2016 Hi, due to problems with suppliers, I have decided not to make them anymore. I only have LCDs without touch panel now. Quote Link to post Share on other sites
TDHofstetter 1 Posted December 23, 2016 Share Posted December 23, 2016 Ah. Ok. I have one of your non-touch 2.2" displays (with ?SD & no onboard SRAM); it's nicely built & does the job very well. A little slow, but that's because it's serial (and we really can't afford parallel with most MSP430s, we just can't spare enough pins). If I could find a decent 2.2" resistive sensor overlay that I knew would fit my display, I'd add it to what I have & be done with it. BTW... good to meet you, Rob. Quote Link to post Share on other sites
hemangjoshi37a 0 Posted June 14, 2017 Share Posted June 14, 2017 Hello everyone, Does anyone have the link to download the library?? Thanks. Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.