They are both adverbs, and they are not really related to each other. Basically refers to something fundamental nature, e.g.
"basically correct" or "Basically, they are simple people." Obviously means that something is plainly evident, e.g. "Obviously, something is wrong."
e.g. = for example