The commands above are incorrect...I realized this when trying to dev on another box, so here's the correct commands from my console (note: the above work, but you have to define cpu before you try to access it)
[MAME]> cpu = manager:machine().devices[":maincpu"]
[MAME]> for k,v in pairs(cpu.spaces) do print(k) end
[MAME]> mem = cpu.spaces["program"]
[MAME]> print("map location: ",string.format('%x',mem:read_u8(0x00Eb)))
map location: 77
Further, I realize now that the version of LUA with mame is not compatable with luasocket (which installs based on the version of LUA you have on a system when using rocks). I tried to get a LUA 3.5 version of luasocket and couldn't get it to compile clean. I'm kinda tired of that rathole, and instead will try to do this via named pipes. I'll post here if I get that working, or if someone else has c# to mame's LUA communication working, that'd be golden.