Vendor Teakra, make emulator own DSP RAM and add DSP RAM to fastmem (#806)
* DSP: Own DSP RAM and add it to fastmem * Vendor Teakra * Add MacOS support to fastmem * Fix MacOS fastmem paths * Fix iOS build
This commit is contained in:
36
third_party/teakra/src/apbp.h
vendored
Normal file
36
third_party/teakra/src/apbp.h
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
#pragma once
|
||||
#include <array>
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
#include "common_types.h"
|
||||
|
||||
namespace Teakra {
|
||||
class Apbp {
|
||||
public:
|
||||
Apbp();
|
||||
~Apbp();
|
||||
|
||||
void Reset();
|
||||
|
||||
void SendData(unsigned channel, u16 data);
|
||||
u16 RecvData(unsigned channel);
|
||||
u16 PeekData(unsigned channel) const;
|
||||
bool IsDataReady(unsigned channel) const;
|
||||
u16 GetDisableInterrupt(unsigned channel) const;
|
||||
void SetDisableInterrupt(unsigned channel, u16 v);
|
||||
void SetDataHandler(unsigned channel, std::function<void()> handler);
|
||||
|
||||
void SetSemaphore(u16 bits);
|
||||
void ClearSemaphore(u16 bits);
|
||||
u16 GetSemaphore() const;
|
||||
void MaskSemaphore(u16 bits);
|
||||
u16 GetSemaphoreMask() const;
|
||||
void SetSemaphoreHandler(std::function<void()> handler);
|
||||
|
||||
bool IsSemaphoreSignaled() const;
|
||||
|
||||
private:
|
||||
class Impl;
|
||||
std::unique_ptr<Impl> impl;
|
||||
};
|
||||
} // namespace Teakra
|
||||
Reference in New Issue
Block a user