You can get publicly funded counsel only if you are poor enough and unable to afford own lawyer. And public defenders tend to be overworked and underfunded, so it is not like they will give you too much personal attention.
In my experience you'll consult with a PD at your arraignment even if you don't qualify for a PD (for everything beyond summary offenses). They will give you the good advice of staying quiet, and stand next to you before the judge, and generally they might help you ask for bail or to otherwise get out at your arraignment.
If it's earlier in the arrest- e.g. at the police station- if they want to question you and you don't have a lawyer they need to get you one, and in theory this could be a PD. I don't have first hand experience with that, mostly because there's little point in the police bothering to question anyone who asks for a lawyer in 99.9% of cases. The lawyer will tell their client to not answer anything and the client should heed the advice.