HP Forums
[Doubt - HP-71B - GDISP] - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Calculators (and very old HP Computers) (/forum-3.html)
+--- Forum: General Forum (/forum-4.html)
+--- Thread: [Doubt - HP-71B - GDISP] (/thread-15474.html)



[Doubt - HP-71B - GDISP] - hp41cx - 08-17-2020 04:15 PM

How define a position on the display to place a character created by the gdisp function.
Thanks


RE: [Doubt - HP-71B - GDISP] - KeithB - 08-17-2020 05:24 PM

Your question is unclear.
GDISP takes an up to 132 character string. Each character represents a column of the display.

My HP71 tells me that 132/22 is 6. So, locations 1-6 are character 1, 7 - 12 are character 2 and so on. 1 + (6*(N-1)) would be the formula for an arbitrary N.


RE: [Doubt - HP-71B - GDISP] - Valentin Albillo - 08-17-2020 06:20 PM

.
Hi, hp41cx (nice name):

(08-17-2020 04:15 PM)hp41cx Wrote:  How define a position on the display to place a character created by the gdisp function.

I agree, your question is not clear.

However, you may want to have a look at this web page:

HP-71B LEX files list

and scrolling down the page you'll find LCDLEX which includes a plethora of display-related new BASIC keywords including some to manipulate the LCD pixels individually (set, clear, check).

They'll give you full control of graphics and you can even write simple graphic games using them.

V.


RE: [Doubt - HP-71B - GDISP] - hp41cx - 08-17-2020 07:29 PM

I created a character ex: a $ = chr$ (124) & chr$ (96) & chr$ (133). How put the character formed using gdisp a$ starting in column 110 for example


RE: [Doubt - HP-71B - GDISP] - KeithB - 08-17-2020 07:51 PM

I don't know that there is a clever way.
J = 1
For I = 110 to 112
B$(I) = A$(J)
J = J+1
Next I


RE: [Doubt - HP-71B - GDISP] - Dave Frederickson - 08-17-2020 08:19 PM

At first the question seemed unclear to me, too, but then I looked up GDISP. On p.126 of the Reference Manual there is an example of a custom character. The WINDOW command is mentioned and I think you'll find your answer there.


RE: [Doubt - HP-71B - GDISP] - KeithB - 08-17-2020 08:41 PM

Except that it says:
"GDISP redefines all dot columns in the display, regardless of the WINDOW setting. However, by using GDISP and WINDOW prior to executing DISP, you can "lock" a bit pattern in a subsection of the display."

So, you cannot protect the GDISP results from another GDISP.


RE: [Doubt - HP-71B - GDISP] - J-F Garnier - 08-18-2020 07:28 AM

(08-17-2020 07:29 PM)hp41cx Wrote:  I created a character ex: a $ = chr$ (124) & chr$ (96) & chr$ (133). How put the character formed using gdisp a$ starting in column 110 for example

You can place a special pattern in the display with a sequence like:
DIM G$[132]
A$ = CHR$ (124) & CHR$ (96) & CHR$ (133) ! your special pattern ?
G$=GDISP$ ! read the current display
G$[110,112]=A$ ! insert your special pattern at columns 110-112
GDISP G$ ! put the updated display

HTH

J-F


RE: [Doubt - HP-71B - GDISP] - hp41cx - 08-18-2020 10:45 AM

J-F that was exactly what I needed
Thank's