Shop OBEX P1 Docs P2 Docs Learn Events
Propeller Touchscreen Platform (PTP): Now available! Drives the $10 3.5" touc - Page 2 — Parallax Forums

Propeller Touchscreen Platform (PTP): Now available! Drives the $10 3.5" touc

2

Comments

  • HarleyHarley Posts: 997
    edited 2010-07-04 02:26
    Thanks Rayman, That takes care of my questions for now.

    Gotta wait for the h/w to play with it and discover what Paint is all about. And to understand what it takes to i/f the LCD with my program, which I'll have to rewrite as it used a 128 x 64 monochrome LCD and three momentary switches to provide control.

    With the touch screen there can be many 'switches' now, or at least a better/different way to do things. yeah.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Harley Shanko
  • HarleyHarley Posts: 997
    edited 2010-07-06 17:06
    @ Rayman,

    My goodies (PTP, 3x 3.5s plus) arrived today, Tuesday. Thought I'd thank you with a graphic.

    When I first plugged in a 5v PS, nothing happened. Replugged the ps back on the pcb it was pulled from and Nada. Cats! One had stepped on one power strip switch!!!

    Beautiful to see PTP Paint! pop on the color screen. What a beautiful display. Sure glad you'd gotten them; sure would be a terrible shame to think they'd been scrapped. :-(

    Now to check all three for their calibration values. Then to check all I see on-screen vs the PTP Paint source listing to better understand all that's being done.

    One satisfied customer. yeah.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Harley Shanko
    5
    5
    51K
    3.5 51.1K
  • RaymanRayman Posts: 13,894
    edited 2010-07-06 21:46
    Harley, Thanks for pic! I'm very glad you're happy with it.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    My Prop Apps:· http://www.rayslogic.com/propeller/Programming/Programming.htm

    My Prop Info: ·http://www.rayslogic.com/propeller/propeller.htm
    My Prop Products:· http://www.rayslogic.com/Propeller/Products/Products.htm
  • HarleyHarley Posts: 997
    edited 2010-07-06 23:26
    A quick question,

    Is there any smaller font than the one used in PTP Paint!? That would be desirable. I'm just getting into LCD displays and not famiiar with what one can do about desiring a smaller font. I suppose the one used on Paint! is from the Prop ROM, right? yeah.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Harley Shanko
  • wjsteelewjsteele Posts: 697
    edited 2010-07-06 23:45
    Harley,

    You can basically draw any type of font you want to. Ray is using a modified version of Chip's VGA Driver, so it'll work with the standard graphics object from the Obex. With it, you can call the "text" method and pass in any location you want to draw the text, and with the "textmode" you can set the size. If you used an 8x8 font, instead of the 16x16 that Ray is using, you would wind up with a 1/4 size font compared to Ray's. You can save a lot of memory if you use the built in fonts, as well, becuase you wouldn't have to define them, since they're already in ROM.

    Bill
  • HarleyHarley Posts: 997
    edited 2010-07-07 00:54
    @ wjsteele, Thanks for that info. I'm aware of how a font uses up lots of memory. I don't need it right now. But would be nice to have about half size text; 8x8 would do.

    @ Rayman, What does it take to exit from Calibrate to go on to Paint? I added a test to check for stylus down and go back to the beginning of Calibrate. Did that so as to easily get multiple readings on each LCD. The front surface of the touch screen does scuff easily I note. Somehow must have bumped one and can see/feel a 'wart' on the surface near the middle, of all things. I'd guess that a more durable first layer is used in final product to protect it better.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Harley Shanko
  • RaymanRayman Posts: 13,894
    edited 2010-07-07 01:19
    Harley, I'll try to provide a better calibrate example soon. Also, you could use "Graphics.spin" to do any size text you want.

    Ariba and I have a few different PSB font size drivers that I'll try to port over to the PTP...

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    My Prop Apps:· http://www.rayslogic.com/propeller/Programming/Programming.htm

    My Prop Info: ·http://www.rayslogic.com/propeller/propeller.htm
    My Prop Products:· http://www.rayslogic.com/Propeller/Products/Products.htm
  • RaymanRayman Posts: 13,894
    edited 2010-07-17 19:43
    Just finished a stereo .wav file player for the PTP:

    [url=http://www.rayslogic.com/Propeller/Products/PTP/PTP_WavPlayer - Archive [Date 2010.07.17 Time 15.31].zip]Download PTP Waveplayer[/url]·

    Plays stereo wav files from SD card to headphones.

    Will work probably work on another Graphics.spin example now...

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    My Prop Apps:· http://www.rayslogic.com/propeller/Programming/Programming.htm

    My Prop Info: ·http://www.rayslogic.com/propeller/propeller.htm
    My Prop Products:· http://www.rayslogic.com/Propeller/Products/Products.htm
  • magdropmagdrop Posts: 13
    edited 2010-07-18 00:56
    @Rayman
    I've been working with your 3.5 PTP for a couple of days and I have to tell you it is an outstanding product.·· I am cobbling together a datalogger for a·prototype engine sensor and the touchscreen platform is going to bring·this particular project to a whole nuther level of sophistication.· At first I was just interested in a rather simple oscilloscope type display to indicate that the device was funtioning properly, but that has become a secondary, rather minor issue.· The really big deal is that I'm working up a power point presentation to put right into the datalogger.· To think that all the documentation and·training can be included with the actual product, just by running it on your platform...·it's sort of amazing.·· I'm still not quite sure that I realize just how good it really is.·· The product itself is going to tell folks what it's there for, what it it's doing, and why they have to have it.·

    So far I haven't run into any snags, it's been smooth sailing.· Of course I haven't tried to put my own images into the SD yet, which looks like the most complicated part, you know, dispaying them correctly with the touchscreen interface and all.· I just wanted to let you know how good this thing really is.· I won't even write a manual or do any training at all if things work out like I expect them to.·

    steve
  • RaymanRayman Posts: 13,894
    edited 2010-07-18 20:30
    Steve, Thanks! There's a Windows app for 2-bit bitmaps on my website that might help. The Paint! apps shows how to use 2-bit bitmaps with the PTP...
    I'm hoping to get 6-bit bitmaps using the SD card as buffer soon...

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    My Prop Apps:· http://www.rayslogic.com/propeller/Programming/Programming.htm

    My Prop Info: ·http://www.rayslogic.com/propeller/propeller.htm
    My Prop Products:· http://www.rayslogic.com/Propeller/Products/Products.htm
  • HughHugh Posts: 362
    edited 2010-07-26 11:46
    Rayman,

    The PTP is excellent. Thank you! Despite a slight delay whilst Her Majesty's Revenue & Customs held it hostage until I paid a small ransom (customs duty) it arrived here quite promptly.

    I have been really impressed with its capabilities and have connected it to another Prop-based project that reads, logs and displays OBD data from the engine management system of my car. The display is now much more user-friendly!

    An excellent product!· smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Hugh - the thinking woman's Geoffrey Pyke.
  • RaymanRayman Posts: 13,894
    edited 2010-07-26 19:02
    Thanks Hugh! Glad you got it. Sorry about the customs ransom. I've heard how some countries charge some outrageous amounts for customs... And, it's just a hassle to begin with. I would like to ship as "commercial sample" to avoid this, but from what I've read about it, that's not quite legal. I have a feeling that a lot of people ship that way anyway or as "gift". Would probably never get caught, but I'd rather stay above board...

    Out of curiosity, do you think it'd be cheaper or more convenient if it shipped from Germany?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    My Prop Apps:· http://www.rayslogic.com/propeller/Programming/Programming.htm

    My Prop Info: ·http://www.rayslogic.com/propeller/propeller.htm
    My Prop Products:· http://www.rayslogic.com/Propeller/Products/Products.htm
  • HughHugh Posts: 362
    edited 2010-07-26 19:23
    Rayman said...
    Thanks Hugh! Glad you got it. Sorry about the customs ransom. I've heard how some countries charge some outrageous amounts for customs... And, it's just a hassle to begin with. I would like to ship as "commercial sample" to avoid this, but from what I've read about it, that's not quite legal. I have a feeling that a lot of people ship that way anyway or as "gift". Would probably never get caught, but I'd rather stay above board...
    Out of curiosity, do you think it'd be cheaper or more convenient if it shipped from Germany?

    I think that once its in the EU its illegal to charge customs duty / VAT when moving to another country: as much as I hate it being so, the UK is in the EU.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Hugh - the thinking woman's Geoffrey Pyke.
  • mikedivmikediv Posts: 825
    edited 2010-07-27 17:17
    Ray I don'r mean to be dense but is the PTP actually a program or code where could I download it?
    I already have your demo programs for the touch sceens I got from you but I am confused about PTP?? thank man
    Ray your website is looking good
  • Duane DegnDuane Degn Posts: 10,588
    edited 2010-07-27 18:05
    Rayman,

    I read through most of this thread and I'm still not sure if the PTP can also drive the 4.3" screens?· I'm under the impression that it does; I just want to make sure.

    After reading about the memory issues you're having with the graphics demo, I wonder if it would be a good idea to have the PTP as a slave device to another Propeller chip.

    Duane
  • RaymanRayman Posts: 13,894
    edited 2010-07-27 19:13
    Duane, Sorry, the PTP is just for the 3.5" screens. Both 4.3" and 3.5" screens use the exact same connector, but have entirely different pinouts...

    Using the PTP as a graphics slave is a good idea. I want to create a serial driver and Windows test app for that...
    But, that won't help the memory situation a whole lot... The Prop just doesn't have the RAM to double-buffer the whole screen.
    The easy solution is to just single-buffer the screen or double-buffer only parts of the screen...

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    My Prop Apps:· http://www.rayslogic.com/propeller/Programming/Programming.htm

    My Prop Info: ·http://www.rayslogic.com/propeller/propeller.htm
    My Prop Products:· http://www.rayslogic.com/Propeller/Products/Products.htm
  • RaymanRayman Posts: 13,894
    edited 2010-07-27 19:14
    mikediv, there·are example codes on my website here:

    http://www.rayslogic.com/Propeller/Products/PTP/PTP.htm


    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    My Prop Apps:· http://www.rayslogic.com/propeller/Programming/Programming.htm

    My Prop Info: ·http://www.rayslogic.com/propeller/propeller.htm
    My Prop Products:· http://www.rayslogic.com/Propeller/Products/Products.htm
  • HughHugh Posts: 362
    edited 2010-07-27 20:34
    Duane Degn said...
    Rayman,

    I read through most of this thread and I'm still not sure if the PTP can also drive the 4.3" screens? I'm under the impression that it does; I just want to make sure.

    After reading about the memory issues you're having with the graphics demo, I wonder if it would be a good idea to have the PTP as a slave device to another Propeller chip.

    Duane

    Duane,

    I am using the PTP as a "graphics slave" - I have a prop doing lots of calculations/interfacing, then pass values to the PTP for the things I want to display via serial link.

    It is a quantum leap from displaying things via LCD, etc., when a TV or VGA monitor isn't available.

    Hugh

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Hugh - the thinking woman's Geoffrey Pyke.
  • RaymanRayman Posts: 13,894
    edited 2010-07-28 09:48
    Nick, I was just playing around with the "bootloader" code you pointed me to.

    I really like it!· Thanks to Brian Riley for putting that together.
    I think I'll now put that in lower EEPROM and Paint! in upper EEPROM.
    It doesn't seem to noticeable affect boot time.

    I have a new customer who has his PropPlug on backorder, so this seems like a perfect way
    to allow him to program the Prop without it.

    I just made a couple changes:
    1.· Tests for presense of SD before attempting to mount (using those 4 resistors I add).
    2.· Tries to mount a few times.· (Noticed that it doesn't always mount the first try).
    3.· Added support for nodelete.txt· (It seems like it was there and then removed at some point?)

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    My Prop Apps:· http://www.rayslogic.com/propeller/Programming/Programming.htm

    My Prop Info: ·http://www.rayslogic.com/propeller/propeller.htm
    My Prop Products:· http://www.rayslogic.com/Propeller/Products/Products.htm
  • laser-vectorlaser-vector Posts: 118
    edited 2010-08-03 22:46
    Hey, just got the PTP and the screen. gotta say its really nice!

    one question,

    im new to graphics, but i downloaded the windows tool for creating 2bit bitmaps and started playing around with it.

    2 x 2 tile images work great, but what about larger ones? i tried 3x3 and some of them worked but others were out of alignment...

    how would someone make images larger than 2x2 work properly and consistently?

    I would really like to make one that fills the screen 15x12!!

    Grant.
  • RaymanRayman Posts: 13,894
    edited 2010-08-03 23:52
    I need to update the bitmap code because it's a little clunky... Right now, there's a constant called "nuchars" that must be set to the total number user tiles (that need to be aligned before use).

    If you just have one 2x2 2-bit bitmap, then nuchars=4

    With just one 3x3 2-bit bitmap, nuchars=9

    I have some new code that handles this automatically (for Visual Spin), but I haven't encorporated it into the PTP code yet...

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    My Prop Apps:· http://www.rayslogic.com/propeller/Programming/Programming.htm

    My Prop Info: ·http://www.rayslogic.com/propeller/propeller.htm
    My Prop Products:· http://www.rayslogic.com/Propeller/Products/Products.htm
  • HarleyHarley Posts: 997
    edited 2010-08-16 18:17
    Has anyone noticed if you 'tease' the touchscreen it can appear to hang up?

    By sensing the state of the IRQ pin, I have the IRQ displayed as UP or DN. When you lightly touch the screen until you get a DN indication it will hang in the DN state.

    Is there a 'stiction' or hysteresis involved? It hasn't been a problem yet to my knowledge, but without the UP/DN display you wouldn't know it is 'hanging'. It takes a harder press to get it to release the DN state.

    I'm very pleased with this LCD.
  • RaymanRayman Posts: 13,894
    edited 2010-08-16 18:30
    Harley,
    I think you're talking about the touchscreen decoder's IRQ pin. The way that works is that once the screen is touched the IRQ flag is set until you clear it yourself. This is required for those cheap microcontrollers that only have one core... They don't have to continuously monitor the status of the touchscreen (slow), just check the IRQ flag (fast).

    Actually, with the Prop, you can ignore the IRQ pin and just use a spare cog to monitor the status of the touchscreen. This might be worthwhile in cases where you have extra cogs, but not enough pins...

    But, the IRQ does allow you to save a core for more important stuff...
  • HarleyHarley Posts: 997
    edited 2010-08-16 20:36
    Thank you for that clarification, Rayman.

    This is the first time I've even gotten 'this close' to a touchscreen. So hadn't considered what you described.

    I used your Paint! demo as a starting point for my program. Learned a lot and still learning. I note that WaitStylusDown uses the IRQ pin and was used elsewhere too. But the user usually shouldn't need to deal with it any further. I just displayed it's state, while debugging things, just for the heck of it and learned a bit more about touch ICs. Thanks.
  • Duane DegnDuane Degn Posts: 10,588
    edited 2010-08-21 17:33
    Rayman,

    Does the WaitStylusUp method in PTP_Paint.spin do anything?

    Here's the method:
    PUB WaitStylusUp
      'Wait for stylus to be up
      repeat
        waitcnt(cnt+clkfreq/100)  
        if ina[lcd#TouchIrqPin]<>0
        return
    

    I imagine there should be an indent before return. I either found a small bug or I don't understand spin as well as I thought. (I hope it's a bug.)

    This is from verion 1a which is the same version presently on Ray's Logic PTP Page

    I really like my PTP. Thanks.

    Duane
  • RaymanRayman Posts: 13,894
    edited 2010-08-21 19:11
    Duane,

    Good catch. You're right that it appears that the "return" should be indented. Otherwise, the "if" doesn't do anything.

    I'll have to take a closer look (when my head is clearer) and see what I meant to do there... I have to take another look at the IRQ. I don't think it clears itself, so I'm not sure what I had in mind there....

    Ray
  • RaymanRayman Posts: 13,894
    edited 2010-08-22 12:54
    Well, it looks like this code was mostly a cut&paste job from my 4.3" Paint example. And, both codes aren't especially well written :(

    They were adapted from code that worked with a mouse and this was a not so good attempt to make them work the same way...

    Looks like everything is handled in "WaitStylusDown".
    "WaitStylusUp" doesn't really do anything.

    I think what I should have done was move all the code starting with:
    if (tz<90000) and (tz>10000) and (ina[27]==0 )

    to the "WaitStylusUp" section. This is where it checks to see that the screen is still being touched after some delay.

    Problem is that because this is a drawing program, I don't really want it to wait for the stylus to come up, like you would for a GUI with buttons...
  • laser-vectorlaser-vector Posts: 118
    edited 2010-08-22 18:40
    hey ray, i was told those acrylic cases should be finished by the end of this month, is that all still on time?
  • RaymanRayman Posts: 13,894
    edited 2010-08-23 06:25
    I'll have to check with Chuck George at MountainKingTechnologies. I believe he said he was going to try and make something, but I haven't heard from him since the Expo...
  • HarleyHarley Posts: 997
    edited 2010-08-24 20:27
    @ Rayman. Sometime before we had the 'forum change' there was someone who was developing a 'breakout board' for the 3.5" LCD. I've forgotton who he was. He had a problem with the POE if I recall.

    I'm wondering if anyone has done a breakout for this neat LCD?
Sign In or Register to comment.