That's great, thanks for the update. Would you mind sharing the code you used for this at some point, especially if you get the touch portion of it functioning?
Oh sure. I'm just gonna get it work better and work on the the touch controller part. I will also include the hardware schematics. Maybe next week, I'll post it here.
Hi Guys,

I have a beaglebone black and a 7" CTE tft LCD module with a touchscreen and a SSD1963 controller. I have been researching how to connect these two devices and have come across this very informative thread.
One question though, there is already a 7" screen available for the beaglebone black, please see this link: http://circuitco.com/support/index.php?title=BeagleBone_LCD7. It looks like with this screen all you have to do is connect the beaglebone to the screen and the most recent version of Angstrom has the necessary code to output to the screen. I have looked at the documentation I could find on that LCD7 screen and it does not look like it has a controller like the SSD1963, but it basically has all the same inputs. Is there any harm in connecting my 7" screen to the same pins as outlined in the wiki and seeing if it works out of the box? Should it work out of the box, or is there a different communication method between the LCD7 screen and a SSD1963 controller?
Thanks
Hello all, I've been working on a .dts to port the SSD1289 3 inch LCD to Beaglebone Black with the 3.8 kernel. I'm a little confused where the LCD_MCLK comes in to play? My SSD1289 has it seems 4 CS pins, T_CS (I'm assuming for the touchscreen), SD_CS (which I assume is for the SD card), F_CS and CS which I have no clue what the difference between them are. Are one of these the LCD_MCLK? It doesn't seem to come up again in OP's code for 3.2? as far as I can tell and I end up with a pin that has no hole.

In the BB-BONE-LCD7 dts that there's a pin which is not in LCD mode "0x84 0x07 /* gpmc_csn2.gpio1_31, OUTPUT | MODE7 - AVDD_EN */" which translates to a GPIO on P8 pin 20. Is this where I should be connecting things?

This is the code (http://pastebin.com/CYArYahF) for the .dts that I hacked together based on the screen I have. It compiles and exports fine but the screen doesn't seem to work. I plug the backlight into the 3.3v as well as the screen but nothing but a grid looking thing. This is supposedly the datasheet for the screen as well: (http://aitendo3.sakura.ne.jp/aitendo_data/product_img/lcd/tft2/M032C1289TP/3.2-SSD1289.pdf)

Any recommendations?

Thanks
Aarron

I feel obligated to tell you that I'm pretty new at all this if you haven't already figured that out from the post.

Back of board:
http://i.imgur.com/PTAr8J0.png
Pin definition from vendor:
http://i.imgur.com/wccDIdI.png
Quote:
In the BB-BONE-LCD7 dts that there's a pin which is not in LCD mode "0x84 0x07 /* gpmc_csn2.gpio1_31, OUTPUT | MODE7 - AVDD_EN */" which translates to a GPIO on P8 pin 20. Is this where I should be connecting things?
It's worth pointing out that the SSD1289 requires LIDD mode, while I believe the LCD7 uses the analog mode.

Quote:
This is the code (http://pastebin.com/CYArYahF) for the .dts that I hacked together based on the screen I have. It compiles and exports fine but the screen doesn't seem to work. I plug the backlight into the 3.3v as well as the screen but nothing but a grid looking thing. This is supposedly the datasheet for the screen as well: (http://aitendo3.sakura.ne.jp/aitendo_data/product_img/lcd/tft2/M032C1289TP/3.2-SSD1289.pdf)
If you take a look at my pre-3.x code, you'll see that I was working before the .dts files were used, so I can't say I'm familiar with it. However, I'm willing to look into it (but your paste seems to have expired!).
Quote:
It's worth pointing out that the SSD1289 requires LIDD mode, while I believe the LCD7 uses the analog mode.


Ah, alright, it ended up causing me problems and conflicts so I removed it

Quote:
If you take a look at my pre-3.x code, you'll see that I was working before the .dts files were used, so I can't say I'm familiar with it. However, I'm willing to look into it (but your paste seems to have expired!).


Sorry about that, this should work. http://pastebin.com/Xn85XV0Z it's updated for the removed GPIO


Essentially, what you need to know about the DTS thing is that lines 21-40 are like 'declarations' for the pins.

Lines 56-98 are the the pinmux settings.

These two charts should help you get a grip on the address and mode settings:
P8 header:
https://github.com/derekmolloy/boneDeviceTree/blob/master/docs/BeagleboneBlackP8HeaderTable.pdf?raw=true
P9 header:
https://github.com/derekmolloy/boneDeviceTree/blob/master/docs/BeagleboneBlackP9HeaderTable.pdf?raw=true

The pin definitions typically go "PINADDRESS MODE"
IE

Code:
 0xa0 0x08 
translates to Pin 40 (0xa0), Mode 0 with the pulldown setting (0x08)

From the pictures of my board/datasheet are you able to tell what the F_CS does?
Hello,

ay00, maybe the reason why your modified dts file doesn't work is because i think the "part-number = "BB-BONE-LCD3CUSTOM-01";" line might correspond to the info in the memory required for a proper cape, this is so that when you plug in the cape the beaglebone can identify it and run the code. Since you, and I, are not using official capes, we can't have this line or other lines I believe. I am new to this too, and I have no idea what the correct solution is, but based on my poor understanding of the system that might be one problem.
What I said previously may not be correct.

ay00, the back of your board looks the exact same as the back of my board, and I think there are 5 control pins RD, WR, RS, CS, and REST. I've looked at the data sheet of my ssd1963 and there are two display modes, 6800 and 8080 I think. The 6800 mode uses 5 control pins (8080 uses 4 control pins) and the LCD_D0-17 data pins, so i think that is what I should be connecting up to.

However, I don't think that's the control scheme used in the LCD7 dts file, so I need to find the actual lcd driver in Angstrom and modify that, or switch it to the correct version of the driver if there is one. Does anyone know where I can find that driver? is the source file on the beaglebone, or do I need to download the kernel source files and look through those?

also, the LCD_AVDD_EN pin or whatever is a pwm input to the screen to control the screen brightness.

I just googled 6800 display mode and it is a common standard made by motorolla, and the 8080 mode is from Intel, and they are parallel interfaces. So i imagine I can find a driver somewhere that is already written for this, and I just put its name in the "compatible = " part in a dts file, and then I can do the pinmux from there?
To my knowledge, Angstrom does not offer LIDD drivers, hence why I created my own 8080-mode LIDD drivers (see the first post in the topic). However, that might no longer be true as of kernel 3.x Angstrom versions.
ok, looking through some previous posts I've found that I have said things that have already been said.

So it looks like if I can load that dtbo file for the lcd7 cape, and connect the correct pins as outlined on the circuitco wiki article for the LCD7, it might work. After lloking at different sources, The way I'm going to connect the pins are: CS to LCD_EN, RS to LCD_VSYNC, WR to LCD_HSYNC, and RD to LCD_PCLK. I don't know what REST is for, I'll leave that unplugged for now and see what happens
Yes, it looks like the LCD7 cape uses 8080 mode, so i guess the LIDD drivers for that are now in the 3.8 kernel. It was just difficult to figure out what thing was using what communication because all the pins are called different things, even though they do the same stuff (i think)
http://pastebin.com/yZjXHeu5

Still getting nowhere further with updates to my code made to try and distinguish it from the real capes. Does this need to run at boottime for it to be recognized as a display or something? I've tried to edit the uEnv to disable both the HDMI and the HDMIN capes with capeMgr.disable, which seems to work but I can't get the LCD3CUSTOM or any combination thereof to load at boot with capeMgr.enable I've been reading about having to recompile the kernel and including the dts/dtbo files to make the dtbo bootable but I'm still not totally convinced that will solve any of my problems.

Anybody else had any luck??
I have tried to get the LCD overlays to load but no luck. I can load other overlays, but I've tried my modified overlay and the existing LCD7 overlays but none load, I either get something like "file doesn't exist", or "file already exists" or something along those lines. I have read that it is a bug with the current Angstrom/kernel that you can't apply an LCD overlay during runtime, but if it is compiled with the kernel then it does work, so that is what I am trying now.

It's quite a bit to take in at once though, and some of the tutorials for compiling kernels are for older kernels. I followed the kernel compiling how to video at derekmolloy.ie, and everything was going fine until the point where I tried to load the kernel (it was 3.2.47 or something like that) onto my sd card, that previously had angstrom and kernel 3.8 on it, and I got the problem that the boot/kernel partition was too small. So I'll try the same steps, trying to substitute in 3.8 instead of 3.2, and I'll see how far I get.
engkan2kit wrote:
KermMartian wrote:
engkan2kit wrote:
So I read about the 3.8 kernel. It now uses device tree to add support for hardware connected to the MPU. Have you tried to make your LCD work with the version 3.8 of the linux kernel?

Thanks.
I'm afraid I haven't experimented with any of the latest kernels. If you do figure out how to do it, though, I would love to hear!


I got it working in 3.8 kernel. I think it is less complicated to add an LCD in the latest kernel because of the device tree. I just used the tilcdc driver and defined the timings and resolution based on the datasheet of my display. Pinmuxing is done via a dts file (not in a .c file anymore) I compile the dts file in the beaglebone and save it in the /lib/firmware/ directory in the beaglebone black. Then the LCD I attached now works like a custom cape(without the eeprom).

I willl be working on the the touch panel of this device now.


Hi! I'm wondering if you are using an LCD that has an RGB interface? Can tilcdc driver be used on an LCD with 8080 interface? Of course the LCD controller on AM335x chip supports 8080 interface using LIDD mode. But I can't find any clue how to enable and use LIDD mode in tilcdc driver. Looking forward to your response! Smile
Any updates on getting an ssd1963 display working on the Beaglebone Black 3.8 based kernels?

I have attached one, but if I connect the pclk pin to p8.28 header(assigned for pclk) it prevents my BBB from booting. I just get a power LED and network lights, nothing more.

If I connect the pclk to a standard GPIO pin, I can boot, and initialize the tilcdc driver via device tree file. Loads fine and create's a /dev/fb0 device. Backlight turns on, but the lcd show's nothing but a somewhat horizontally mirrored black image.(I can see a line going down the center of the screen).

http://www.sainsmart.com/sainsmart-5-5-inch-tft-lcd-480x800-arduino-due-mega2560-r3-raspberry-pi.html ~ this is the board I am trying to interface.

Any help would be appreciated. I am awaiting a FTDI/USB dongle to see what's going on here, if it is even trying to boot into the kernel or not. But I seem to be at a lost cause here.

FYI ~ Tried using latest ubuntu 3.8.13-bone40 and custom kernel, plus latest standard angstrom builds, all the same result.

Thanks for any input!
Sheldon.
I'm afraid I haven't worked with either 3.8 or the Beaglebone Black at all yet, so I don't have any particular insights on this. Also, what's stopping you from using the normal serial console over USB for debugging? That worked fine for me when I was building my driver. That's particularly weird about the PCLK pin; I think a serial console might help with that issue as well.
Kerm,

Great work on your LIDD driver. After extensive research on the net, you're the only one who managed to do it...

I've started writing a C code handling the LIDD module thru mmap registers, but for some reason I can't set the clock enables in the CLKC_ENABLE register of the LCDC...

I can't also find your source code, I would love to have a quick look on how you did your driver.

I can't use your patch directly, I'm on a custom Buildroot fs.
Wizzboy wrote:
Kerm,

Great work on your LIDD driver. After extensive research on the net, you're the only one who managed to do it...
Thank you! It was a pretty painful twelve days or so trying to figure it all out, but in the end it worked.

Quote:
I've started writing a C code handling the LIDD module thru mmap registers, but for some reason I can't set the clock enables in the CLKC_ENABLE register of the LCDC...

I can't also find your source code, I would love to have a quick look on how you did your driver.
If you look at my patch, it contains all of the code that I wrote for the driver in easily-accessible form.

Quote:
I can't use your patch directly, I'm on a custom Buildroot fs.
That's understandable. You should be able to manually apply the code in my patch to your source files, though.
Looking at your code, and other codes I've seen, you guys juste write straight to the CLKC_ENABLE register... but for some reason when I write to it there's no effect, it keeps reading 0x00000000.

Everything seems to be setup right, except these clocks wont turn on. You had any problems regarding this when you went thru your driver?
Wizzboy wrote:
Looking at your code, and other codes I've seen, you guys juste write straight to the CLKC_ENABLE register... but for some reason when I write to it there's no effect, it keeps reading 0x00000000.
Make sure that you turned on all of the other necessary modules. I remember problems with having to turn on certain other things before I could enable that (although my memory could certainly be faulty).
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 4 of 5
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement