
GeoBASIC User Manual
10 — GeoBASIC Sample Programs
TPS1100-Version 2.10
10-5
DIM iY
AS Integer
'y coordinate
DIM iButton
AS Integer
'button id
CONST CX
= 90
'display center x coordinate
CONST CY
= 24
'display center y coordinate
CONST DL
= 20
'length of line
CONST HELPTEXT = "Visualizes the angles with lines from the
station. "
+
"The computed mean angle is shown by the longer
line. " +
"The north angle is 0."
MMI_CreateGraphDialog( CaptionShort, "PICTURE", HELPTEXT )
'Draw center and circle
MMI_DrawCircle( CX, CY,
3,
3, MMI_NO_BRUSH, MMI_PEN_BLACK )
MMI_DrawCircle( CX, CY, DL, DL, MMI_NO_BRUSH, MMI_PEN_BLACK )
'Draw lines for angles (there are iNoPoints angles)
DO WHILE iNoPoints > 0
'compute the line
iX = INT( DL * SIN(angles(INT(iNoPoints))) )
iY = INT( DL * COS(angles(INT(iNoPoints))) )
MMI_DrawLine( CX, CY, CX+iX, CY-iY, MMI_PEN_BLACK )
iNoPoints = iNoPoints - 1
LOOP
'Draw line for dMean
iX = INT( (DL+4) * SIN(dMean) )
iY = INT( (DL+4) * COS(dMean) )
MMI_DrawLine( CX, CY, CX+iX, CY-iY, MMI_PEN_DASHED )
'Wait for key press and finish dialog
MMI_AddButton( MMI_F5_KEY, "END" )
MMI_GetButton( iButton, FALSE )
MMI_DeleteDialog()
END ShowGraphics
'--------------------------------------------------------------------
GLOBAL SUB Main
'
----
' Description
'
Reads the number of points to be measured. Measures these points,
'
calculates the mean value and shows the result or moves (if
'
motorized) the TPS tocalulcated position.
'
DIM iNoPoints
AS Integer
'number of points to measure
DIM iCurrNo
AS Integer
'current point number
DIM lNoOk
AS Logical
'TRUE if no of points are valid
Содержание tps1100
Страница 1: ...GeoBASIC FOR TPS1100 User Manual Version 2 10 1997 2001 Leica Geosystems AG Heerbrugg Switzerland ...
Страница 150: ...GeoBASIC FOR TPS1100 Reference Manual Version 2 10 1997 2001 Leica Geosystems AG Heerbrugg Switzerland ...
Страница 411: ...GeoBASIC Reference Manual 6 System Functions TPS1100 Version 1 30 6 7 6 5 35 CSV_LibCallAvailable 6 213 ...
Страница 620: ...TPS1100 Version 2 10 6 1 ...
Страница 621: ......
Страница 623: ...TPS1100 Version 2 10 6 1 ...
Страница 624: ......
Страница 1053: ...TPS1100 Version 1 30 E 1 Appendix E GEOFONT ...
Страница 1154: ...GeoBASIC Reference Manual Appendix J List of Predefined Identifiers TPS1100 Version 1 30 J 9 TMC_SetOffsetDist 6 128 ...