Minor nitpick, but at least as far as the GNU GPL goes, it explicitly allows you to charge for software distribution when the software came bundled with a tangible item (like the firmware of an IoT device). The distributor can require you to pay them to get it. This was more common in the old days when software mostly came on CD-ROMs and you'd be getting another physical item in the mail, but the provision remains in the GPLv3 under section 6(b)(1) as an option that the distributor can require.
It has to be the reasonable costs of distribution. It can't just be an arbitrary fee.