​Grafik-Display zeigt falsche Text

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • ​Grafik-Display zeigt falsche Text

      Hallo Leute,
      ich habe eing Grafik Display 132x32 mit ST7567 Controller und steuer per SPI an.
      Das initialisieren des Display hat ohne Probleme funktioniert. Aber stat der Text dem ich vorgebe schreibt anderes auf dem Display.

      BASCOM Source Code: EADOGM132x32.BAS

      1. '-----------------------------------------------------------
      2. ' EADOGM132x32.BAS
      3. ' (c) 1995-2009 MCS Electronics
      4. ' micro : m324p
      5. ' demo : SPI graphical display EADOGM132x32
      6. ' IMPORTANT : SPI only allows the WRITE mode. THis mean that setting pixels is not possible.
      7. ' for this reason commands as PSET, LINE and CIRCLE are not supported.
      8. ' best option would be to display pictures
      9. ' fonts and images are compatible with KS108
      10. '-----------------------------------------------------------
      11. '$regfile = "m324pdef.dat" ' ATmega168
      12. $regfile = "m324Adef.dat"
      13. $crystal = 8000000
      14. '$lib "glcdeadogm128x6.lbx" ' specify the used lib
      15. $lib "glcdEADOGM132x32.lib"
      16. $hwstack = 40
      17. $swstack = 40
      18. $framesize = 40
      19. 'the display was connected with these pins
      20. Config Graphlcd = 128x64eadogm , Cs1 = Portb.4 , A0 = Portb.2 , Si = Portb.0 , Sclk = Portb.1 , Rst = Portb.3
      21. 'the best option is to control the reset line of the LCD with the micro so you can reset it controlled at startup
      22. Dim B As Byte , J As Byte
      23. Dim K As Byte , X As Word , Y As Word
      24. Cls
      25. 'specify the font we want to use
      26. Setfont Font8x8
      27. 'You can use locate but the columns have a range from 1-128
      28. 'When you want to show somthing on the LCD, use the LDAT command
      29. 'LCDAT Y , COL, value
      30. Lcdat 1 , 1 , "11111111"
      31. Lcdat 2 , 1 , "ABCDEFGHIJKL1234"
      32. Lcdat 3 , 1 , "MCS Electronics" , 1
      33. Lcdat 4 , 1 , "MCS Electronics"
      34. Wait 3
      35. Locate 1 , 1 : Lcd "TEST"
      36. 'Cls
      37. 'Setfont Font16x16sajat
      38. 'Lcdat 3 , 1 , "HELLO"
      39. End
      40. Plaatje:
      41. 'include the picture data
      42. '$bgf "ks108.bgf"
      43. 'include used fonts
      44. $include "font8x8.font"
      45. '$include "font16x16sajat.font"
      Display All

      Grüße, Patrick
      Files
    • Nein.
      Das Ergebnis ist das selbe.

      Ich habe zwischen durch mal Datenblatt für ST7567 durchgeblättert und es gibt ein Test-Modus.
      Wisst ihr wie Befehle manuell auf dem Display zuweisen kann?
      Files
      • ST7567.png

        (89.15 kB, downloaded 10 times, last: )

      The post was edited 1 time, last by patrick_cpp ().