I tested the predefined keyboard jog functions. mcJogVelocityStart with mcJogSetRate method looks more like what I want.
2021-09-27 10:52:16.410 - Logging Enabled.
2021-09-27 10:52:17.214 - Jog Rapid: keydown = true, axis = 0, dir = -1 mckeyboard.cpp:740
2021-09-27 10:52:17.214 - API: mcJogSetRate(inst = 0, axis = 0, percent = 100.0000) (mcKeyboard)
2021-09-27 10:52:17.214 - Attempt transition from "Idle" on event "Jog" axis.cpp:753
2021-09-27 10:52:17.214 - Signal id 1127, (Jog Enabled), changed from HIGH to LOW.
2021-09-27 10:52:17.214 - S_IDLE_on_exit
2021-09-27 10:52:17.214 - Signal id 1172, (Machine Idle), changed from HIGH to LOW.
2021-09-27 10:52:17.214 - ACTION_start_jogging
2021-09-27 10:52:17.214 - S_JOGGING_on_entry
2021-09-27 10:52:17.229 - API: mcJogVelocityStart(inst = 0, axis = 0, dir = -1) = 0 (mcKeyboard)
2021-09-27 10:52:17.284 - Jog Rapid: keydown = false, axis = 0, dir = -1 mckeyboard.cpp:740
2021-09-27 10:52:17.284 - API: mcJogSetRate(inst = 0, axis = 0, percent = 100.0000) (mcKeyboard)
2021-09-27 10:52:17.284 - API: mcJogVelocityStop(inst = 0, axis = 0) = 0 (mcKeyboard)
2021-09-27 10:52:17.352 - Attempt transition from "Jogging" on event "Stop Jog" controller.cpp:1815
2021-09-27 10:52:17.352 - S_JOGGING_on_exit
2021-09-27 10:52:17.352 - S_FILE_RUNNING_stop_jogging
2021-09-27 10:52:17.352 - S_IDLE_on_entry
2021-09-27 10:52:17.352 - Signal id 1127, (Jog Enabled), changed from LOW to HIGH.
2021-09-27 10:52:17.352 - Signal id 1172, (Machine Idle), changed from LOW to HIGH.