1 /*---------------------------------------------------------------------------*
2   Project:  TwlSDK - OS - include
3   File:     pxi.h
4 
5   Copyright 2008 Nintendo.  All rights reserved.
6 
7   These coded instructions, statements, and computer programs contain
8   proprietary information of Nintendo of America Inc. and/or Nintendo
9   Company Ltd., and are protected by Federal copyright law.  They may
10   not be disclosed to third parties or copied or duplicated in any form,
11   in whole or in part, without the prior written consent of Nintendo.
12 
13   $Date:: 2007-07-31#$
14   $Rev: 387 $
15   $Author: nakasima $
16  *---------------------------------------------------------------------------*/
17 
18 #ifndef NITRO_OS_PXI_H_
19 #define NITRO_OS_PXI_H_
20 
21 #ifdef __cplusplus
22 extern "C" {
23 #endif
24 
25 #include <nitro/misc.h>
26 #include <nitro/types.h>
27 #include <nitro/pxi.h>
28 
29 //================================================================================
30 /*---------------------------------------------------------------------------*
31   Name:         OS_IsResetOccurred
32 
33   Description:  get whethre reset event occurred
34 
35   Arguments:    None.
36 
37   Returns:      TRUE  : if reset occurred
38                 FALSE : if not
39  *---------------------------------------------------------------------------*/
40 BOOL    OS_IsResetOccurred(void);
41 
42 #ifdef SDK_TWL
43 
44 /*---------------------------------------------------------------------------*
45   Name:         OSi_IsTerminatePxiOccurred
46 
47   Description:  get status whethre terminate event occurred
48 
49   Arguments:    None.
50 
51   Returns:      TRUE  : if terminate event occurred
52                 FALSE : if not
53  *---------------------------------------------------------------------------*/
54 BOOL    OSi_IsTerminatePxiOccurred(void);
55 
56 #endif // SDK_TWL
57 
58 /*---------------------------------------------------------------------------*
59   Name:         OSi_SetTerminatePxiOccurred
60 
61   Description:  set status of terminate event occurred
62 
63   Arguments:    None.
64 
65   Returns:      None.
66  *---------------------------------------------------------------------------*/
67 #ifdef SDK_TWL
68 void OSi_SetTerminatePxiOccurred(void);
69 #else // SDK_NITRO
70 #define OSi_SetTerminatePxiOccurred()  ((void)0)
71 #endif // SDK_NITRO
72 
73 //================================================================================
74 //-------- internal
75 void OSi_CommonCallback(PXIFifoTag tag, u32 data, BOOL err);
76 void OSi_SendToPxi(u16 data);
77 
78 
79 #ifdef __cplusplus
80 } /* extern "C" */
81 #endif
82 
83 /* NITRO_OS_PXI_H_ */
84 #endif
85