@chipos81 That's so awesome! I would love to see a J2ME implementation on an FPGA one day for these mobile games popular in the '00s. BTW, you may want to vist our subreddit called /r/fpgagaming ( www.reddit.com/r/fpgagaming/ ) which deals with flashcarts, hardware replicas, video converters, and more.
Hi. I checked out your code on github ( thanks for sharing! ). In your specs, you detail that the analog to digital converter used has 8 channels. How many of these channels did you end up using? Also to which pins of the LCD did you connect them to? I'm looking at the pinouts for the LCD and I can't tell which are the analog outs. See image imgur.com/a/TpQtO
It's been a while so can't remember the exact details. It only uses two analogue channels and with that you can sense X,Y and whether the user is touching the screen. You have to set up voltage differentials over the screen to make it work though. The first few diagrams at www.ti.com/lit/an/slaa384a/slaa384a.pdf should show you how it works. Looking at comments in my code LCD_D6, LCD_D7, LCD_RS and LCD_WR are connected to the sides of the screens. Sure Adafruit have a touchscreen library which worked with it if you are using it with an Arduino and don't want to bother with the details.
Ah I see. Thanks for the quick reply and info! I might end up shelling the extra cash for the Adafruit LCD board because of the documentation, libraries, and info available. My know how at the moment isn't enough to make working with the mcufriend lcd anything but a very painful experience.
A quick follow up question. How did you connect the touch output to the adc? Did you solder directly to the four wire flex coming from the touch screen? As is the touch screen shares io pins with the lcd screen... And since the FPGA can't read analog...
Nope, if I remember correctly those pins were connected to the FPGA and the analog inputs of the ADC, When measuring the FPGA digital outputs were set into a high Z mode (equivalent to Input pin mode on an Arduino). This effectively disconnects them from the FPGA (not really but you can think of it like that as long as you're within the voltage range the pins can take).
Hi, thanks again for the quick reply! How would setting the FPGA pins (the two connected to the 'sense' outputs of the touch screen) to high impedance (equivalent to input mode?) disconnect them from the signal coming in from the touch screen? Pardon my noobness.