Programming work free of charge

Have you ever done a programming work and got paid less than a project was worth? I did, long time ago. Many software developers still fall into this trap, even though there’s a universally simple solution for not doing any extra work free of charge.