RTC6 boards
Doc. Rev. 1.0.21 en-US
6 Developing RTC6-User Programs
117
• If using method 2, you should use it fully. If the
set_sub_pointer alone is executed, then the
subroutine is already callable by sub_call and its
index, but the subroutine remains unprotected
against overwriting. Protection is obtained only
after the subroutine is subsequently copied as an
indexed subroutine by save_disk/load_disk into
the protected RTC6 List Memory area “List 3”.
• save_disk ignores all non-indexed subroutines,
even those subsequently protected in the
protected RTC6 List Memory area “List 3” by
method 1. Be aware that they can be overwritten
there by load_disk.
• save_disk/load_disk automatically replaces
unallowed commands (for example,,
set_end_of_list) with list_nop commands.
• Indexed subroutines repeatedly indexed with
copy_dst_src are duplicated in the RTC6 List
Memory at a subsequent save_disk/load_disk.
This can result in a memory overflow in the
protected RTC6 List Memory area “List 3”.
• Before executing load_disk, be sure the
protected RTC6 List Memory area “List 3” is of
sufficient size after configuration of “List 1” and
“List 2” (save_disk returns the number of stored
list commands). An indexed subroutine is not
stored by load_disk if there is not sufficient
memory.
• Conversion of a subroutine by method 2 changes
the absolute memory address of the subroutine.
Unprotecting Subroutines
The protection of a subroutine stored in the
protected RTC6 List Memory area “List 3” is removed,
if it is assigned by config_list to one of the RTC6 List
Memory area “List 1” or “List 2”.
The subroutine can then still be called using the same
parameters (index or absolute memory address). But
it no longer has protection against unintentional
overwriting.