These are more generally useful than just for the module so make them globally available, prefixed consistently with MICROPY_PLATFORM_.