Has Marlin have memory?

So with dual homing we can go to the same spot in a repeatable fashion. I normally home before a job then jog to my workplace origin write down my offsets then G92 to reset. If something goes wrong I rehome and then move to the location I wrote down.

What I would like to do is to be able to store the offset from home value in my gcode at the start of the job so if I have to kill the job and reset the machine I can simply rehome and go to the last saved start position. Does this ability exist either in Marlin via Gcode or CNC.js?

I want to store the 220,75 in memory so I can do an G0X220Y75 if something goes bad.

What about making a macro in cncjs? That’s what I do for z-homing, different variants of zeroing and similar.

Look into Work Coordinate Systems (G54-G59) and Tool Offsets. I believe Marlin supports both. Here’s a basic video.

I use work coordinate systems, which are great, but I don’t think they’re persistent through power down.

I have a few ones though that I use regularly, and have macros that will home the machine, jog to (for example) 27.5, 44, change to work coordinate system #1 and then set the work X and Y to zero. I always probe for Z anyway. (That example is for a clamp fence that I have that bolts to the spoilboard.

I use work coordinate systems, which are great, but I don’t think they’re persistent through power down.

According to the g-code reference for workspaces:

All workspaces default to 0,0,0 at start, or with EEPROM support they may be restored from a previous session.

So in theory they can be saved and restored, but I don’t know if it is as simple as executing an M500, or if there are more hoops to jump through.

Thanks all just knowing the vocabulary helps as a starting point. I’ll report back if I can get it to persist.