Post Reply 
newRPL - build 1255 released! [updated to 1299]
10-14-2019, 08:54 PM
Post: #588
RE: newRPL - build 1255 released! [updated to 1282]
(10-11-2019 10:19 PM)JoJo1973 Wrote:  Hello Claudio,

what's the meaning of system flags -12, -45, -46 and -47?

Those flags belong in the newRPL UAUR (Ultra-Advanced User Reference):

Flag -12 is set/cleared every time the user presses a key in the soft menus.
It's cleared if the pressed key was in menu 1 (top), set if it was in menu 2.
It affects the commands xxxLST and xxxOTHR:
TMENU: Modifies the "Active" menu (active menu is controlled by flag -11, usually (-flag clear-) it's the top one).
TMENULST / TMENUOTHR: They do TMENU, but the former uses the menu in which the user pressed last, while the latter changes the menu the user did NOT press last (a.k.a the "other" menu). They are meant to be used to bring up menus within menu handlers. For example, a menu handler may use TMENUOTHR to open a custom sub-menu in the other menu.

RCLMENU / RCLMENULST/RCLMENUOTHR: Same as RCLMENU, but following the same logic.
MENUBK / MENUBKLST / MENUBKOTHR: Brings up the previous menu for all 3 cases.


Flag -45 = DONEXTCUSTOMKEY
This flag is cleared right before entering a custom (user) key handler. Normal case is that the key handler will consume the key press, once the handler executes, no other handler will be used. However, you can "chain" handlers: let's say you want to count how many times the user presses the number "4", so you create a custom key handler that increments a global variable and you ASNKEY to number 4. But you want the "4" key to still be functional, so you set this flag, and the system will continue looking for additional custom handlers (previously installed for that same key). This way your handler is completely transparent. There's no limit on the number of handlers you can have for the same key.

Flag -46 = DODEFAULTKEY
Similar to -45, but this one is cleared before the first custom key handler is executed (there could be more than one as per chain execution above). Once all the custom key handlers finished executing, if this flag is set, the system will execute the standard default handler for that key. In other words, if any one of the custom handlers decided that the key should do the default behavior, setting this flag achieves it. In the example above, for the number "4" to be functional, your handler would have to set both flags, -45 and -46. The user would never know that the key was being logged.

Flag -47 = Disable auto execution of programs sent via USB. By default, sending a program with USBSEND will execute it automatically in the remote calculator. This flag disables that behavior. When data is received and this flag is set, the "Rx" signal will show in the status area until USBRECV is executed to pick up the data. In general, it's best to leave this flag clear (auto-receive enabled), since newRPL Desktop needs it to communicate with the calculator to establish the connection (it retrieves newRPL version, serial number for selection, and is also needed to run the firmware update process). If you don't want to execute a program, simply run USBRECV on the remote before sending it (which incidentally can be sent from the remote!).
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: newRPL - build 1001 released! - pier4r - 12-16-2017, 08:03 AM
newRPL - on Hp 39gs - Martin Hepperle - 06-05-2019, 06:51 AM
RE: newRPL - build 1001 released! - pier4r - 12-23-2017, 10:16 AM
RE: newRPL - build 1001 released! - pier4r - 01-01-2018, 09:42 AM
t - Claudio L. - 01-01-2018, 03:06 PM
RE: newRPL - build 1001 released! - pier4r - 01-01-2018, 03:41 PM
RE: newRPL - build 1001 released! - pier4r - 01-02-2018, 04:54 PM
RE: newRPL - build 1001 released! - pier4r - 01-02-2018, 06:58 PM
newRPL - brickviking - 10-05-2018, 06:01 AM
RE: newRPL - build 1255 released! [updated to 1282] - Claudio L. - 10-14-2019 08:54 PM
How to participate? - erazor - 12-13-2019, 07:12 AM



User(s) browsing this thread: 4 Guest(s)