My shied is a MCUFriend 2.4 from china, controller is ST7789V. It looks like SHTIRLITZ's one. but value range seem to be different!
I'm recharging my multi meter batterie and i'll measure again the resistance.
My shied is a MCUFriend 2.4 from china, controller is ST7789V. It looks like SHTIRLITZ's one. but value range seem to be different!
I'm recharging my multi meter batterie and i'll measure again the resistance.
Good morning
The library me it worked very well, the display is corrected, thank you very much for your help.
You have the library of tocuhscreem, I get an error TSpoint p undeclared scope. I am new to this and my English is not very good.
I have a question what is the difference between libraries and UTFTGUE adafruit_GFX?
Thank you so much for help me.
I have done some new test with ST7789V hardware.
I have change the Touchscreen.cpp to remove oversampling.
I have done 4 average of 300 samples (TL,TR,BL,BR). What I get is
X Y
TL 544 201
BL 381 676
TR 487 208
BR 356 661
We can see there that Y is consistant from R to L for low and high value delta around 10.
It is not the case for X there is large delta around 140.
X seems to not be linear.
I have measure A1A6 and get 2K2 Ohm
measure A2A7 and get 580 Ohm
Here is what I get while reading analogic value.
As you can see it is not linear at all, so difficult to manage correctly the X on this screen. I hope it is only my sample and not all the screens.

