Fenrir
8 years ago
39 changed files with 1628 additions and 815 deletions
@ -1,8 +1,13 @@
@@ -1,8 +1,13 @@
|
||||
use ::Result; |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
extern "C" { |
||||
pub fn acInit() -> Result; |
||||
pub fn acExit(); |
||||
pub fn acWaitInternetConnection() -> Result; |
||||
pub fn ACU_GetWifiStatus(out: *mut u32) -> Result; |
||||
pub fn ACU_GetWifiStatus(out: *mut u32_) -> Result; |
||||
} |
||||
use ::types::*; |
||||
|
@ -1,49 +1,186 @@
@@ -1,49 +1,186 @@
|
||||
use ::{Handle, Result}; |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
#[repr(C)] |
||||
#[derive(Copy)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct AM_TitleEntry { |
||||
pub titleID: u64, |
||||
pub size: u64, |
||||
pub version: u16, |
||||
pub unk: [u8; 6usize], |
||||
pub titleID: u64_, |
||||
pub size: u64_, |
||||
pub version: u16_, |
||||
pub unk: [u8_; 6usize], |
||||
} |
||||
|
||||
impl ::core::clone::Clone for AM_TitleEntry { |
||||
fn clone(&self) -> Self { *self } |
||||
} |
||||
|
||||
impl ::core::default::Default for AM_TitleEntry { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
|
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum Enum_Unnamed1 { |
||||
AM_STATUS_MASK_INSTALLING = 1, |
||||
AM_STATUS_MASK_AWAITING_FINALIZATION = 2, |
||||
} |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum AM_InstallStatus { |
||||
AM_STATUS_ABORTED = 2, |
||||
AM_STATUS_SAVED = 3, |
||||
AM_STATUS_INSTALL_IN_PROGRESS = 2050, |
||||
AM_STATUS_AWAITING_FINALIZATION = 2051, |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct AM_PendingTitleEntry { |
||||
pub titleId: u64_, |
||||
pub version: u16_, |
||||
pub status: u16_, |
||||
pub titleType: u32_, |
||||
pub unk: [u8_; 8usize], |
||||
} |
||||
impl ::core::default::Default for AM_PendingTitleEntry { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum Enum_Unnamed2 { |
||||
AM_DELETE_PENDING_NON_SYSTEM = 1, |
||||
AM_DELETE_PENDING_SYSTEM = 2, |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct AM_TWLPartitionInfo { |
||||
pub capacity: u64_, |
||||
pub freeSpace: u64_, |
||||
pub titlesCapacity: u64_, |
||||
pub titlesFreeSpace: u64_, |
||||
} |
||||
impl ::core::default::Default for AM_TWLPartitionInfo { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
extern "C" { |
||||
pub fn amInit() -> Result; |
||||
pub fn amAppInit() -> Result; |
||||
pub fn amExit(); |
||||
pub fn amGetSessionHandle() -> *mut Handle; |
||||
pub fn AM_GetTitleCount(mediatype: u8, count: *mut u32) -> Result; |
||||
pub fn AM_GetTitleIdList(mediatype: u8, count: u32, titleIDs: *mut u64) |
||||
pub fn AM_GetTitleCount(mediatype: FS_MediaType, count: *mut u32_) |
||||
-> Result; |
||||
pub fn AM_GetTitleList(titlesRead: *mut u32_, mediatype: FS_MediaType, |
||||
titleCount: u32_, titleIds: *mut u64_) -> Result; |
||||
pub fn AM_GetTitleInfo(mediatype: FS_MediaType, titleCount: u32_, |
||||
titleIds: *mut u64_, titleInfo: *mut AM_TitleEntry) |
||||
-> Result; |
||||
pub fn AM_GetDeviceId(deviceID: *mut u32) -> Result; |
||||
pub fn AM_ListTitles(mediatype: u8, titleCount: u32, |
||||
titleIdList: *mut u64, titleList: *mut AM_TitleEntry) |
||||
pub fn AM_GetTicketCount(count: *mut u32_) -> Result; |
||||
pub fn AM_GetTicketList(ticketsRead: *mut u32_, ticketCount: u32_, |
||||
skip: u32_, ticketIds: *mut u64_) -> Result; |
||||
pub fn AM_GetPendingTitleCount(count: *mut u32_, mediatype: FS_MediaType, |
||||
statusMask: u32_) -> Result; |
||||
pub fn AM_GetPendingTitleList(titlesRead: *mut u32_, titleCount: u32_, |
||||
mediatype: FS_MediaType, statusMask: u32_, |
||||
titleIds: *mut u64_) -> Result; |
||||
pub fn AM_GetPendingTitleInfo(titleCount: u32_, mediatype: FS_MediaType, |
||||
titleIds: *mut u64_, |
||||
titleInfo: *mut AM_PendingTitleEntry) |
||||
-> Result; |
||||
pub fn AM_StartCiaInstall(mediatype: u8, ciaHandle: *mut Handle) |
||||
pub fn AM_GetDeviceId(deviceID: *mut u32_) -> Result; |
||||
pub fn AM_ExportTwlBackup(titleID: u64_, operation: u8_, |
||||
workbuf: *mut ::libc::c_void, |
||||
workbuf_size: u32_, |
||||
filepath: *const ::libc::c_char) -> Result; |
||||
pub fn AM_ImportTwlBackup(filehandle: Handle, operation: u8_, |
||||
buffer: *mut ::libc::c_void, size: u32_) |
||||
-> Result; |
||||
pub fn AM_ReadTwlBackupInfo(filehandle: Handle, |
||||
outinfo: *mut ::libc::c_void, |
||||
outinfo_size: u32_, |
||||
workbuf: *mut ::libc::c_void, |
||||
workbuf_size: u32_, |
||||
banner: *mut ::libc::c_void, |
||||
banner_size: u32_) -> Result; |
||||
pub fn AM_GetTWLPartitionInfo(info: *mut AM_TWLPartitionInfo) -> Result; |
||||
pub fn AM_StartCiaInstall(mediatype: FS_MediaType, ciaHandle: *mut Handle) |
||||
-> Result; |
||||
pub fn AM_StartDlpChildCiaInstall(ciaHandle: *mut Handle) -> Result; |
||||
pub fn AM_CancelCIAInstall(ciaHandle: *mut Handle) -> Result; |
||||
pub fn AM_FinishCiaInstall(mediatype: u8, ciaHandle: *mut Handle) |
||||
pub fn AM_CancelCIAInstall(ciaHandle: Handle) -> Result; |
||||
pub fn AM_FinishCiaInstall(ciaHandle: Handle) -> Result; |
||||
pub fn AM_DeleteTitle(mediatype: FS_MediaType, titleID: u64_) -> Result; |
||||
pub fn AM_DeleteAppTitle(mediatype: FS_MediaType, titleID: u64_) |
||||
-> Result; |
||||
pub fn AM_DeleteTicket(ticketId: u64_) -> Result; |
||||
pub fn AM_DeletePendingTitle(mediatype: FS_MediaType, titleId: u64_) |
||||
-> Result; |
||||
pub fn AM_DeleteTitle(mediatype: u8, titleID: u64) -> Result; |
||||
pub fn AM_DeleteAppTitle(mediatype: u8, titleID: u64) -> Result; |
||||
pub fn AM_DeletePendingTitles(mediatype: FS_MediaType, flags: u32_) |
||||
-> Result; |
||||
pub fn AM_DeleteAllPendingTitles(mediatype: FS_MediaType) -> Result; |
||||
pub fn AM_InstallNativeFirm() -> Result; |
||||
pub fn AM_InstallFirm(titleID: u64) -> Result; |
||||
pub fn AM_GetTitleProductCode(mediatype: u8, titleID: u64,
|
||||
productCode: *mut u8) |
||||
pub fn AM_InstallFirm(titleID: u64_) -> Result; |
||||
pub fn AM_GetTitleProductCode(mediatype: FS_MediaType, titleId: u64_, |
||||
productCode: *mut ::libc::c_char) -> Result; |
||||
pub fn AM_GetTitleExtDataId(extDataId: *mut u64_, mediatype: FS_MediaType, |
||||
titleId: u64_) -> Result; |
||||
pub fn AM_GetCiaFileInfo(mediatype: FS_MediaType, |
||||
titleEntry: *mut AM_TitleEntry, |
||||
fileHandle: Handle) -> Result; |
||||
pub fn AM_GetCiaIcon(icon: *mut ::libc::c_void, fileHandle: Handle) |
||||
-> Result; |
||||
pub fn AM_GetCiaDependencies(dependencies: *mut u64_, fileHandle: Handle) |
||||
-> Result; |
||||
pub fn AM_GetCiaMetaOffset(metaOffset: *mut u64_, fileHandle: Handle) |
||||
-> Result; |
||||
pub fn AM_GetCiaCoreVersion(coreVersion: *mut u32_, fileHandle: Handle) |
||||
-> Result; |
||||
pub fn AM_GetCiaRequiredSpace(requiredSpace: *mut u64_, |
||||
mediaType: FS_MediaType, fileHandle: Handle) |
||||
-> Result; |
||||
pub fn AM_GetCiaFileInfo(mediatype: u8, titleEntry: *mut AM_TitleEntry, |
||||
pub fn AM_GetCiaMetaSection(meta: *mut ::libc::c_void, size: u32_, |
||||
fileHandle: Handle) -> Result; |
||||
pub fn AM_InitializeExternalTitleDatabase(overwrite: u8) -> Result; |
||||
pub fn AM_QueryAvailableExternalTitleDatabase(available: *mut u8) |
||||
-> Result; |
||||
pub fn AM_InstallTicketBegin(ticketHandle: *mut Handle) -> Result; |
||||
pub fn AM_InstallTicketAbort(ticketHandle: Handle) -> Result; |
||||
pub fn AM_InstallTicketFinish(ticketHandle: Handle) -> Result; |
||||
pub fn AM_InstallTitleBegin(mediaType: FS_MediaType, titleId: u64_, |
||||
unk: u8) -> Result; |
||||
pub fn AM_InstallTitleStop() -> Result; |
||||
pub fn AM_InstallTitleResume(mediaType: FS_MediaType, titleId: u64_) |
||||
-> Result; |
||||
pub fn AM_InstallTitleAbort() -> Result; |
||||
pub fn AM_InstallTitleFinish() -> Result; |
||||
pub fn AM_CommitImportTitles(mediaType: FS_MediaType, titleCount: u32_, |
||||
temp: u8, titleIds: *mut u64_) -> Result; |
||||
pub fn AM_InstallTmdBegin(tmdHandle: *mut Handle) -> Result; |
||||
pub fn AM_InstallTmdAbort(tmdHandle: Handle) -> Result; |
||||
pub fn AM_InstallTmdFinish(tmdHandle: Handle, unk: u8) -> Result; |
||||
pub fn AM_CreateImportContentContexts(contentCount: u32_, |
||||
contentIndices: *mut u16_) |
||||
-> Result; |
||||
pub fn AM_InstallContentBegin(contentHandle: *mut Handle, index: u16_) |
||||
-> Result; |
||||
pub fn AM_InstallContentStop(contentHandle: Handle) -> Result; |
||||
pub fn AM_InstallContentResume(contentHandle: *mut Handle, |
||||
resumeOffset: *mut u64_, index: u16_) |
||||
-> Result; |
||||
pub fn AM_InstallContentCancel(contentHandle: Handle) -> Result; |
||||
pub fn AM_InstallContentFinish(contentHandle: Handle) -> Result; |
||||
pub fn AM_ImportCertificates(cert1Size: u32_, cert1: *mut ::libc::c_void, |
||||
cert2Size: u32_, cert2: *mut ::libc::c_void, |
||||
cert3Size: u32_, cert3: *mut ::libc::c_void, |
||||
cert4Size: u32_, cert4: *mut ::libc::c_void) |
||||
-> Result; |
||||
pub fn AM_ImportCertificate(certSize: u32_, cert: *mut ::libc::c_void) |
||||
-> Result; |
||||
pub fn AM_CommitImportTitlesAndUpdateFirmwareAuto(mediaType: FS_MediaType, |
||||
titleCount: u32_, |
||||
temp: u8, |
||||
titleIds: *mut u64_) |
||||
-> Result; |
||||
} |
||||
use ::types::*; |
||||
use super::fs::FS_MediaType; |
||||
|
@ -0,0 +1,18 @@
@@ -0,0 +1,18 @@
|
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
extern "C" { |
||||
pub fn ampxiInit(servhandle: Handle) -> Result; |
||||
pub fn ampxiExit(); |
||||
pub fn AMPXI_WriteTWLSavedata(titleid: u64_, buffer: *mut u8_, size: u32_, |
||||
image_filepos: u32_, section_type: u8_, |
||||
operation: u8_) -> Result; |
||||
pub fn AMPXI_InstallTitlesFinish(mediaType: FS_MediaType, db: u8_, |
||||
titlecount: u32_, tidlist: *mut u64_) |
||||
-> Result; |
||||
} |
||||
use ::types::*; |
||||
use super::fs::FS_MediaType; |
@ -1,14 +1,19 @@
@@ -1,14 +1,19 @@
|
||||
use ::Result; |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
extern "C" { |
||||
pub fn cfgnorInit(value: u8) -> Result; |
||||
pub fn cfgnorInit(value: u8_) -> Result; |
||||
pub fn cfgnorExit(); |
||||
pub fn cfgnorDumpFlash(buf: *mut u32, size: u32) -> Result; |
||||
pub fn cfgnorWriteFlash(buf: *mut u32, size: u32) -> Result; |
||||
pub fn CFGNOR_Initialize(value: u8) -> Result; |
||||
pub fn cfgnorDumpFlash(buf: *mut u32_, size: u32_) -> Result; |
||||
pub fn cfgnorWriteFlash(buf: *mut u32_, size: u32_) -> Result; |
||||
pub fn CFGNOR_Initialize(value: u8_) -> Result; |
||||
pub fn CFGNOR_Shutdown() -> Result; |
||||
pub fn CFGNOR_ReadData(offset: u32, buf: *mut u32, size: u32) |
||||
pub fn CFGNOR_ReadData(offset: u32_, buf: *mut u32_, size: u32_) |
||||
-> Result; |
||||
pub fn CFGNOR_WriteData(offset: u32, buf: *mut u32, size: u32) |
||||
pub fn CFGNOR_WriteData(offset: u32_, buf: *mut u32_, size: u32_) |
||||
-> Result; |
||||
} |
||||
use ::types::*; |
||||
|
@ -1,48 +1,45 @@
@@ -1,48 +1,45 @@
|
||||
use ::{Handle, Result}; |
||||
use ::libc::c_void; |
||||
|
||||
#[repr(C)] |
||||
#[derive(Clone, Copy)] |
||||
pub enum DSP_InterruptType { |
||||
DSP_INTERRUPT_PIPE = 2, |
||||
} |
||||
|
||||
#[repr(C)] |
||||
#[derive(Clone, Copy)] |
||||
pub enum DSP_PipeDirection { |
||||
DSP_PIPE_INPUT = 0, |
||||
DSP_PIPE_OUTPUT = 1, |
||||
} |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum DSP_InterruptType { DSP_INTERRUPT_PIPE = 2, } |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum DSP_PipeDirection { DSP_PIPE_INPUT = 0, DSP_PIPE_OUTPUT = 1, } |
||||
extern "C" { |
||||
pub fn dspInit() -> Result; |
||||
pub fn dspExit(); |
||||
pub fn DSP_GetHeadphoneStatus(is_inserted: *mut u8) -> Result; |
||||
pub fn DSP_FlushDataCache(address: *const c_void, |
||||
size: u32) -> Result; |
||||
pub fn DSP_InvalidateDataCache(address: *const c_void, |
||||
size: u32) -> Result; |
||||
pub fn DSP_FlushDataCache(address: *const ::libc::c_void, size: u32_) |
||||
-> Result; |
||||
pub fn DSP_InvalidateDataCache(address: *const ::libc::c_void, size: u32_) |
||||
-> Result; |
||||
pub fn DSP_GetSemaphoreHandle(semaphore: *mut Handle) -> Result; |
||||
pub fn DSP_SetSemaphore(value: u16) -> Result; |
||||
pub fn DSP_SetSemaphoreMask(mask: u16) -> Result; |
||||
pub fn DSP_LoadComponent(component: *const c_void, |
||||
size: u32, prog_mask: u16, data_mask: u16, |
||||
pub fn DSP_SetSemaphore(value: u16_) -> Result; |
||||
pub fn DSP_SetSemaphoreMask(mask: u16_) -> Result; |
||||
pub fn DSP_LoadComponent(component: *const ::libc::c_void, size: u32_, |
||||
prog_mask: u16_, data_mask: u16_, |
||||
is_loaded: *mut u8) -> Result; |
||||
pub fn DSP_UnloadComponent() -> Result; |
||||
pub fn DSP_RegisterInterruptEvents(handle: Handle, interrupt: u32, |
||||
channel: u32) -> Result; |
||||
pub fn DSP_ReadPipeIfPossible(channel: u32, peer: u32, |
||||
buffer: *mut c_void, |
||||
length: u16, length_read: *mut u16) |
||||
-> Result; |
||||
pub fn DSP_WriteProcessPipe(channel: u32, |
||||
buffer: *const c_void, |
||||
length: u32) -> Result; |
||||
pub fn DSP_ConvertProcessAddressFromDspDram(dsp_address: u32, |
||||
arm_address: *mut u32) |
||||
pub fn DSP_RegisterInterruptEvents(handle: Handle, interrupt: u32_, |
||||
channel: u32_) -> Result; |
||||
pub fn DSP_ReadPipeIfPossible(channel: u32_, peer: u32_, |
||||
buffer: *mut ::libc::c_void, length: u16_, |
||||
length_read: *mut u16_) -> Result; |
||||
pub fn DSP_WriteProcessPipe(channel: u32_, buffer: *const ::libc::c_void, |
||||
length: u32_) -> Result; |
||||
pub fn DSP_ConvertProcessAddressFromDspDram(dsp_address: u32_, |
||||
arm_address: *mut u32_) |
||||
-> Result; |
||||
pub fn DSP_RecvData(regNo: u16, value: *mut u16) -> Result; |
||||
pub fn DSP_RecvDataIsReady(regNo: u16, is_ready: *mut u8) -> Result; |
||||
pub fn DSP_SendData(regNo: u16, value: u16) -> Result; |
||||
pub fn DSP_SendDataIsEmpty(regNo: u16, is_empty: *mut u8) -> Result; |
||||
pub fn DSP_RecvData(regNo: u16_, value: *mut u16_) -> Result; |
||||
pub fn DSP_RecvDataIsReady(regNo: u16_, is_ready: *mut u8) -> Result; |
||||
pub fn DSP_SendData(regNo: u16_, value: u16_) -> Result; |
||||
pub fn DSP_SendDataIsEmpty(regNo: u16_, is_empty: *mut u8) -> Result; |
||||
} |
||||
use ::types::*; |
||||
|
@ -1,13 +0,0 @@
@@ -1,13 +0,0 @@
|
||||
use ::Result; |
||||
use ::libc::c_void; |
||||
|
||||
|
||||
extern "C" { |
||||
pub fn hbInit() -> Result; |
||||
pub fn hbExit() -> (); |
||||
pub fn HB_FlushInvalidateCache() -> Result; |
||||
pub fn HB_GetBootloaderAddresses(load3dsx: *mut *mut c_void, setArgv: *mut *mut c_void)
|
||||
-> Result; |
||||
pub fn HB_ReprotectMemory(addr: *mut u32, pages: u32, mode: u32, reprotectedPages: *mut u32)
|
||||
-> Result; |
||||
} |
@ -1,79 +1,126 @@
@@ -1,79 +1,126 @@
|
||||
use ::{Handle, Result}; |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
#[repr(C)] |
||||
#[derive(Copy)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct httpcContext { |
||||
pub servhandle: Handle, |
||||
pub httphandle: u32, |
||||
} |
||||
impl ::core::clone::Clone for httpcContext { |
||||
fn clone(&self) -> Self { *self } |
||||
pub httphandle: u32_, |
||||
} |
||||
impl ::core::default::Default for httpcContext { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
|
||||
#[derive(Clone, Copy)] |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum HTTPC_RequestMethod { |
||||
HTTPC_METHOD_GET = 1, |
||||
HTTPC_METHOD_POST = 2, |
||||
HTTPC_METHOD_HEAD = 3, |
||||
HTTPC_METHOD_PUT = 4, |
||||
HTTPC_METHOD_DELETE = 5, |
||||
} |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum HTTPC_RequestStatus { |
||||
HTTPC_STATUS_REQUEST_IN_PROGRESS = 5, |
||||
HTTPC_STATUS_DOWNLOAD_READY = 7, |
||||
} |
||||
|
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum HTTPC_KeepAlive { |
||||
HTTPC_KEEPALIVE_DISABLED = 0, |
||||
HTTPC_KEEPALIVE_ENABLED = 1, |
||||
} |
||||
extern "C" { |
||||
pub fn httpcInit() -> Result; |
||||
pub fn httpcInit(sharedmem_size: u32_) -> Result; |
||||
pub fn httpcExit(); |
||||
pub fn httpcOpenContext(context: *mut httpcContext, |
||||
url: *mut u8, |
||||
use_defaultproxy: u32) -> Result; |
||||
method: HTTPC_RequestMethod, |
||||
url: *const ::libc::c_char, |
||||
use_defaultproxy: u32_) -> Result; |
||||
pub fn httpcCloseContext(context: *mut httpcContext) -> Result; |
||||
pub fn httpcCancelConnection(context: *mut httpcContext) -> Result; |
||||
pub fn httpcAddRequestHeaderField(context: *mut httpcContext, |
||||
name: *mut u8, |
||||
value: *mut u8) |
||||
-> Result; |
||||
name: *const ::libc::c_char, |
||||
value: *const ::libc::c_char) -> Result; |
||||
pub fn httpcAddPostDataAscii(context: *mut httpcContext, |
||||
name: *const ::libc::c_char, |
||||
value: *const ::libc::c_char) -> Result; |
||||
pub fn httpcAddPostDataRaw(context: *mut httpcContext, data: *const u32_, |
||||
len: u32_) -> Result; |
||||
pub fn httpcBeginRequest(context: *mut httpcContext) -> Result; |
||||
pub fn httpcReceiveData(context: *mut httpcContext, buffer: *mut u8, |
||||
size: u32) -> Result; |
||||
pub fn httpcReceiveData(context: *mut httpcContext, buffer: *mut u8_, |
||||
size: u32_) -> Result; |
||||
pub fn httpcReceiveDataTimeout(context: *mut httpcContext, |
||||
buffer: *mut u8_, size: u32_, |
||||
timeout: u64_) -> Result; |
||||
pub fn httpcGetRequestState(context: *mut httpcContext, |
||||
out: *mut HTTPC_RequestStatus) -> Result; |
||||
pub fn httpcGetDownloadSizeState(context: *mut httpcContext, |
||||
downloadedsize: *mut u32, |
||||
contentsize: *mut u32) -> Result; |
||||
downloadedsize: *mut u32_, |
||||
contentsize: *mut u32_) -> Result; |
||||
pub fn httpcGetResponseStatusCode(context: *mut httpcContext, |
||||
out: *mut u32, delay: u64) -> Result; |
||||
out: *mut u32_) -> Result; |
||||
pub fn httpcGetResponseStatusCodeTimeout(context: *mut httpcContext, |
||||
out: *mut u32_, timeout: u64_) |
||||
-> Result; |
||||
pub fn httpcGetResponseHeader(context: *mut httpcContext, |
||||
name: *mut u8, |
||||
value: *mut u8, |
||||
valuebuf_maxsize: u32) -> Result; |
||||
pub fn httpcDownloadData(context: *mut httpcContext, buffer: *mut u8, |
||||
size: u32, downloadedsize: *mut u32) -> Result; |
||||
pub fn HTTPC_Initialize(handle: Handle) -> Result; |
||||
pub fn HTTPC_InitializeConnectionSession(handle: Handle, |
||||
contextHandle: Handle) -> Result; |
||||
pub fn HTTPC_CreateContext(handle: Handle, |
||||
url: *mut u8, |
||||
contextHandle: *mut Handle) -> Result; |
||||
pub fn HTTPC_CloseContext(handle: Handle, contextHandle: Handle) |
||||
name: *const ::libc::c_char, |
||||
value: *mut ::libc::c_char, |
||||
valuebuf_maxsize: u32_) -> Result; |
||||
pub fn httpcAddTrustedRootCA(context: *mut httpcContext, cert: *const u8_, |
||||
certsize: u32_) -> Result; |
||||
pub fn httpcAddDefaultCert(context: *mut httpcContext, |
||||
certID: SSLC_DefaultRootCert) -> Result; |
||||
pub fn httpcSelectRootCertChain(context: *mut httpcContext, |
||||
RootCertChain_contexthandle: u32_) |
||||
-> Result; |
||||
pub fn HTTPC_SetProxyDefault(handle: Handle, contextHandle: Handle) |
||||
pub fn httpcSetClientCert(context: *mut httpcContext, cert: *const u8_, |
||||
certsize: u32_, privk: *const u8_, |
||||
privk_size: u32_) -> Result; |
||||
pub fn httpcSetClientCertDefault(context: *mut httpcContext, |
||||
certID: SSLC_DefaultClientCert) |
||||
-> Result; |
||||
pub fn HTTPC_AddRequestHeaderField(handle: Handle, contextHandle: Handle, |
||||
name: *mut u8, |
||||
value: *mut u8) |
||||
pub fn httpcSetClientCertContext(context: *mut httpcContext, |
||||
ClientCert_contexthandle: u32_) |
||||
-> Result; |
||||
pub fn HTTPC_BeginRequest(handle: Handle, contextHandle: Handle) |
||||
pub fn httpcSetSSLOpt(context: *mut httpcContext, options: u32_) |
||||
-> Result; |
||||
pub fn HTTPC_ReceiveData(handle: Handle, contextHandle: Handle, |
||||
buffer: *mut u8, size: u32) -> Result; |
||||
pub fn HTTPC_GetRequestState(handle: Handle, contextHandle: Handle, |
||||
out: *mut HTTPC_RequestStatus) -> Result; |
||||
pub fn HTTPC_GetDownloadSizeState(handle: Handle, contextHandle: Handle, |
||||
downloadedsize: *mut u32, |
||||
contentsize: *mut u32) -> Result; |
||||
pub fn HTTPC_GetResponseHeader(handle: Handle, contextHandle: Handle, |
||||
name: *mut u8, |
||||
value: *mut u8, |
||||
valuebuf_maxsize: u32) -> Result; |
||||
pub fn HTTPC_GetResponseStatusCode(handle: Handle, contextHandle: Handle, |
||||
out: *mut u32) -> Result; |
||||
pub fn httpcSetSSLClearOpt(context: *mut httpcContext, options: u32_) |
||||
-> Result; |
||||
pub fn httpcCreateRootCertChain(RootCertChain_contexthandle: *mut u32_) |
||||
-> Result; |
||||
pub fn httpcDestroyRootCertChain(RootCertChain_contexthandle: u32_) |
||||
-> Result; |
||||
pub fn httpcRootCertChainAddCert(RootCertChain_contexthandle: u32_, |
||||
cert: *const u8_, certsize: u32_, |
||||
cert_contexthandle: *mut u32_) -> Result; |
||||
pub fn httpcRootCertChainAddDefaultCert(RootCertChain_contexthandle: u32_, |
||||
certID: SSLC_DefaultRootCert, |
||||
cert_contexthandle: *mut u32_) |
||||
-> Result; |
||||
pub fn httpcRootCertChainRemoveCert(RootCertChain_contexthandle: u32_, |
||||
cert_contexthandle: u32_) -> Result; |
||||
pub fn httpcOpenClientCertContext(cert: *const u8_, certsize: u32_, |
||||
privk: *const u8_, privk_size: u32_, |
||||
ClientCert_contexthandle: *mut u32_) |
||||
-> Result; |
||||
pub fn httpcOpenDefaultClientCertContext(certID: SSLC_DefaultClientCert, |
||||
ClientCert_contexthandle: |
||||
*mut u32_) -> Result; |
||||
pub fn httpcCloseClientCertContext(ClientCert_contexthandle: u32_) |
||||
-> Result; |
||||
pub fn httpcDownloadData(context: *mut httpcContext, buffer: *mut u8_, |
||||
size: u32_, downloadedsize: *mut u32_) -> Result; |
||||
pub fn httpcSetKeepAlive(context: *mut httpcContext, |
||||
option: HTTPC_KeepAlive) -> Result; |
||||
} |
||||
use ::types::*; |
||||
use super::sslc::*; |
||||
|
@ -1,21 +1,25 @@
@@ -1,21 +1,25 @@
|
||||
use ::{Result, Handle}; |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
extern "C" { |
||||
pub fn iruInit(sharedmem_addr: *mut u32, sharedmem_size: u32) -> Result; |
||||
pub fn iruInit(sharedmem_addr: *mut u32_, sharedmem_size: u32_) -> Result; |
||||
pub fn iruExit(); |
||||
pub fn iruGetServHandle() -> Handle; |
||||
pub fn iruSendData(buf: *mut u8, size: u32, wait: u8) -> Result; |
||||
pub fn iruRecvData(buf: *mut u8, size: u32, flag: u8, |
||||
transfercount: *mut u32, wait: u8) -> Result; |
||||
pub fn iruSendData(buf: *mut u8_, size: u32_, wait: u8) -> Result; |
||||
pub fn iruRecvData(buf: *mut u8_, size: u32_, flag: u8_, |
||||
transfercount: *mut u32_, wait: u8) -> Result; |
||||
pub fn IRU_Initialize() -> Result; |
||||
pub fn IRU_Shutdown() -> Result; |
||||
pub fn IRU_StartSendTransfer(buf: *mut u8, size: u32) -> Result; |
||||
pub fn IRU_StartSendTransfer(buf: *mut u8_, size: u32_) -> Result; |
||||
pub fn IRU_WaitSendTransfer() -> Result; |
||||
pub fn IRU_StartRecvTransfer(size: u32, flag: u8) -> Result; |
||||
pub fn IRU_WaitRecvTransfer(transfercount: *mut u32) -> Result; |
||||
pub fn IRU_SetBitRate(value: u8) -> Result; |
||||
pub fn IRU_GetBitRate(out: *mut u8) -> Result; |
||||
pub fn IRU_SetIRLEDState(value: u32) -> Result; |
||||
pub fn IRU_GetIRLEDRecvState(out: *mut u32) -> Result; |
||||
pub fn IRU_StartRecvTransfer(size: u32_, flag: u8_) -> Result; |
||||
pub fn IRU_WaitRecvTransfer(transfercount: *mut u32_) -> Result; |
||||
pub fn IRU_SetBitRate(value: u8_) -> Result; |
||||
pub fn IRU_GetBitRate(out: *mut u8_) -> Result; |
||||
pub fn IRU_SetIRLEDState(value: u32_) -> Result; |
||||
pub fn IRU_GetIRLEDRecvState(out: *mut u32_) -> Result; |
||||
} |
||||
|
||||
use ::types::*; |
||||
|
@ -1,20 +1,24 @@
@@ -1,20 +1,24 @@
|
||||
use ::types::*; |
||||
|
||||
use super::hid::circlePosition; |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
extern "C" { |
||||
pub static mut irrstMemHandle: Handle; |
||||
pub static mut irrstSharedMem: *mut vu32; |
||||
|
||||
} |
||||
extern "C" { |
||||
pub fn irrstInit() -> Result; |
||||
pub fn irrstExit(); |
||||
pub fn irrstScanInput(); |
||||
pub fn irrstKeysHeld() -> u32; |
||||
pub fn irrstKeysHeld() -> u32_; |
||||
pub fn irrstCstickRead(pos: *mut circlePosition); |
||||
pub fn irrstWaitForEvent(nextEvent: u8); |
||||
pub fn IRRST_GetHandles(outMemHandle: *mut Handle, |
||||
outEventHandle: *mut Handle) -> Result; |
||||
pub fn IRRST_Initialize(unk1: u32, unk2: u8) -> Result; |
||||
pub fn IRRST_Initialize(unk1: u32_, unk2: u8_) -> Result; |
||||
pub fn IRRST_Shutdown() -> Result; |
||||
|
||||
} |
||||
use ::types::*; |
||||
use super::hid::*; |
||||
|
@ -1,42 +1,47 @@
@@ -1,42 +1,47 @@
|
||||
use ::{Handle, Result}; |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#[derive(Clone, Copy)] |
||||
#[repr(C)] |
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum MICU_Encoding { |
||||
MICU_ENCODING_PCM8 = 0, |
||||
MICU_ENCODING_PCM16 = 1, |
||||
MICU_ENCODING_PCM8_SIGNED = 2, |
||||
MICU_ENCODING_PCM16_SIGNED = 3, |
||||
} |
||||
|
||||
#[derive(Clone, Copy)] |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum MICU_SampleRate { |
||||
MICU_SAMPLE_RATE_32730 = 0, |
||||
MICU_SAMPLE_RATE_16360 = 1, |
||||
MICU_SAMPLE_RATE_10910 = 2, |
||||
MICU_SAMPLE_RATE_8180 = 3, |
||||
} |
||||
|
||||
extern "C" { |
||||
pub fn micInit(buffer: *mut u8, bufferSize: u32) -> Result; |
||||
pub fn micInit(buffer: *mut u8_, bufferSize: u32_) -> Result; |
||||
pub fn micExit(); |
||||
pub fn micGetSampleDataSize() -> u32; |
||||
pub fn micGetLastSampleOffset() -> u32; |
||||
pub fn MICU_MapSharedMem(size: u32, handle: Handle) -> Result; |
||||
pub fn micGetSampleDataSize() -> u32_; |
||||
pub fn micGetLastSampleOffset() -> u32_; |
||||
pub fn MICU_MapSharedMem(size: u32_, handle: Handle) -> Result; |
||||
pub fn MICU_UnmapSharedMem() -> Result; |
||||
pub fn MICU_StartSampling(encoding: MICU_Encoding, |
||||
sampleRate: MICU_SampleRate, offset: u32, |
||||
size: u32, _loop: u8) -> Result; |
||||
sampleRate: MICU_SampleRate, offset: u32_, |
||||
size: u32_, loop_: u8) -> Result; |
||||
pub fn MICU_AdjustSampling(sampleRate: MICU_SampleRate) -> Result; |
||||
pub fn MICU_StopSampling() -> Result; |
||||
pub fn MICU_IsSampling(sampling: *mut u8) -> Result; |
||||
pub fn MICU_GetEventHandle(handle: *mut Handle) -> Result; |
||||
pub fn MICU_SetGain(gain: u8) -> Result; |
||||
pub fn MICU_GetGain(gain: *mut u8) -> Result; |
||||
pub fn MICU_SetGain(gain: u8_) -> Result; |
||||
pub fn MICU_GetGain(gain: *mut u8_) -> Result; |
||||
pub fn MICU_SetPower(power: u8) -> Result; |
||||
pub fn MICU_GetPower(power: *mut u8) -> Result; |
||||
pub fn MICU_SetClamp(clamp: u8) -> Result; |
||||
pub fn MICU_GetClamp(clamp: *mut u8) -> Result; |
||||
pub fn MICU_SetAllowShellClosed(allowShellClosed: u8) -> Result; |
||||
} |
||||
use ::types::*; |
||||
|
@ -1,67 +0,0 @@
@@ -1,67 +0,0 @@
|
||||
use ::Result; |
||||
|
||||
#[derive(Clone, Copy)] |
||||
#[repr(C)] |
||||
pub enum MVDSTD_Mode { |
||||
MVDMODE_COLORFORMATCONV = 0, |
||||
MVDMODE_VIDEOPROCESSING = 1, |
||||
} |
||||
|
||||
#[derive(Clone, Copy)] |
||||
#[repr(C)] |
||||
pub enum MVDSTD_InputFormat { |
||||
MVD_INPUT_YUYV422 = 65537, |
||||
MVD_INPUT_H264 = 131073, |
||||
} |
||||
|
||||
#[derive(Clone, Copy)] |
||||
#[repr(C)] |
||||
pub enum MVDSTD_OutputFormat { MVD_OUTPUT_RGB565 = 262146, } |
||||
|
||||
#[repr(C)] |
||||
#[derive(Copy)] |
||||
pub struct MVDSTD_Config { |
||||
pub input_type: MVDSTD_InputFormat, |
||||
pub unk_x04: u32, |
||||
pub unk_x08: u32, |
||||
pub inwidth: u32, |
||||
pub inheight: u32, |
||||
pub physaddr_colorconv_indata: u32, |
||||
pub unk_x18: [u32; 10usize], |
||||
pub flag_x40: u32, |
||||
pub unk_x44: u32, |
||||
pub unk_x48: u32, |
||||
pub outheight0: u32, |
||||
pub outwidth0: u32, |
||||
pub unk_x54: u32, |
||||
pub output_type: MVDSTD_OutputFormat, |
||||
pub outwidth1: u32, |
||||
pub outheight1: u32, |
||||
pub physaddr_outdata0: u32, |
||||
pub physaddr_outdata1_colorconv: u32, |
||||
pub unk_x6c: [u32; 44usize], |
||||
} |
||||
impl ::core::clone::Clone for MVDSTD_Config { |
||||
fn clone(&self) -> Self { *self } |
||||
} |
||||
impl ::core::default::Default for MVDSTD_Config { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
|
||||
extern "C" { |
||||
pub fn mvdstdInit(mode: MVDSTD_Mode, input_type: MVDSTD_InputFormat, |
||||
output_type: MVDSTD_OutputFormat, size: u32) -> Result; |
||||
pub fn mvdstdExit(); |
||||
pub fn mvdstdGenerateDefaultConfig(config: *mut MVDSTD_Config, |
||||
input_width: u32, input_height: u32, |
||||
output_width: u32, |
||||
output_height: u32, |
||||
vaddr_colorconv_indata: *mut u32, |
||||
vaddr_outdata0: *mut u32, |
||||
vaddr_outdata1_colorconv: *mut u32); |
||||
pub fn mvdstdProcessFrame(config: *mut MVDSTD_Config, |
||||
h264_vaddr_inframe: *mut u32, |
||||
h264_inframesize: u32, h264_frameid: u32) |
||||
-> Result; |
||||
pub fn MVDSTD_SetConfig(config: *mut MVDSTD_Config) -> Result; |
||||
} |
@ -0,0 +1,23 @@
@@ -0,0 +1,23 @@
|
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum NDM_ExclusiveState { |
||||
EXCLUSIVE_STATE_NONE = 0, |
||||
EXCLUSIVE_STATE_INFRASTRUCTURE = 1, |
||||
EXCLUSIVE_STATE_LOCAL_COMMUNICATIONS = 2, |
||||
EXCLUSIVE_STATE_STREETPASS = 3, |
||||
EXCLUSIVE_STATE_STREETPASS_DATA = 4, |
||||
} |
||||
extern "C" { |
||||
pub fn ndmuInit() -> Result; |
||||
pub fn ndmuExit(); |
||||
pub fn ndmuEnterExclusiveState(state: NDM_ExclusiveState) -> Result; |
||||
pub fn ndmuLeaveExclusiveState() -> Result; |
||||
} |
||||
use ::types::*; |
@ -1,11 +1,52 @@
@@ -1,11 +1,52 @@
|
||||
use ::Result; |
||||
use ::libc::c_void; |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct NotificationHeader { |
||||
pub dataSet: u8, |
||||
pub unread: u8, |
||||
pub enableJPEG: u8, |
||||
pub isSpotPass: u8, |
||||
pub isOptedOut: u8, |
||||
pub unkData: [u8_; 3usize], |
||||
pub processID: u64_, |
||||
pub unkData2: [u8_; 8usize], |
||||
pub jumpParam: u64_, |
||||
pub unkData3: [u8_; 8usize], |
||||
pub time: u64_, |
||||
pub title: [u16_; 32usize], |
||||
} |
||||
impl ::core::default::Default for NotificationHeader { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
extern "C" { |
||||
pub fn newsInit() -> Result; |
||||
pub fn newsExit(); |
||||
pub fn NEWS_AddNotification(title: *const u16, titleLength: u32, |
||||
message: *const u16, messageLength: u32, |
||||
imageData: *const c_void, |
||||
imageSize: u32, jpeg: u8) -> Result; |
||||
pub fn NEWS_AddNotification(title: *const u16_, titleLength: u32_, |
||||
message: *const u16_, messageLength: u32_, |
||||
imageData: *const ::libc::c_void, |
||||
imageSize: u32_, jpeg: u8) -> Result; |
||||
pub fn NEWS_GetTotalNotifications(num: *mut u32_) -> Result; |
||||
pub fn NEWS_SetNotificationHeader(news_id: u32_, |
||||
header: *const NotificationHeader) |
||||
-> Result; |
||||
pub fn NEWS_GetNotificationHeader(news_id: u32_, |
||||
header: *mut NotificationHeader) |
||||
-> Result; |
||||
pub fn NEWS_SetNotificationMessage(news_id: u32_, message: *const u16_, |
||||
size: u32_) -> Result; |
||||
pub fn NEWS_GetNotificationMessage(news_id: u32_, message: *mut u16_, |
||||
size: *mut u32_) -> Result; |
||||
pub fn NEWS_SetNotificationImage(news_id: u32_, |
||||
buffer: *const ::libc::c_void, |
||||
size: u32_) -> Result; |
||||
pub fn NEWS_GetNotificationImage(news_id: u32_, |
||||
buffer: *mut ::libc::c_void, |
||||
size: *mut u32_) -> Result; |
||||
} |
||||
use ::types::*; |
||||
|
@ -0,0 +1,127 @@
@@ -0,0 +1,127 @@
|
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum NFC_OpType { NFC_OpType_1 = 1, NFC_OpType_NFCTag = 2, } |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum NFC_TagState { |
||||
NFC_TagState_Uninitialized = 0, |
||||
NFC_TagState_ScanningStopped = 1, |
||||
NFC_TagState_Scanning = 2, |
||||
NFC_TagState_InRange = 3, |
||||
NFC_TagState_OutOfRange = 4, |
||||
NFC_TagState_DataReady = 5, |
||||
} |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum Enum_Unnamed1 { |
||||
NFC_amiiboFlag_Setup = 16, |
||||
NFC_amiiboFlag_AppDataSetup = 32, |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy)] |
||||
pub struct NFC_TagInfo { |
||||
pub id_offset_size: u16_, |
||||
pub unk_x2: u8_, |
||||
pub unk_x3: u8_, |
||||
pub id: [u8_; 40usize], |
||||
} |
||||
impl ::core::clone::Clone for NFC_TagInfo { |
||||
fn clone(&self) -> Self { *self } |
||||
} |
||||
impl ::core::default::Default for NFC_TagInfo { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy)] |
||||
pub struct NFC_AmiiboSettings { |
||||
pub mii: [u8_; 96usize], |
||||
pub nickname: [u16_; 11usize], |
||||
pub flags: u8_, |
||||
pub countrycodeid: u8_, |
||||
pub setupdate_year: u16_, |
||||
pub setupdate_month: u8_, |
||||
pub setupdate_day: u8_, |
||||
pub unk_x7c: [u8_; 44usize], |
||||
} |
||||
impl ::core::clone::Clone for NFC_AmiiboSettings { |
||||
fn clone(&self) -> Self { *self } |
||||
} |
||||
impl ::core::default::Default for NFC_AmiiboSettings { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy)] |
||||
pub struct NFC_AmiiboConfig { |
||||
pub lastwritedate_year: u16_, |
||||
pub lastwritedate_month: u8_, |
||||
pub lastwritedate_day: u8_, |
||||
pub write_counter: u16_, |
||||
pub val_x6: u16_, |
||||
pub val_x8: u8_, |
||||
pub val_x9: u8_, |
||||
pub val_xa: u16_, |
||||
pub val_xc: u8_, |
||||
pub pagex4_byte3: u8_, |
||||
pub appdata_size: u8_, |
||||
pub zeros: [u8_; 49usize], |
||||
} |
||||
impl ::core::clone::Clone for NFC_AmiiboConfig { |
||||
fn clone(&self) -> Self { *self } |
||||
} |
||||
impl ::core::default::Default for NFC_AmiiboConfig { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy)] |
||||
pub struct NFC_AppDataInitStruct { |
||||
pub data_x0: [u8_; 12usize], |
||||
pub data_xc: [u8_; 48usize], |
||||
} |
||||
impl ::core::clone::Clone for NFC_AppDataInitStruct { |
||||
fn clone(&self) -> Self { *self } |
||||
} |
||||
impl ::core::default::Default for NFC_AppDataInitStruct { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct NFC_AppDataWriteStruct { |
||||
pub id: [u8_; 10usize], |
||||
pub id_size: u8_, |
||||
pub unused_xb: [u8_; 21usize], |
||||
} |
||||
impl ::core::default::Default for NFC_AppDataWriteStruct { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
extern "C" { |
||||
pub fn nfcInit(type_: NFC_OpType) -> Result; |
||||
pub fn nfcExit(); |
||||
pub fn nfcGetSessionHandle() -> Handle; |
||||
pub fn nfcStartScanning(inval: u16_) -> Result; |
||||
pub fn nfcStopScanning(); |
||||
pub fn nfcLoadAmiiboData() -> Result; |
||||
pub fn nfcResetTagScanState() -> Result; |
||||
pub fn nfcUpdateStoredAmiiboData() -> Result; |
||||
pub fn nfcGetTagState(state: *mut NFC_TagState) -> Result; |
||||
pub fn nfcGetTagInfo(out: *mut NFC_TagInfo) -> Result; |
||||
pub fn nfcOpenAppData(amiibo_appid: u32_) -> Result; |
||||
pub fn nfcInitializeWriteAppData(amiibo_appid: u32_, |
||||
buf: *const ::libc::c_void, size: size_t) |
||||
-> Result; |
||||
pub fn nfcReadAppData(buf: *mut ::libc::c_void, size: size_t) -> Result; |
||||
pub fn nfcWriteAppData(buf: *const ::libc::c_void, size: size_t, |
||||
taginfo: *mut NFC_TagInfo) -> Result; |
||||
pub fn nfcGetAmiiboSettings(out: *mut NFC_AmiiboSettings) -> Result; |
||||
pub fn nfcGetAmiiboConfig(out: *mut NFC_AmiiboConfig) -> Result; |
||||
} |
||||
use ::types::*; |
@ -1,9 +1,17 @@
@@ -1,9 +1,17 @@
|
||||
use ::Result; |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
extern "C" { |
||||
pub fn nsInit() -> Result; |
||||
pub fn nsExit(); |
||||
pub fn NS_LaunchTitle(titleid: u64, launch_flags: u32, procid: *mut u32) -> Result; |
||||
pub fn NS_RebootToTitle(mediatype: u8, titleid: u64) -> Result; |
||||
pub fn NS_LaunchFIRM(titleid: u64_) -> Result; |
||||
pub fn NS_LaunchTitle(titleid: u64_, launch_flags: u32_, |
||||
procid: *mut u32_) -> Result; |
||||
pub fn NS_LaunchApplicationFIRM(titleid: u64_, flags: u32_) -> Result; |
||||
pub fn NS_RebootToTitle(mediatype: u8_, titleid: u64_) -> Result; |
||||
pub fn NS_TerminateProcessTID(titleid: u64_) -> Result; |
||||
} |
||||
|
||||
use ::types::*; |
||||
|
@ -1,24 +1,19 @@
@@ -1,24 +1,19 @@
|
||||
use ::{Handle, Result}; |
||||
use ::libc::c_void; |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
extern "C" { |
||||
pub fn pmInit() -> Result; |
||||
pub fn pmExit(); |
||||
pub fn PM_LaunchTitle(mediatype: u8, titleid: u64, launch_flags: u32) |
||||
pub fn PM_LaunchTitle(mediatype: u8_, titleid: u64_, launch_flags: u32_) |
||||
-> Result; |
||||
pub fn PM_GetTitleExheaderFlags(mediatype: u8, titleid: u64, |
||||
out: *mut u8) -> Result; |
||||
pub fn PM_SetFIRMLaunchParams(size: u32, _in: *mut u8) -> Result; |
||||
pub fn PM_GetFIRMLaunchParams(size: u32, out: *mut u8) -> Result; |
||||
pub fn PM_LaunchFIRMSetParams(firm_titleid_low: u32, size: u32, |
||||
_in: *mut u8) -> Result; |
||||
pub fn srvPmInit() -> Result; |
||||
pub fn srvPmExit(); |
||||
pub fn SRVPM_PublishToProcess(notificationId: u32, process: Handle) |
||||
-> Result; |
||||
pub fn SRVPM_PublishToAll(notificationId: u32) -> Result; |
||||
pub fn SRVPM_RegisterProcess(procid: u32, count: u32, |
||||
serviceaccesscontrol: c_void) -> Result; |
||||
pub fn SRVPM_UnregisterProcess(procid: u32) -> Result; |
||||
pub fn PM_GetTitleExheaderFlags(mediatype: u8_, titleid: u64_, |
||||
out: *mut u8_) -> Result; |
||||
pub fn PM_SetFIRMLaunchParams(size: u32_, in_: *mut u8_) -> Result; |
||||
pub fn PM_GetFIRMLaunchParams(size: u32_, out: *mut u8_) -> Result; |
||||
pub fn PM_LaunchFIRMSetParams(firm_titleid_low: u32_, size: u32_, |
||||
in_: *mut u8_) -> Result; |
||||
} |
||||
|
||||
use ::types::*; |
||||
|
@ -0,0 +1,8 @@
@@ -0,0 +1,8 @@
|
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
|
||||
use ::types::*; |
@ -0,0 +1,15 @@
@@ -0,0 +1,15 @@
|
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
extern "C" { |
||||
pub fn ptmSysmInit() -> Result; |
||||
pub fn ptmSysmExit(); |
||||
pub fn PTMSYSM_CheckNew3DS() -> Result; |
||||
pub fn PTMSYSM_ConfigureNew3DSCPU(value: u8_) -> Result; |
||||
pub fn PTMSYSM_ShutdownAsync(timeout: u64_) -> Result; |
||||
pub fn PTMSYSM_RebootAsync(timeout: u64_) -> Result; |
||||
} |
||||
use ::types::*; |
@ -1,7 +1,15 @@
@@ -1,7 +1,15 @@
|
||||
use ::Result; |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
extern "C" { |
||||
pub fn ptmSysmInit() -> Result; |
||||
pub fn ptmSysmExit(); |
||||
pub fn PTMSYSM_ConfigureNew3DSCPU(value: u8) -> Result; |
||||
pub fn PTMSYSM_CheckNew3DS() -> Result; |
||||
pub fn PTMSYSM_ConfigureNew3DSCPU(value: u8_) -> Result; |
||||
pub fn PTMSYSM_ShutdownAsync(timeout: u64_) -> Result; |
||||
pub fn PTMSYSM_RebootAsync(timeout: u64_) -> Result; |
||||
} |
||||
use ::types::*; |
||||
|
@ -1,11 +1,16 @@
@@ -1,11 +1,16 @@
|
||||
use ::Result; |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
extern "C" { |
||||
pub fn ptmuInit() -> Result; |
||||
pub fn ptmuExit(); |
||||
pub fn PTMU_GetShellState(out: *mut u8) -> Result; |
||||
pub fn PTMU_GetBatteryLevel(out: *mut u8) -> Result; |
||||
pub fn PTMU_GetBatteryChargeState(out: *mut u8) -> Result; |
||||
pub fn PTMU_GetPedometerState(out: *mut u8) -> Result; |
||||
pub fn PTMU_GetTotalStepCount(steps: *mut u32) -> Result; |
||||
pub fn PTMU_GetShellState(out: *mut u8_) -> Result; |
||||
pub fn PTMU_GetBatteryLevel(out: *mut u8_) -> Result; |
||||
pub fn PTMU_GetBatteryChargeState(out: *mut u8_) -> Result; |
||||
pub fn PTMU_GetPedometerState(out: *mut u8_) -> Result; |
||||
pub fn PTMU_GetTotalStepCount(steps: *mut u32_) -> Result; |
||||
} |
||||
use ::types::*; |
||||
|
@ -0,0 +1,50 @@
@@ -0,0 +1,50 @@
|
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum PXIDEV_WaitType { |
||||
WAIT_NONE = 0, |
||||
WAIT_SLEEP = 1, |
||||
WAIT_IREQ_RETURN = 2, |
||||
WAIT_IREQ_CONTINUE = 3, |
||||
} |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum PXIDEV_DeassertType { |
||||
DEASSERT_NONE = 0, |
||||
DEASSERT_BEFORE_WAIT = 1, |
||||
DEASSERT_AFTER_WAIT = 2, |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct PXIDEV_SPIBuffer { |
||||
pub ptr: *mut ::libc::c_void, |
||||
pub size: u32_, |
||||
pub transferOption: u8_, |
||||
pub waitOperation: u64_, |
||||
} |
||||
impl ::core::default::Default for PXIDEV_SPIBuffer { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
extern "C" { |
||||
pub fn pxiDevInit() -> Result; |
||||
pub fn pxiDevExit(); |
||||
pub fn PXIDEV_SPIMultiWriteRead(header: *mut PXIDEV_SPIBuffer, |
||||
writeBuffer1: *mut PXIDEV_SPIBuffer, |
||||
readBuffer1: *mut PXIDEV_SPIBuffer, |
||||
writeBuffer2: *mut PXIDEV_SPIBuffer, |
||||
readBuffer2: *mut PXIDEV_SPIBuffer, |
||||
footer: *mut PXIDEV_SPIBuffer) -> Result; |
||||
pub fn PXIDEV_SPIWriteRead(bytesRead: *mut u32_, |
||||
initialWaitOperation: u64_, |
||||
writeBuffer: *mut PXIDEV_SPIBuffer, |
||||
readBuffer: *mut PXIDEV_SPIBuffer) -> Result; |
||||
} |
||||
use ::types::*; |
@ -1,7 +1,108 @@
@@ -1,7 +1,108 @@
|
||||
use ::Result; |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum NetworkOpt { |
||||
NETOPT_MAC_ADDRESS = 4100, |
||||
NETOPT_ARP_TABLE = 12290, |
||||
NETOPT_IP_INFO = 16387, |
||||
NETOPT_IP_MTU = 16388, |
||||
NETOPT_ROUTING_TABLE = 16390, |
||||
NETOPT_UDP_NUMBER = 32770, |
||||
NETOPT_UDP_TABLE = 32771, |
||||
NETOPT_TCP_NUMBER = 36866, |
||||
NETOPT_TCP_TABLE = 36867, |
||||
NETOPT_DNS_TABLE = 45059, |
||||
NETOPT_DHCP_LEASE_TIME = 49153, |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct SOCU_ARPTableEntry { |
||||
pub unk0: u32_, |
||||
pub ip: in_addr, |
||||
pub mac: [u8_; 6usize], |
||||
pub padding: [u8_; 2usize], |
||||
} |
||||
impl ::core::default::Default for SOCU_ARPTableEntry { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct SOCU_IPInfo { |
||||
pub ip: in_addr, |
||||
pub netmask: in_addr, |
||||
pub broadcast: in_addr, |
||||
} |
||||
impl ::core::default::Default for SOCU_IPInfo { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct SOCU_RoutingTableEntry { |
||||
pub dest_ip: in_addr, |
||||
pub netmask: in_addr, |
||||
pub gateway: in_addr, |
||||
pub flags: u32_, |
||||
pub time: u64_, |
||||
} |
||||
impl ::core::default::Default for SOCU_RoutingTableEntry { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct SOCU_UDPTableEntry { |
||||
pub local: sockaddr_storage, |
||||
pub remote: sockaddr_storage, |
||||
} |
||||
impl ::core::default::Default for SOCU_UDPTableEntry { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct SOCU_TCPTableEntry { |
||||
pub state: u32_, |
||||
pub local: sockaddr_storage, |
||||
pub remote: sockaddr_storage, |
||||
} |
||||
impl ::core::default::Default for SOCU_TCPTableEntry { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct SOCU_DNSTableEntry { |
||||
pub family: u32_, |
||||
pub ip: in_addr, |
||||
pub padding: [u8_; 12usize], |
||||
} |
||||
impl ::core::default::Default for SOCU_DNSTableEntry { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
extern "C" { |
||||
pub fn SOC_Init(context_addr: *mut u32, context_size: u32) -> Result; |
||||
pub fn SOC_Exit() -> Result; |
||||
pub fn gethostid() -> i32; |
||||
pub fn socInit(context_addr: *mut u32_, context_size: u32_) -> Result; |
||||
pub fn socExit() -> Result; |
||||
pub fn gethostid() -> ::libc::c_long; |
||||
pub fn gethostname(name: *mut ::libc::c_char, namelen: size_t) |
||||
-> ::libc::c_int; |
||||
pub fn SOCU_ShutdownSockets() -> ::libc::c_int; |
||||
pub fn SOCU_CloseSockets() -> ::libc::c_int; |
||||
pub fn SOCU_GetNetworkOpt(level: ::libc::c_int, optname: NetworkOpt, |
||||
optval: *mut ::libc::c_void, |
||||
optlen: *mut socklen_t) -> ::libc::c_int; |
||||
pub fn SOCU_GetIPInfo(ip: *mut in_addr, netmask: *mut in_addr, |
||||
broadcast: *mut in_addr) -> ::libc::c_int; |
||||
pub fn SOCU_AddGlobalSocket(sockfd: ::libc::c_int) -> ::libc::c_int; |
||||
} |
||||
use ::types::*; |
||||
use sys::socket::*; |
||||
use sys::inaddr::*; |
||||
|
@ -1,12 +1,18 @@
@@ -1,12 +1,18 @@
|
||||
use ::{Handle, Result}; |
||||
use ::libc::c_void; |
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
extern "C" { |
||||
pub fn srvPmInit() -> Result; |
||||
pub fn srvPmExit(); |
||||
pub fn SRVPM_PublishToProcess(notificationId: u32, process: Handle) -> Result; |
||||
pub fn SRVPM_PublishToAll(notificationId: u32) -> Result; |
||||
pub fn SRVPM_RegisterProcess(procid: u32, count: u32, |
||||
serviceaccesscontrol: c_void) -> Result; |
||||
pub fn SRVPM_UnregisterProcess(procid: u32) -> Result; |
||||
pub fn SRVPM_PublishToProcess(notificationId: u32_, process: Handle) |
||||
-> Result; |
||||
pub fn SRVPM_PublishToAll(notificationId: u32_) -> Result; |
||||
pub fn SRVPM_RegisterProcess(procid: u32_, count: u32_, |
||||
serviceaccesscontrol: *mut ::libc::c_void) |
||||
-> Result; |
||||
pub fn SRVPM_UnregisterProcess(procid: u32_) -> Result; |
||||
} |
||||
use ::types::*; |
||||
|
@ -0,0 +1,115 @@
@@ -0,0 +1,115 @@
|
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct sslcContext { |
||||
pub servhandle: Handle, |
||||
pub sslchandle: u32_, |
||||
pub sharedmem_handle: Handle, |
||||
} |
||||
impl ::core::default::Default for sslcContext { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum SSLC_DefaultRootCert { |
||||
SSLC_DefaultRootCert_Nintendo_CA = 1, |
||||
SSLC_DefaultRootCert_Nintendo_CA_G2 = 2, |
||||
SSLC_DefaultRootCert_Nintendo_CA_G3 = 3, |
||||
SSLC_DefaultRootCert_Nintendo_Class2_CA = 4, |
||||
SSLC_DefaultRootCert_Nintendo_Class2_CA_G2 = 5, |
||||
SSLC_DefaultRootCert_Nintendo_Class2_CA_G3 = 6, |
||||
SSLC_DefaultRootCert_CyberTrust = 7, |
||||
SSLC_DefaultRootCert_AddTrust_External_CA = 8, |
||||
SSLC_DefaultRootCert_COMODO = 9, |
||||
SSLC_DefaultRootCert_USERTrust = 10, |
||||
SSLC_DefaultRootCert_DigiCert_EV = 11, |
||||
} |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum SSLC_DefaultClientCert { SSLC_DefaultClientCert_ClCertA = 64, } |
||||
#[derive(Copy, Clone)] |
||||
#[repr(u32)] |
||||
#[derive(Debug)] |
||||
pub enum Enum_Unnamed1 { |
||||
SSLCOPT_Default = 0, |
||||
SSLCOPT_DisableVerify = 512, |
||||
SSLCOPT_TLSv10 = 2048, |
||||
} |
||||
extern "C" { |
||||
pub fn sslcInit(session_handle: Handle) -> Result; |
||||
pub fn sslcExit(); |
||||
pub fn sslcCreateRootCertChain(RootCertChain_contexthandle: *mut u32_) |
||||
-> Result; |
||||
pub fn sslcDestroyRootCertChain(RootCertChain_contexthandle: u32_) |
||||
-> Result; |
||||
pub fn sslcAddTrustedRootCA(RootCertChain_contexthandle: u32_, |
||||
cert: *const u8_, certsize: u32_, |
||||
cert_contexthandle: *mut u32_) -> Result; |
||||
pub fn sslcRootCertChainAddDefaultCert(RootCertChain_contexthandle: u32_, |
||||
certID: SSLC_DefaultRootCert, |
||||
cert_contexthandle: *mut u32_) |
||||
-> Result; |
||||
pub fn sslcRootCertChainRemoveCert(RootCertChain_contexthandle: u32_, |
||||
cert_contexthandle: u32_) -> Result; |
||||
pub fn sslcCreate8CertChain(CertChain_contexthandle: *mut u32_) -> Result; |
||||
pub fn sslcDestroy8CertChain(CertChain_contexthandle: u32_) -> Result; |
||||
pub fn sslc8CertChainAddCert(CertChain_contexthandle: u32_, |
||||
cert: *const u8_, certsize: u32_, |
||||
cert_contexthandle: *mut u32_) -> Result; |
||||
pub fn sslc8CertChainAddDefaultCert(CertChain_contexthandle: u32_, |
||||
certID: u8_, |
||||
cert_contexthandle: *mut u32_) |
||||
-> Result; |
||||
pub fn sslc8CertChainRemoveCert(CertChain_contexthandle: u32_, |
||||
cert_contexthandle: u32_) -> Result; |
||||
pub fn sslcOpenClientCertContext(cert: *const u8_, certsize: u32_, |
||||
key: *const u8_, keysize: u32_, |
||||
ClientCert_contexthandle: *mut u32_) |
||||
-> Result; |
||||
pub fn sslcOpenDefaultClientCertContext(certID: SSLC_DefaultClientCert, |
||||
ClientCert_contexthandle: |
||||
*mut u32_) -> Result; |
||||
pub fn sslcCloseClientCertContext(ClientCert_contexthandle: u32_) |
||||
-> Result; |
||||
pub fn sslcSeedRNG() -> Result; |
||||
pub fn sslcGenerateRandomData(buf: *mut u8_, size: u32_) -> Result; |
||||
pub fn sslcCreateContext(context: *mut sslcContext, sockfd: ::libc::c_int, |
||||
input_opt: u32_, hostname: *const ::libc::c_char) |
||||
-> Result; |
||||
pub fn sslcDestroyContext(context: *mut sslcContext) -> Result; |
||||
pub fn sslcStartConnection(context: *mut sslcContext, |
||||
internal_retval: *mut ::libc::c_int, |
||||
out: *mut u32_) -> Result; |
||||
pub fn sslcRead(context: *mut sslcContext, buf: *mut ::libc::c_void, |
||||
len: size_t, peek: u8) -> Result; |
||||
pub fn sslcWrite(context: *mut sslcContext, buf: *const ::libc::c_void, |
||||
len: size_t) -> Result; |
||||
pub fn sslcContextSetRootCertChain(context: *mut sslcContext, |
||||
handle: u32_) -> Result; |
||||
pub fn sslcContextSetClientCert(context: *mut sslcContext, handle: u32_) |
||||
-> Result; |
||||
pub fn sslcContextSetHandle8(context: *mut sslcContext, handle: u32_) |
||||
-> Result; |
||||
pub fn sslcContextClearOpt(context: *mut sslcContext, bitmask: u32_) |
||||
-> Result; |
||||
pub fn sslcContextGetProtocolCipher(context: *mut sslcContext, |
||||
outprotocols: *mut ::libc::c_char, |
||||
outprotocols_maxsize: u32_, |
||||
outcipher: *mut ::libc::c_char, |
||||
outcipher_maxsize: u32_) -> Result; |
||||
pub fn sslcContextGetState(context: *mut sslcContext, out: *mut u32_) |
||||
-> Result; |
||||
pub fn sslcContextInitSharedmem(context: *mut sslcContext, buf: *mut u8_, |
||||
size: u32_) -> Result; |
||||
pub fn sslcAddCert(context: *mut sslcContext, buf: *const u8_, size: u32_) |
||||
-> Result; |
||||
} |
||||
use ::types::*; |
@ -0,0 +1,6 @@
@@ -0,0 +1,6 @@
|
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
@ -0,0 +1,44 @@
@@ -0,0 +1,44 @@
|
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
|
||||
use ::types::*; |
||||
use super::socket::*; |
||||
|
||||
pub type in_port_t = uint16_t; |
||||
pub type in_addr_t = uint32_t; |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct in_addr { |
||||
pub s_addr: in_addr_t, |
||||
} |
||||
impl ::core::default::Default for in_addr { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct sockaddr_in { |
||||
pub sin_family: sa_family_t, |
||||
pub sin_port: in_port_t, |
||||
pub sin_addr: in_addr, |
||||
pub sin_zero: [::libc::c_uchar; 8usize], |
||||
} |
||||
impl ::core::default::Default for sockaddr_in { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct ip_mreq { |
||||
pub imr_multiaddr: in_addr, |
||||
pub imr_interface: in_addr, |
||||
} |
||||
impl ::core::default::Default for ip_mreq { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
|
@ -1,2 +1,4 @@
@@ -1,2 +1,4 @@
|
||||
pub mod libc; |
||||
pub mod lock; |
||||
pub mod socket; |
||||
pub mod inaddr; |
||||
|
@ -0,0 +1,77 @@
@@ -0,0 +1,77 @@
|
||||
/* automatically generated by rust-bindgen */ |
||||
|
||||
#![allow(dead_code,
|
||||
non_camel_case_types, |
||||
non_upper_case_globals, |
||||
non_snake_case)] |
||||
pub type socklen_t = uint32_t; |
||||
pub type sa_family_t = uint16_t; |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct sockaddr { |
||||
pub sa_family: sa_family_t, |
||||
pub sa_data: [::libc::c_char; 0usize], |
||||
} |
||||
impl ::core::default::Default for sockaddr { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct sockaddr_storage { |
||||
pub ss_family: sa_family_t, |
||||
pub __ss_padding: [::libc::c_char; 26usize], |
||||
} |
||||
impl ::core::default::Default for sockaddr_storage { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
#[repr(C)] |
||||
#[derive(Copy, Clone)] |
||||
#[derive(Debug)] |
||||
pub struct linger { |
||||
pub l_onoff: ::libc::c_int, |
||||
pub l_linger: ::libc::c_int, |
||||
} |
||||
impl ::core::default::Default for linger { |
||||
fn default() -> Self { unsafe { ::core::mem::zeroed() } } |
||||
} |
||||
extern "C" { |
||||
pub fn accept(sockfd: ::libc::c_int, addr: *mut sockaddr, |
||||
addrlen: *mut socklen_t) -> ::libc::c_int; |
||||
pub fn bind(sockfd: ::libc::c_int, addr: *const sockaddr, |
||||
addrlen: socklen_t) -> ::libc::c_int; |
||||
pub fn closesocket(sockfd: ::libc::c_int) -> ::libc::c_int; |
||||
pub fn connect(sockfd: ::libc::c_int, addr: *const sockaddr, |
||||
addrlen: socklen_t) -> ::libc::c_int; |
||||
pub fn getpeername(sockfd: ::libc::c_int, addr: *mut sockaddr, |
||||
addrlen: *mut socklen_t) -> ::libc::c_int; |
||||
pub fn getsockname(sockfd: ::libc::c_int, addr: *mut sockaddr, |
||||
addrlen: *mut socklen_t) -> ::libc::c_int; |
||||
pub fn getsockopt(sockfd: ::libc::c_int, level: ::libc::c_int, |
||||
optname: ::libc::c_int, optval: *mut ::libc::c_void, |
||||
optlen: *mut socklen_t) -> ::libc::c_int; |
||||
pub fn listen(sockfd: ::libc::c_int, backlog: ::libc::c_int) |
||||
-> ::libc::c_int; |
||||
pub fn recv(sockfd: ::libc::c_int, buf: *mut ::libc::c_void, len: size_t, |
||||
flags: ::libc::c_int) -> ssize_t; |
||||
pub fn recvfrom(sockfd: ::libc::c_int, buf: *mut ::libc::c_void, |
||||
len: size_t, flags: ::libc::c_int, |
||||
src_addr: *mut sockaddr, addrlen: *mut socklen_t) |
||||
-> ssize_t; |
||||
pub fn send(sockfd: ::libc::c_int, buf: *const ::libc::c_void, |
||||
len: size_t, flags: ::libc::c_int) -> ssize_t; |
||||
pub fn sendto(sockfd: ::libc::c_int, buf: *const ::libc::c_void, |
||||
len: size_t, flags: ::libc::c_int, |
||||
dest_addr: *const sockaddr, addrlen: socklen_t) -> ssize_t; |
||||
pub fn setsockopt(sockfd: ::libc::c_int, level: ::libc::c_int, |
||||
optname: ::libc::c_int, optval: *const ::libc::c_void, |
||||
optlen: socklen_t) -> ::libc::c_int; |
||||
pub fn shutdown(sockfd: ::libc::c_int, how: ::libc::c_int) |
||||
-> ::libc::c_int; |
||||
pub fn socket(domain: ::libc::c_int, type_: ::libc::c_int, |
||||
protocol: ::libc::c_int) -> ::libc::c_int; |
||||
pub fn sockatmark(sockfd: ::libc::c_int) -> ::libc::c_int; |
||||
} |
||||
|
||||
use ::types::*; |
Loading…
Reference in new issue