btdrv: Updated sysver check for removed cmds in 14.x.

This commit is contained in:
yellows8 2022-04-07 22:12:26 -04:00
parent a1d6b3be43
commit 9865dbf921
No known key found for this signature in database
GPG Key ID: 0AF90DA3F1E60E43
2 changed files with 4 additions and 4 deletions

View File

@ -1439,7 +1439,7 @@ Result btdrvGetAudioControlInputState(BtdrvAudioControlButtonState *states, s32
/** /**
* @brief AcquireAudioConnectionStateChangedEvent * @brief AcquireAudioConnectionStateChangedEvent
* @note Only available on [12.0.0+]. * @note Only available on [12.0.0-13.2.1].
* @param[out] out_event Output Event. * @param[out] out_event Output Event.
* @param[in] autoclear Event autoclear. * @param[in] autoclear Event autoclear.
*/ */
@ -1447,7 +1447,7 @@ Result btdrvAcquireAudioConnectionStateChangedEvent(Event* out_event, bool autoc
/** /**
* @brief GetConnectedAudioDevice * @brief GetConnectedAudioDevice
* @note Only available on [12.0.0+]. * @note Only available on [12.0.0-13.2.1].
* @param[out] addrs Output array of \ref BtdrvAddress. * @param[out] addrs Output array of \ref BtdrvAddress.
* @param[in] count Size of the addrs array in entries, the maximum is 0x8. * @param[in] count Size of the addrs array in entries, the maximum is 0x8.
* @param[out] total_out Total output entries. * @param[out] total_out Total output entries.

View File

@ -1391,14 +1391,14 @@ Result btdrvGetAudioControlInputState(BtdrvAudioControlButtonState *states, s32
} }
Result btdrvAcquireAudioConnectionStateChangedEvent(Event* out_event, bool autoclear) { Result btdrvAcquireAudioConnectionStateChangedEvent(Event* out_event, bool autoclear) {
if (hosversionBefore(12,0,0)) if (!hosversionBetween(12, 14))
return MAKERESULT(Module_Libnx, LibnxError_IncompatSysVer); return MAKERESULT(Module_Libnx, LibnxError_IncompatSysVer);
return _btdrvCmdGetEvent(out_event, autoclear, 144); return _btdrvCmdGetEvent(out_event, autoclear, 144);
} }
Result btdrvGetConnectedAudioDevice(BtdrvAddress *addrs, s32 count, s32 *total_out) { Result btdrvGetConnectedAudioDevice(BtdrvAddress *addrs, s32 count, s32 *total_out) {
if (hosversionBefore(12,0,0)) if (!hosversionBetween(12, 14))
return MAKERESULT(Module_Libnx, LibnxError_IncompatSysVer); return MAKERESULT(Module_Libnx, LibnxError_IncompatSysVer);
return _btdrvCmdOutU32OutBuf(addrs, count*sizeof(BtdrvAddress), (u32*)total_out, 145); return _btdrvCmdOutU32OutBuf(addrs, count*sizeof(BtdrvAddress), (u32*)total_out, 145);