If you pled guilty after being advised by the court and signed the necessary paperwork it will be difficult to vacate the plea and sentence. Only if you are in custody do you automatically get a Public Defender (irrespective of financial eligibility). Otherwise, you must meet financial eligibility to get the public defender.
Just because you panicked is not sufficient cause to set aside your plea.
Best of LuckAsk a similar question