Three main approaches.
Snap to text/dialogue/window/... box is an option here for many things but probably not what you want.
You can also just place the cursor on given coordinates. Might be harder if you are moving the screen around, getting other screens, changing res and whatnot.
Depending upon the setup then move relative is also a thing you could do (slam it to the bottom of the screen from where it is, maybe then a relative move up).
Noting current cursor position to restore later, possibly even on button release, should be nothing too drastic.
However "to anchor my cursor to the bottom screen of a DS emulator"
That makes it sound like you want to look into "mouse jails" wherein the mouse is confined to a screen/window/area. Should be discussed in whatever macro tool you are using here as playing games with multiple screens/windowed games is also an issue macro peeps run into and might have even solved internally.