diff --git a/nx/include/switch/services/set.h b/nx/include/switch/services/set.h index 3a9d3cd3..191310f3 100644 --- a/nx/include/switch/services/set.h +++ b/nx/include/switch/services/set.h @@ -25,13 +25,13 @@ typedef enum { /// Console Product Models typedef enum { - MODEL_INVALID = 0, ///< Invalid Model - MODEL_NX = 1, ///< Erista Model - MODEL_COPPER = 2, ///< Erista "Simulation" Model - MODEL_IOWA = 3, ///< Mariko Model - MODEL_HOAG = 4, ///< Mariko Lite Model - MODEL_CALCIO = 5, ///< Mariko "Simulation" Model - MODEL_AULA = 6, ///< Mariko Pro Model(?) + ProductModel_INVALID = 0, ///< Invalid Model + ProductModel_NX = 1, ///< Erista Model + ProductModel_COPPER = 2, ///< Erista "Simulation" Model + ProductModel_IOWA = 3, ///< Mariko Model + ProductModel_HOAG = 4, ///< Mariko Lite Model + ProductModel_CALCIO = 5, ///< Mariko "Simulation" Model + ProductModel_AULA = 6, ///< Mariko Pro Model(?) } ProductModel; /// IDs for Language. diff --git a/nx/source/services/set.c b/nx/source/services/set.c index dd1232dd..0cc53086 100644 --- a/nx/source/services/set.c +++ b/nx/source/services/set.c @@ -637,8 +637,11 @@ Result setsysSetDeviceNickname(const SetSysDeviceNickName *nickname) { ); } -Result setsysGetProductModel(s32 *out) { - return _setCmdNoInOutU32(&g_setsysSrv, (u32*)out, 79); +Result setsysGetProductModel(ProductModel *out) { + u32 product_model = 0; + Result rc = _setCmdNoInOutU32(&g_setsysSrv, &product_model, 79); + if (R_SUCCEEDED(rc) && out) *out = product_model; + return rc; } Result setsysGetLdnChannel(s32 *out) {