1. The ER is free to you, because they legally cannot refuse to treat you based on your ability to pay.
2. A regular doctor's visit costs $250 and your medicine costs $5-$500/month depending on what you need, because those businesses won't give you things they don't think you'll pay for.
One need not be morally bankrupt to make choice #1. We all choose things that are more expensive for society because they are more convenient or less expensive for us - lots of regular activities of what patio11 calls the professional/managerial class have negative externalities that the rest of society pays for: air travel, personal automobiles, and lawns all come immediately to mind.
If you want people to get their medical care from a PCP and their medicine from the pharmacy, then make it cheaper for them. Health insurance companies know this; that's why many plans lets you see your PCP for a small fixed price even before your deductible is met - because they want to incentivise you to get your care in the way that's cheapest for them.