Arduino Mega – TFT Megashield v1.1 met TFT320QVT

Arduino shields
Berichten: 4
Geregistreerd: 13 Nov 2015, 22:15

Arduino Mega – TFT Megashield v1.1 met TFT320QVT

Berichtdoor loens » 17 Nov 2015, 20:10

HELP !
Voorbeeldsketch gezocht voor:
Arduino Mega – TFT Megashield v1.1 met TFT320QVT
De voorbeeldsketches werken geen van alle. (in 1.0.6)
Krijg wel wat licht in het scherm, maar voor de rest NIETS.
Wie kan en wil me een beetje helpen. (ben pas bezig met Arduino)

Advertisement

Gebruikers-avatar
Berichten: 5043
Geregistreerd: 13 Mei 2013, 20:57
Woonplaats: Heemskerk

Re: Arduino Mega – TFT Megashield v1.1 met TFT320QVT

Berichtdoor nicoverduin » 18 Nov 2015, 08:37

Laat eens een voorbeeld sketch hier zien die je hebt gebruikt? Klinkt als een verkeerde pin definitie.
Docent HBO Technische Informatica, Embedded ontwikkelaar & elektronicus
http://www.verelec.nl

Berichten: 4
Geregistreerd: 13 Nov 2015, 22:15

Re: Arduino Mega – TFT Megashield v1.1 met TFT320QVT

Berichtdoor loens » 18 Nov 2015, 12:10

Lees dit eens door voor het mooi formatteren en beter leesbaar maken van de code

viewtopic.php?f=16&t=903



Hier een van de vele voorbeeld bestanden die niet werkt.
Deze stopt bij :
UTFT myGLCD(ITDB32S,38,39,40,41);


cpp code
// UTFT_Bitmap 
// Copyright (C)2015 Rinky-Dink Electronics, Henning Karlsen. All right reserved
// web: http://www.RinkyDinkElectronics.com/
//
// This program is a demo of the drawBitmap()-function.
//
// This demo was made to work on the 320x240 modules.
// Any other size displays may cause strange behaviour.
//
// This program requires the UTFT library.
//

#include <UTFT.h>

// Declare which fonts we will be using
extern uint8_t SmallFont[];

// Set the pins to the correct ones for your development shield
// ------------------------------------------------------------
// Standard Arduino Mega/Due shield : <display model>,38,39,40,41
// CTE TFT LCD/SD Shield for Arduino Due : <display model>,25,26,27,28
// Teensy 3.x TFT Test Board : <display model>,23,22, 3, 4
// ElecHouse TFT LCD/SD Shield for Arduino Due : <display model>,22,23,31,33
//
// Remember to change the model parameter to suit your display module!
UTFT myGLCD(ITDB32S,38,39,40,41);

extern unsigned short info[0x400];
extern unsigned short icon[0x400];
extern unsigned short tux[0x400];

void setup()
{
myGLCD.InitLCD();
myGLCD.setFont(SmallFont);
}

void loop()
{
myGLCD.fillScr(255, 255, 255);
myGLCD.setColor(255, 255, 255);
myGLCD.print(" *** A 10 by 7 grid of a 32x32 icon *** ", CENTER, 228);
for (int x=0; x<10; x++)
for (int y=0; y<7; y++)
myGLCD.drawBitmap (x*32, y*32, 32, 32, info);

delay(5000);

myGLCD.fillScr(255, 255, 255);
myGLCD.setColor(255, 255, 255);
myGLCD.print(" Two different icons in scale 1 to 4 ", CENTER, 228);
int x=0;
for (int s=0; s<4; s++)
{
x+=(s*32);
myGLCD.drawBitmap (x, 0, 32, 32, tux, s+1);
}
x=0;
for (int s=4; s>0; s--)
{
myGLCD.drawBitmap (x, 224-(s*32), 32, 32, icon, s);
x+=(s*32);
}

delay(5000);
}

Gebruikers-avatar
Berichten: 5043
Geregistreerd: 13 Mei 2013, 20:57
Woonplaats: Heemskerk

Re: Arduino Mega – TFT Megashield v1.1 met TFT320QVT

Berichtdoor nicoverduin » 18 Nov 2015, 14:07

