Solution 1:

You can enable full keyboard access to easily navigate the on-screen controls using the Tab and arrow key.

Go to System Preferences → Keyboard → Shortcuts and check the checkbox shown towards the bottom that reads, Use keyboard navigation to move focus between controls.

enter image description here

Now with the above set up, you can simply open System Preferences using Spotlight (which itself can be launched using the keyboard shortcut Command + Space), then use the keyboard shortcut Command + F to move focus to the System Preferences search field. Now type Mouse and trackpad and select the result that reads Mouse and trackpad easier to use.

enter image description here

This would take you to the desired preference pane. Now you can easily use the Tab key to navigate to the required checkbox and toggle the setting.

enter image description here

P.S.: With full keyboard access, on-screen controls can be navigated using the Tab and/or arrow keys. A control can be activated or toggled using the Space or the Enter key, and dialogue boxes dismissed using the the Esc key.

Solution 2:

If you want to disconnect your Bluetooth Mouse, just turn off Bluetooth.

You will need a (free) utility called blueutil to turn it off. See this answer for full details on where to obtain and how to use.

You can use AppleScript to disable Bluetooth as well.

Once disconnected, your track pad will begin working again.