1 /*""FILE COMMENT""*******************************************************
2 * System Name	: LPC API for RX62Nxx
3 * File Name		: r_pdl_lpc_RX62Nxx.h
4 * Version		: 1.02
5 * Contents		: LPC API header
6 * Customer		:
7 * Model			:
8 * Order			:
9 * CPU			: RX
10 * Compiler		: RXC
11 * OS			: Nothing
12 * Programmer	:
13 * Note			:
14 ************************************************************************
15 * Copyright, 2011. Renesas Electronics Corporation
16 * and Renesas Solutions Corporation
17 ************************************************************************
18 * History		: 2011.04.08
19 *				: Ver 1.02
20 *				: CS-5 release.
21 *""FILE COMMENT END""**************************************************/
22 
23 #ifndef R_PDL_LPC_RX62Nxx_H
24 #define R_PDL_LPC_RX62Nxx_H
25 
26 #define R_PDL_LPC_BACKUP_AREA_SIZE	32
27 
28 /* Library prototypes */
29 bool R_LPC_CreateAll(
30 	const uint32_t,
31 	const uint32_t
32 );
33 bool R_LPC_ControlAll(
34 	const uint16_t
35 );
36 bool R_LPC_WriteBackupAll(
37 	volatile const uint8_t * const,
38 	const uint8_t
39 );
40 bool R_LPC_ReadBackupAll(
41 	volatile uint8_t * const,
42 	const uint8_t
43 );
44 bool R_LPC_GetStatusAll(
45 	volatile uint16_t * const
46 );
47 bool ReturnFalse(void);
48 
49 /* Macro definitions */
50 
51 #define R_LPC_Create(a, b) \
52 ( \
53 R_LPC_CreateAll( (a), (b) ) \
54 )
55 
56 #define R_LPC_Control(a) \
57 ( \
58 R_LPC_ControlAll( (a) ) \
59 )
60 
61 #define R_LPC_WriteBackup(a, b) \
62 ( \
63 ( ( ((b) > 0) && ((b) <= R_PDL_LPC_BACKUP_AREA_SIZE) ) ) ? \
64 R_LPC_WriteBackupAll( (a), (b) ) : \
65 ReturnFalse() \
66 )
67 
68 #define R_LPC_ReadBackup(a, b) \
69 ( \
70 ( ( ((b) > 0) && ((b) <= R_PDL_LPC_BACKUP_AREA_SIZE) ) ) ? \
71 R_LPC_ReadBackupAll( (a), (b) ) : \
72 ReturnFalse() \
73 )
74 
75 #define R_LPC_GetStatus(a) \
76 ( \
77 R_LPC_GetStatusAll( (a) ) \
78 )
79 
80 #endif
81 /* End of file */
82