Sign in to follow this  
Followers 0
Chapmann

Soft

3 posts in this topic

Soft

Edited by Chapmann

Share this post


Link to post
Share on other sites

Search the manual for your CPU for the GTS and SBR instructions. The subroutine is inserted after the main program END instruction. The subroutine is started with the SBR instruction and ended with an RT (return)  instruction. You may use a RTC (return conditional) if your subroutine requires it) Unlike many other programming languages there is no structure for passing or returning values, The subroutine is identified by a constant provided as an argument to the SBR instruction. You invoke the subroutine from within the main program using the GTS instruction with the same numeric argument as the target subroutine. I don't remember if you can use the GTS from inside another subroutine. Otherwise the operation is similar to other language subroutines. On invocation the main code stops, the code within the subroutine is executed, then the processing of the main program continues from the instruction immediately after the GTS.

Edited by b_carlton
Mistyped RTC

Share this post


Link to post
Share on other sites

I am curious what you mean by changing your question to 'soft'

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0