Lit is right that the 2nd Amendment applied to the Federal govt originally, and that it was never incorporated into the BoRs. It has been incorporated since Heller and another case in the Robert's Court.
However state's also allowed guns as a right back then too. The idea of a Federal BoR's came from the states. States can pass some gun laws but not a ban...because there is another delegated power given to Congress which is that they can call up the "militia" aka the people who hold arms. That means the people are to remain armed.
Self defense is a natural right. It is fundamental. So it cannot be taken away by any govt.
“Experience should teach us to be most on our guard to protect liberty when the Government’s purposes are beneficent. Men born to freedom are naturally alert to repel invasion of their liberty by evil-minded rulers. The greatest dangers to liberty lurk in insidious encroachment by men of zeal, well-meaning but without understanding.” — James Madison