I have no idea what your PNG is supposed to show.
Personally, I have always used a very simple "Touchscreen_due" branch of the Adafruit library on Github.
I have just installed the latest version of the "Touch-Screen-Library-Master" from GitHub.
Sure enough, it is pretty flaky in the Calibration sketch. I suggest that you will get a more reliable response by altering "TouchScreen.h"
#define NUMSAMPLES 3
You may find that 4 or 5 is better.
I thought that I had included a new "Touch_shield_kbv" sketch in the v2.5 ZIP or perhaps I had attached it to another post. You can see what your Touch is reporting.
David.
Touch_shield_kbv.ino (10.1 KB)
I just ordered a 3.6" MCUFRIEND LCD and an Uno clone. I'd really prefer to run the screen on a Due (or at least a Mega) as the Uno has SO little memory.
They are probably 3 or 4 weeks away (coming from China to Western Australia) but I am looking forward to joining this thread.
Well, to be honest, I would prefer to download all the necessary libraries etc and not need to resort to this thread (hoping it all works) but I expect it won't all work. I'll keep an eye on this thread till then.
I have 3 BangGood 3.2" screens which don't have touch screens which I have been playing with.
I want to implement a digital clock so the touch screen will allow setting of the alarms etc. My particular screen will NOT have an SD so I will attach and external SD reader.
I am prepared to bend pins to connect hardware SPI but not happy with cutting traces and delicate soldering etc ![]()
Please keep this thread going ![]()
Thanks to david_prentice for all your hard work.... ![]()
The yellow or blue style of Uno clone have A6, A7 and extra holes for header strip.
Attach right-angle headers, and you can connect to the (scarce) unused pins with a shield mounted.
The Uno style shields can fit on a Mega or Due. They will work but obviously slower than a Uno due to the PORT bit mangling for D2-D9 pins.
You can also use these Uno shields on NUCLEO or FRDM boards. More Flash and powerful ARM processors.
David.
My Uno clone has the extra holes for more headers but no A6 and A7.
Wow, entered this message on my iPad and lost 80% of the message I typed! I don't think it liked the iPad smileys!????
I thought the Mega and Uno were compatible with the lower end pins!? I know SPI is different. ![]()
On another thread my Dues were still faster than my Mega even with soft SPI!
Not challenging, just asking. ![]()
As you know, digital#2 is PD2 on a Uno, PE4 on a Mega, PD1 on a Leonardo, PB25 on a Due, ...
I am expecting you to plug a shield into a standard Arduino. So the shield's LCD_D2 mates with digital#2 on all Arduinos.
You can NOT change the data bus pins or the control pins. MCUFRIEND_kbv uses the Shield pins and ignores any arguments in the constructor.
You just plug the shield into the Arduino, build, upload and go.
If you want to use the microSD on a Mega or Due, you have to use softSPI. e.g. from the <SdFat.h> library
SdFat.h is a nightmare. Which is why I have deliberately not included SD examples.
Of course, SD examples work fine on a Uno with the hardware SPI.
David.
david_prentice:
As you know, digital#2 is PD2 on a Uno, PE4 on a Mega, PD1 on a Leonardo, PB25 on a Due, ...<<<>>>
If you want to use the microSD on a Mega or Due, you have to use softSPI. e.g. from the <SdFat.h> library
SdFat.h is a nightmare. Which is why I have deliberately not included SD examples.
David.
Sorry, I don't know ANYTHING about the control pins. I'm too afraid to even look ![]()
Maybe ONE DAY, when I summon up the nerve. Hence I have to rely on others to write libraries. Once someone else had "hit" the hardware I can "glue" the methods I need.
I have 12 Nanos, an Uno, a Mega and 2 Dues. Until a couple of months ago I did EVERYTHING on my Nanos. Went from 0.9" screen to a 2.2" screen to 2 X2.4" to a 2.8" to 4X3.2"s and now to 3.6. I've used, and picked up methods, from U8glib to ILI9340 to ILI9341 to ILI9341_due to UTFT to my heavily modified UTFT library to Bodmer's HX8357 2 ILI9481 libraries. Then I changed to my Dues along the way then went back to my Mega (to play with). The Nanos (and the Uno) are now neglected.... ![]()
I'd buy 5 more Dues tomorrow except I'm looking for the R3-E versions that are as rare as "hen's teeth".
I agree, SdFat IS a nightmare. But I want to use my Dues so I have to use Soft SPI so I have to use SdFat ![]()
I have an SD SlideShow sketch that took DAYS of hard slog to convert from SD.h to SdFat.h. I abandoned 2 attempts before I eventually succeeded in the conversion.
I want to make clocks for my grand kids with changing "photo" backgrounds, birthday messages, holidays etc. One picture is 307Kb of PROGMEM, ONLY possible on a Due.... ![]()
A sketch with a "screen" library, an SD library, an RTC library and a touch screen
library won't fit on a UNO
![]()
Thanks again for your library, I look forward to using it ![]()
The beauty of the Arduino is that you plug in a shield and go.
A library can look after the hardware happy in the knowledge that the user has not made any wiring mistakes.
The user can write simple sketches that just work. If she has a problem, she can post on this forum and get answers from people from the opposite side of the world. Until today, I did not realise that you are in Oz.
Yes, there are some limits to compatibility over the Arduino range. e.g. a shield designed for a Uno may expect SPI on 10, 11,12, 13. A shield with SPI on the 3x2 ISP header will work on an Arduino but not on a NUCLEO. So the cheap Mcufriend Uno shields need a Mega, Leonardo, Due to bit-bash SPI on 11, 12, 13.
I am not even going to think about a Nano or Pro Mini. Users are hell bent on unconventional wiring. It would be a nightmare to support them. Mind you, the 3.3V Pro Minis are ideal for using 3.3V sensors and displays.
You have been using purpose built Mega display shields. And seen just how well Rowboteer's libraries can perform. And you never needed to worry which pin was used for CS or WR or even which pins are used for the data bus.
David.
A quick question?
Can someone not bend pins 10, 11, 12 & 13 and connect them to 53, 51, 50 & 52 on a Mega with Dupont wires? I don't know if it is a straight translation but MISO to MISO, SCK to SCK, MOSI to MOSI and SS to SS and avoid bit bashing? Same with the Due and the SPI header?
I suspect this will only effect the touch screen? That would only leave D0 to D7 and a few power connections. The 3.6" I ordered doesn't have an SD card so wouldn't need to be considered ![]()
I downloaded your library off the second link. Is that the most current? Is it on Github?
Did you know you can buy an adaptor you can mount a Nano on so the adaptor behaves like a Uno!?
I have one in front of me.... ![]()
Thank you for your library, I will have a peek at it tomorrow. It is almost midnight so
Thank you and goodnight ![]()
PS another question.... There is an RD connection? Does that mean you can do a readPixel and hardware scrolling?
I made an Adapter shield that receives Uno shields and sits on a Mega routing the data bus to PORTA and SPI bus to 50-53
I made an Adapter shield that receives Uno shields and sits on a Due routing the data bus to PD0-PD7 and SPI bus to PA25-PA27
This means that the 8-bit data bus runs at full speed on both Mega and Due. Likewise the SPI bus.
They are both regular ProtoShields with kynar wire soldered connections.
I have no idea what 3.6" display that you have ordered. All mcufriend-style shields have microSD sockets. It is just a pity that the Mega version microSD does not work. The Uno style shields work fine.
Yes, a Uno shield adapter for a Nano sounds a good idea. Mind you, most Nano owners are too tight to buy one.
I would not be happy with bending shield pins. If you want to re-route stuff, make an adapter shield sandwich. In terms of work, a home-made shield takes quite some time. Buying a $10 NUCLEO seems a lot easier.
David.
SORRY David!
I'm blind as a bat! It HAS an SD card! This is IT....
http://www.ebay.com.au/itm/141656670946?_trksid=p2060353.m2749.l2649&ssPageName=STRK%3AMEBIDX%3AIT
Now you'll have to pardon me while I feel around for my white stick ![]()
Wow! Just like that you made TWO shields!!!! I have been THINKING of making a shield for my 2.8" for weeks!!!!! And YOU made TWO overnight! ![]()
I've never even heard of a NUCLEO
But I will have a look for it on eBay....
It is only about 20 pins? Couldn't I just wire it up (temporarily?) with Dupont wires? Sorry, what do you mean PD0-PD7? And are PD25-PD27 the SPI header in the centre? Could you please list which pin to which pin as per numbers (names?) on the Due and the shield? NEWBIE alert!
Thanks again ![]()
ONLY 2 listings on eBay. Will the LCD plug straight into the NUCLEO and everything run at full speed? Oops, lots more listings at the end of the search.... ![]()
You can buy Mega Protoshields on Ebay. My first one was a plain pcb. Nowadays they come with headers mounted.
I snipped off the male pins that I was re-routing e.g. 11, 12, 13. And soldered kynar wires to 50, 51, 52.
Likewise with the data bus pins on 2-9.
I made both "adapter shields" some months ago. Although it is simple soldered wiring, the whole job is a little fiddly. It is far preferable to buy a ready-made pcb adapter like ColdTears.
Your selected Ebay shield is an example of mendacious advertising.
It shows a photo of a 400x240 ILI9327 shield mixed with photos of a 480x320 ILI9488 shield.
It carefully omits a photo of the pcb. It quotes initialisation code for a ILI9327 with text saying "ILI9488".
With luck, it has an ILI9486 or ILI9488.
Until the display arrives on your desk, you just have to keep your fingers crossed. At least my library can identify the controller. UTFT users can only do guesswork.
David.
Thanks for your quick reply.
Happily I have no problems ordering anything. My problem is the 5 week (if I'm lucky) wait between ordering and receiving ![]()
I have a Mega Protoshield on hand
But I have at least another 3 week wait for the screen
Will the Mega protoshield work on the Due?
I'm interested making the Due adaptor shield for this display NOW. I MAY eventually make Mega ones for my clocks.
Simple list of connections please. Like....
Shield Due
10 4
11 4 in SPI hddr
12 1 in SPI hddr
13 3 in SPI hddr
2 ?
3 ?
etc etc
TIA ![]()
I thought all adapters were 40 pin ones?
Hello, David.
I was faced with one problem.
I have tried to build Clock on RTC module, and to make indication in 3.2"LCD. In setup display working correctly, but in loop my dispaly loose connection (white screen).
The same RTC scetch working good with 128x64 dispaly (on u8glib).
It seems that LCD loose identification when call a internal function getDateDs1307 or get3231Temp(). However these functions returns to serial correct values, so i suppose that root cause in LCD library....
void loop(){
byte second, minute, hour, dayOfWeek, dayOfMonth, month, year;
//char week[8][10] = {"Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday"};
getDateDs1307(&second, &minute, &hour, &dayOfWeek, &dayOfMonth, &month, &year);
char timenow[10];
char data[11];
snprintf(timenow, sizeof(timenow),"%02d:%02d:%02d",hour, minute, second);
snprintf(data, sizeof(data),"%02d/%02d/%02d", dayOfMonth, month, year);
//Serial.println(timenow);
//Serial.println(data);
//Serial.println(get3231Temp());
//Serial.print("C");
tft.setCursor(125, 50);
tft.print(timenow);
tft.print(data);
tft.fillScreen(0x001F);
tft.print(get3231Temp());
tft.print("C");
tft.fillScreen(0x0000);
delay(1000);
}
What do you think, where can be conflict and how it can be fixed??
As far as I know, you have a red ST7789V display shield with a Uno.
The DS3231 is an I2C device. So it will use A4, A5 pins for I2C. The A4 pin is used by LCD_RST.
You will need to use different pins. The program would look nicer if you overwrite the text rather than clearing the whole display. (Which will flash screen)
David.
David, thanks.
You are right, the wire.h library and LCD use the A4 pin in the in the same time.
But i have no idea, how i can reassign the A4 for I2C bus in UNO.
May it is possible somehow reassign A4 pin in the Mcufriend_kbv library?
You can snip off the A4 pin from your display shield. Your I2C bus will work ok now..
My library should reset the controller in software. So you do not need the LCD_RST pin at all for your ST7789V, ILI9341, ILI9488, ...
Note that users with the older style controllers like ST7781, ILI9325, ... do need the LCD_RST pin. They should not snip off their LCD_RST pin.
David.