I am not new to programming but am to Val3. I hope I am just missing something in that I can't return a value from a call or create a function in the language. So, I can only call programs and set a value in that to a global variable to be accessed after the program call ? eg. I'd like to return a bool for a home check:
if check_home() != true
// fault handling
endIf
vs.
// check_home internally sets bAtHome to true if near home position
call check_home()
if bAtHome != true
// fault handling
endIf
Am I missing something ? Returning a value seems basic to me and Val3 seems to have common language constructs. I hope it is my inexperience with the language that I'm missing something.
I see a way to create an application and package as a "library", but no mechanism for return values either. Is there a SDK to extend the language or create drivers/plugins ?
Thanks for any info !