WolfLanguage Commands:
Chars after # until end of line are ignored
Multiple commands per line separated by ;
Example: stop # ends execution
Example: cls() # clears output screen
Basic Operations
Assignment:
var = value
Example: a = 2
Example: $a = 2; b="abc"
$a is global variable.
Format numerical expression:
Example: 3.14159:000.00:
Format chars: 0 . # where # stands for any number of decimal chars
Showing values
"some text" " more text":
Example: "N 34 12." a " :the " rot13("gnetrg")
+, -, *, /, (, ):
Example: a = 1 / 2 + 34 - 8 * 12
or a = (1 / b + 34 - b) * 12
Root, Power
sqrt(), ^:
Example: a = sqrt(2) ^ 5
Trigonometric functions
cos(), sin(), tan(),
atan(), asin(), acos():
Example: a = cos(90);
or a = atan(b);
Change mode for trig functions
deg()
rad()
Trig conversion functions
deg2rad() alias d2r()
rad2deg() alias r2d()
Numeric functions
ct(number) # crosstotal
q(number) # Quersumme/crosstotal
Text functions[s is a string]
length(s)
mid(s,startpos,length)
instr(s,searchStr)
instr(startpos,s,searchstr)
ucase(s)
lcase(s)
replace(s,searchStr,ReplaceStr)
reverse(s)
encode(s,s1,s2)
count(s,whatStr)
val(s) # A=1, B=2, ... Z=26; Add all
sval(s) # A=1, B=2, ... Z=26
rot13(s)
Coordinate
bearing(coordinate1,coordinate2)
center() # get current center
center(coordinate)
cp() # get current GPS position
distance(coordinate1,coordinate2)
format(coordinate,fmt)
where fmt="CW" or "UTM" or "DMS" or "DD" or "DMM" or "GK"
goto(coordinate)
goto(coordinate,waypointname)
project(coordinate,angle,distance)
Generate program for Multis (with/without addi Wpts)
skeleton() # current cache also
skeleton(numberOfStages)
IF THEN ENDIF
IF condition THEN statement; statement .... ENDIF