Well its a tight fit for RAM I think - certainly for RSA with secure keylengths being
what they are now.
ECC takes less space but you'll have to implement discrete elliptic curve operations
over at least one of the NIST curves, which I doubt anyone trusts any more with
the Snowden revelations.