Er zijn helaas meerdere mogelijkheden. Kennelijk wisselen die TFT drivers nog wel eens. Dus waar nu staat ITDB32S kan het een andere driver worden. Dus om te begnnen, graag de link naar het product waar je hem gekocht hebt.
Docent HBO Technische Informatica, Embedded ontwikkelaar & elektronicus
http://www.verelec.nl

Gebruikers-avatar
Berichten: 210
Geregistreerd: 03 Sep 2013, 10:03
Woonplaats: Katwijk ZH

Re: Arduino Mega – TFT Megashield v1.1 met TFT320QVT

Berichtdoor baco1978 » 18 Nov 2015, 17:17

je zegt dat die daarbij stopt,
wat is dan de foutmelding die het programma aangeeft?
Met vriendelijke groet Arjan

Berichten: 4
Geregistreerd: 13 Nov 2015, 22:15

Re: Arduino Mega – TFT Megashield v1.1 met TFT320QVT

Berichtdoor loens » 18 Nov 2015, 18:10

De foutmelding is:
UTFT does not name a type.

Hier wat gegevens:
HY-TFT320 is a 3.2 inch TFT LCD Screen module, 320*240 (resolution), 65K color, 40pins interface ,
not just a LCD breakout, but include the Touch screen, SD card. So it’s a powerful extension module
for your project.
This Screen includes a controller SSD1289, it’s 16bit data interface, easy to drive by many MCU like
STM32 ,AVR and 8051.HY-TFT320 is designed with a touch controller in it . The touch IC is XPT2046 ,
and touch interface is included in the 40 pins breakout. Another useful extension in this module is the
SD Card socket . It use the SPI mode to operate the SD card, the SPI interface include in the 40pins
breakout.
Application Ideas
 Digital Photo Frame (DPF)
 Video terminals
 Instrumentation
 GPS
 Game consoles
 Video phones and Portable VCD, DVD
Specification:
 3.2" Color TFT LCD
 320 x 240 Resolution
 65,536 Colors (16 Bit)
 Powerful 16 Bit Microcontroller(SSD1289)
 Built-in video RAM buffer
 Integrated Resistive Touchscreen
 Integrated SD card
 5V Operating Volta

Note: The TFT controller model needs to be declared in the initializing statement. ITDB02
myGLCD(38,39,40,41) needs to be modified as myGLCD(38,39,40,41,ITDB32S) when using Arduino
Mega2560.ITDB02 myGLCD(19,18,17,16,ITDB32S) needs to be commented when using Aduino UNO.
Otherwise it just show a blank screen. In practice, RS, WR, CS, RSET can be connected to any free
pin. But the pin number must be in accord with myGLCD(RS,WR,CS,RST).

Gebruikers-avatar
Berichten: 5043
Geregistreerd: 13 Mei 2013, 20:57
Woonplaats: Heemskerk

Re: Arduino Mega – TFT Megashield v1.1 met TFT320QVT

Berichtdoor nicoverduin » 19 Nov 2015, 08:59

als jij een compiler waarschuwing krijg, dan is er nog niets geupload naar de Mega. Dan klopt je library niet. Heb je die wel in je applicatie geimporteerd?
Docent HBO Technische Informatica, Embedded ontwikkelaar & elektronicus
http://www.verelec.nl

Berichten: 4067
Geregistreerd: 16 Okt 2013, 14:31
Woonplaats: s hertogenbosch

Re: Arduino Mega – TFT Megashield v1.1 met TFT320QVT

Berichtdoor shooter » 19 Nov 2015, 10:26

utft moet staan in .....arduino/library/utft/utft.h
paul deelen
shooter@home.nl

Berichten: 4
Geregistreerd: 13 Nov 2015, 22:15

Re: Arduino Mega – TFT Megashield v1.1 met TFT320QVT

Berichtdoor loens » 19 Nov 2015, 14:23

Ben er al uit.
Arduino opnieuw geinstalleerd met de bijbehorende displaydriver en alles werkt.
Bedankt voor jullie reacties. :D

Terug naar Shields

Wie is er online?

Gebruikers in dit forum: Geen geregistreerde gebruikers en 6 gasten