diff options
| author | 2014-11-11 01:46:04 -0500 | |
|---|---|---|
| committer | 2014-11-11 01:46:04 -0500 | |
| commit | ac8b38e54d2a22754b146944dfa27c240a2b6921 (patch) | |
| tree | bc092b2ef5ce773a7d28d042baa8c536da4deffd /src | |
| parent | Merge pull request #169 from archshift/autoplay (diff) | |
| parent | Add FRD:U service and functions (diff) | |
| download | yuzu-ac8b38e54d2a22754b146944dfa27c240a2b6921.tar.gz yuzu-ac8b38e54d2a22754b146944dfa27c240a2b6921.tar.xz yuzu-ac8b38e54d2a22754b146944dfa27c240a2b6921.zip | |
Merge pull request #189 from archshift/frdu
Add FRD:U service and functions
Diffstat (limited to 'src')
| -rw-r--r-- | src/core/CMakeLists.txt | 2 | ||||
| -rw-r--r-- | src/core/hle/service/frd_u.cpp | 35 | ||||
| -rw-r--r-- | src/core/hle/service/frd_u.h | 27 | ||||
| -rw-r--r-- | src/core/hle/service/service.cpp | 2 |
4 files changed, 66 insertions, 0 deletions
diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt index f67481359..f41d52e80 100644 --- a/src/core/CMakeLists.txt +++ b/src/core/CMakeLists.txt | |||
| @@ -36,6 +36,7 @@ set(SRCS | |||
| 36 | hle/service/dsp_dsp.cpp | 36 | hle/service/dsp_dsp.cpp |
| 37 | hle/service/err_f.cpp | 37 | hle/service/err_f.cpp |
| 38 | hle/service/fs_user.cpp | 38 | hle/service/fs_user.cpp |
| 39 | hle/service/frd_u.cpp | ||
| 39 | hle/service/gsp_gpu.cpp | 40 | hle/service/gsp_gpu.cpp |
| 40 | hle/service/hid_user.cpp | 41 | hle/service/hid_user.cpp |
| 41 | hle/service/mic_u.cpp | 42 | hle/service/mic_u.cpp |
| @@ -106,6 +107,7 @@ set(HEADERS | |||
| 106 | hle/service/dsp_dsp.h | 107 | hle/service/dsp_dsp.h |
| 107 | hle/service/err_f.h | 108 | hle/service/err_f.h |
| 108 | hle/service/fs_user.h | 109 | hle/service/fs_user.h |
| 110 | hle/service/frd_u.h | ||
| 109 | hle/service/gsp_gpu.h | 111 | hle/service/gsp_gpu.h |
| 110 | hle/service/hid_user.h | 112 | hle/service/hid_user.h |
| 111 | hle/service/mic_u.h | 113 | hle/service/mic_u.h |
diff --git a/src/core/hle/service/frd_u.cpp b/src/core/hle/service/frd_u.cpp new file mode 100644 index 000000000..58023e536 --- /dev/null +++ b/src/core/hle/service/frd_u.cpp | |||
| @@ -0,0 +1,35 @@ | |||
| 1 | // Copyright 2014 Citra Emulator Project | ||
| 2 | // Licensed under GPLv2 | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #include "common/log.h" | ||
| 6 | #include "core/hle/hle.h" | ||
| 7 | #include "core/hle/service/frd_u.h" | ||
| 8 | |||
| 9 | //////////////////////////////////////////////////////////////////////////////////////////////////// | ||
| 10 | // Namespace FRD_U | ||
| 11 | |||
| 12 | namespace FRD_U { | ||
| 13 | |||
| 14 | const Interface::FunctionInfo FunctionTable[] = { | ||
| 15 | {0x00050000, nullptr, "GetFriendKey"}, | ||
| 16 | {0x00080000, nullptr, "GetMyPresence"}, | ||
| 17 | {0x00100040, nullptr, "GetPassword"}, | ||
| 18 | {0x00190042, nullptr, "GetFriendFavoriteGame"}, | ||
| 19 | {0x001A00C4, nullptr, "GetFriendInfo"}, | ||
| 20 | {0x001B0080, nullptr, "IsOnFriendList"}, | ||
| 21 | {0x001C0042, nullptr, "DecodeLocalFriendCode"}, | ||
| 22 | {0x001D0002, nullptr, "SetCurrentlyPlayingText"}, | ||
| 23 | {0x00320042, nullptr, "SetClientSdkVersion"} | ||
| 24 | }; | ||
| 25 | //////////////////////////////////////////////////////////////////////////////////////////////////// | ||
| 26 | // Interface class | ||
| 27 | |||
| 28 | Interface::Interface() { | ||
| 29 | Register(FunctionTable, ARRAY_SIZE(FunctionTable)); | ||
| 30 | } | ||
| 31 | |||
| 32 | Interface::~Interface() { | ||
| 33 | } | ||
| 34 | |||
| 35 | } // namespace | ||
diff --git a/src/core/hle/service/frd_u.h b/src/core/hle/service/frd_u.h new file mode 100644 index 000000000..9df8a815a --- /dev/null +++ b/src/core/hle/service/frd_u.h | |||
| @@ -0,0 +1,27 @@ | |||
| 1 | // Copyright 2014 Citra Emulator Project | ||
| 2 | // Licensed under GPLv2 | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #pragma once | ||
| 6 | |||
| 7 | #include "core/hle/service/service.h" | ||
| 8 | |||
| 9 | //////////////////////////////////////////////////////////////////////////////////////////////////// | ||
| 10 | // Namespace FRD_U | ||
| 11 | |||
| 12 | namespace FRD_U { | ||
| 13 | |||
| 14 | class Interface : public Service::Interface { | ||
| 15 | public: | ||
| 16 | Interface(); | ||
| 17 | ~Interface(); | ||
| 18 | /** | ||
| 19 | * Gets the string port name used by CTROS for the service | ||
| 20 | * @return Port name of service | ||
| 21 | */ | ||
| 22 | std::string GetPortName() const { | ||
| 23 | return "frd:u"; | ||
| 24 | } | ||
| 25 | }; | ||
| 26 | |||
| 27 | } // namespace | ||
diff --git a/src/core/hle/service/service.cpp b/src/core/hle/service/service.cpp index b144a77d4..bb0f80e98 100644 --- a/src/core/hle/service/service.cpp +++ b/src/core/hle/service/service.cpp | |||
| @@ -12,6 +12,7 @@ | |||
| 12 | #include "core/hle/service/dsp_dsp.h" | 12 | #include "core/hle/service/dsp_dsp.h" |
| 13 | #include "core/hle/service/err_f.h" | 13 | #include "core/hle/service/err_f.h" |
| 14 | #include "core/hle/service/fs_user.h" | 14 | #include "core/hle/service/fs_user.h" |
| 15 | #include "core/hle/service/frd_u.h" | ||
| 15 | #include "core/hle/service/gsp_gpu.h" | 16 | #include "core/hle/service/gsp_gpu.h" |
| 16 | #include "core/hle/service/hid_user.h" | 17 | #include "core/hle/service/hid_user.h" |
| 17 | #include "core/hle/service/mic_u.h" | 18 | #include "core/hle/service/mic_u.h" |
| @@ -80,6 +81,7 @@ void Init() { | |||
| 80 | g_manager->AddService(new CFG_U::Interface); | 81 | g_manager->AddService(new CFG_U::Interface); |
| 81 | g_manager->AddService(new DSP_DSP::Interface); | 82 | g_manager->AddService(new DSP_DSP::Interface); |
| 82 | g_manager->AddService(new ERR_F::Interface); | 83 | g_manager->AddService(new ERR_F::Interface); |
| 84 | g_manager->AddService(new FRD_U::Interface); | ||
| 83 | g_manager->AddService(new FS_User::Interface); | 85 | g_manager->AddService(new FS_User::Interface); |
| 84 | g_manager->AddService(new GSP_GPU::Interface); | 86 | g_manager->AddService(new GSP_GPU::Interface); |
| 85 | g_manager->AddService(new HID_User::Interface); | 87 | g_manager->AddService(new HID_User::Interface); |