Hi Majid, I do not have your display but I can test it on a Nokia display. It does not use your driver but is uses a part of the glcd_common. Maybe there is an issue there.
In the following video you can see what I tested bu I did not test a square exactly around the edges: https://youtu.be/pgEeMSh4aGA [https://i.ytimg.com/vi/pgEeMSh4aGA/maxresdefault.jpg]<https://youtu.be/pgEeMSh4aGA> JAL PIC demo of library for Nokia 5110 Display<https://youtu.be/pgEeMSh4aGA> Demo program showing the functionality of the PIC JAL library of the Nokia 5110 display.Jallib can be found at: http://justanotherlanguage.org/ youtu.be I will give it a try this weekend. Kind regards, Rob ________________________________ Van: [email protected] <[email protected]> namens majid ebru <[email protected]> Verzonden: donderdag 22 juli 2021 11:19 Aan: jallib <[email protected]> Onderwerp: Re: [jallib] when i use KS0108 , the micro reseted ?? Hi Ron I wrote these codes and micro didn't work I should change 63 to 55 . Also I can't write string in position y=55 I can draw line 55 and write text in 48 ?!? On Wednesday, July 21, 2021 at 9:20:31 PM UTC+4:30 [email protected] wrote: Hi Majid, Can you simply the program to write once the following: glcd_line(0,0,127,0) glcd_line(0,0,0,63) glcd_line(127,0,127,63) glcd_line(0,63,127,63) Do you get a box? Kind regards, Rob ________________________________ Van: [email protected] <[email protected]> namens majid ebru <[email protected]> Verzonden: woensdag 21 juli 2021 07:56 Aan: jallib <[email protected]> Onderwerp: Re: [jallib] when i use KS0108 , the micro reseted ?? I think(feel) zero division happens in micro Maybe in the file glcd_common or file glcd_ks0108 , i don't know On Wednesday, July 21, 2021 at 10:24:17 AM UTC+4:30 majid ebru wrote: I think(feel) zero division happens in micro On Tuesday, July 20, 2021 at 11:42:30 PM UTC+4:30 majid ebru wrote: Hi i use glcd_line but it doesn't work correctly? include 18f4520 pragma target clock 8_000_000 -- Fosc pragma target OSC hs pragma target LVP disabled -- -- GRAPHIC_LCD IO definition ------------------------ var byte GLCD_DATAPRT is portD var byte GLCD_DATAPRT_DIR is portD_direction alias GLCD_CS1 is pin_b0 alias GLCD_CS2 is pin_b1 alias GLCD_RST is pin_b2 alias GLCD_RW is pin_c1 alias GLCD_E is pin_b3 alias GLCD_DI is pin_b4 -- alias GLCD_CS1_DIRECTION is pin_b0_direction alias GLCD_CS2_DIRECTION is pin_b1_direction alias GLCD_RST_DIRECTION is pin_b2_direction alias GLCD_RW_DIRECTION is pin_c1_direction alias GLCD_E_DIRECTION is pin_b3_direction alias GLCD_DI_DIRECTION is pin_b4_direction const GLCD_CLIPPING = false -- enable clipping (of ellipse) enable_digital_io() -- all pins digital I/O include delay include math include print include glcd_5x7_font include glcd_6x8_font include glcd_font -- common font stuff glcd_font_use(FONT_5X7) -- activate font include glcd_ks0108 -- glcd device dependent library include glcd_common -- device independent glcd library glcd_init() -- initialize display --------------------------- glcd_clear_screen() forever loop if n < 10000 then block n = n + 1 end block else block n = 0 FlashLED1 = ! FlashLED1 if(FlashLED1)then block -------------------------------------------------- glcd_write_pixel(60,i) glcd_line(0,i,127,i) glcd_char_goto(50,30) print_word_dec(glcd,i) -------------------------------------------------- i = i + 1 end block end if end block end if end loop ------------------------------------------------------------------------------------ only draw 56 (0~55) lines ?!? On Monday, July 19, 2021 at 9:37:09 PM UTC+4:30 [email protected] wrote: Hi Majid, I cannot see anything wrong with your code. Did you try to make a box by writing 4 lines to the screen to see if that works OK? It is not a solution but a test to see if you can write the lines on 'the edges' of the display. Kind regards, Rob ________________________________ Van: [email protected] <[email protected]> namens majid ebru <[email protected]> Verzonden: maandag 19 juli 2021 02:39 Aan: jallib <[email protected]> Onderwerp: [jallib] when i use KS0108 , the micro reseted ?? Hi again i use this code : include 18f4520 pragma target clock 8_000_000 -- Fosc pragma target OSC hs pragma target LVP disabled -- -- GRAPHIC_LCD IO definition ------------------------ var byte GLCD_DATAPRT is portD var byte GLCD_DATAPRT_DIR is portD_direction alias GLCD_CS1 is pin_b0 alias GLCD_CS2 is pin_b1 alias GLCD_RST is pin_b2 alias GLCD_RW is pin_c1 alias GLCD_E is pin_b3 alias GLCD_DI is pin_b4 -- alias GLCD_CS1_DIRECTION is pin_b0_direction alias GLCD_CS2_DIRECTION is pin_b1_direction alias GLCD_RST_DIRECTION is pin_b2_direction alias GLCD_RW_DIRECTION is pin_c1_direction alias GLCD_E_DIRECTION is pin_b3_direction alias GLCD_DI_DIRECTION is pin_b4_direction const GLCD_CLIPPING = TRUE -- enable clipping (of ellipse) enable_digital_io() -- all pins digital I/O include delay include math include print include glcd_5x7_font include glcd_6x8_font include glcd_font -- common font stuff glcd_font_use(FONT_5X7) -- activate font include glcd_ks0108 -- glcd device dependent library include glcd_common -- device independent glcd library glcd_init() -- initialize display --------------------------- glcd_clear_screen() var word n = 0 var byte i = 40 -- -- glcd_box(0,0,127,63) -- -- forever loop end loop ---------------------- glcd_box(0,0,127,63) this is code doesn't work?? but if i change that to glcd_box(0,0,127,55) < this works correctly ? can somebody help me ?? -- You received this message because you are subscribed to the Google Groups "jallib" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jallib/b05ea9ea-8601-44f3-b3b3-d315da0df328n%40googlegroups.com<https://groups.google.com/d/msgid/jallib/b05ea9ea-8601-44f3-b3b3-d315da0df328n%40googlegroups.com?utm_medium=email&utm_source=footer>. -- You received this message because you are subscribed to the Google Groups "jallib" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jallib/9ad8bb5a-efb7-40a8-beba-8ba193b58a77n%40googlegroups.com<https://groups.google.com/d/msgid/jallib/9ad8bb5a-efb7-40a8-beba-8ba193b58a77n%40googlegroups.com?utm_medium=email&utm_source=footer>. -- You received this message because you are subscribed to the Google Groups "jallib" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]<mailto:[email protected]>. To view this discussion on the web visit https://groups.google.com/d/msgid/jallib/3a2597be-896c-4240-a7c3-e2acef5e5fa4n%40googlegroups.com<https://groups.google.com/d/msgid/jallib/3a2597be-896c-4240-a7c3-e2acef5e5fa4n%40googlegroups.com?utm_medium=email&utm_source=footer>. -- You received this message because you are subscribed to the Google Groups "jallib" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jallib/AM0PR07MB624118BDEF17668B4889FC30E6E49%40AM0PR07MB6241.eurprd07.prod.outlook.com.
