IO Device:F81966 LPC DIO under Linux console

From LEXWiKi

(Difference between revisions)
Jump to: navigation, search
(F81966_DLL Function)
Line 1: Line 1:
- 
== The Sample code source you can download from ==
== The Sample code source you can download from ==
Line 23: Line 22:
== F81966_DLL Function ==
== F81966_DLL Function ==
<pre>
<pre>
-
F81966_DLL_API bool F81966_LPC_Init(pF81966_status status);
+
bool F81966_OPEN();
-
 
+
void F81966_Init();
-
F81966_DLL_API BYTE F81966_LPC_Digital_Read_LOW();
+
void F81966_LPC_Write(BYTE LDNData, BYTE reg, BYTE value);
-
F81966_DLL_API void F81966_LPC_Digital_Write_LOW(BYTE byteValue);
+
BYTE F81966_LPC_Read(BYTE LDNData, BYTE reg);
-
F81966_DLL_API BYTE F81966_LPC_Digital_Read_HIGH();
+
void F81966_LPC_Digital_Write_LOW(BYTE byteValue);
-
F81966_DLL_API void F81966_LPC_Digital_Write_HIGH(BYTE byteValue);
+
void F81966_LPC_Digital_Write_HIGH(BYTE byteValue);
-
 
+
BYTE F81966_LPC_Digital_Read_LOW();
-
F81966_DLL_API void F81966_LPC_Set_WDT_Enable(BYTE byteValue);
+
BYTE F81966_LPC_Digital_Read_HIGH();
-
F81966_DLL_API void F81966_LPC_Set_WDT_Disable();
+
void F81966_LPC_Set_WDT_Enable(BYTE byteValue);
 +
void F81966_LPC_Set_WDT_Disable();
 +
void EntryLPC();
 +
void ExitLPC();
</pre>
</pre>
=== Digital Input/Ooutput test===
=== Digital Input/Ooutput test===

Revision as of 14:46, 30 December 2020

Contents

The Sample code source you can download from

Source file: F81966_LPC_GPIO_Utility_Src_v1.5.zip

Binary file: F81966_LPC_GPIO_Utility_Bin_x86_v1.5.zip F81966_LPC_GPIO_Utility_Bin_x64_v1.5.zip

F81966 DLL : F81966_DLL_x32_v1.0.zip F81966_DLL_x64_v1.0.zip

Introduction F81966 DIO

Image:F81966_1.4.jpg

  1. Start test Button,Send bits one by one and one by one receive
  2. CIO116 mode for CIO116 module use
  3. Set time countdown,If the end of the countdown, the trigger signal to reboot
  4. Enable loop ,Continuously reset the WDT to ensure that when the system is normal, the restart signal will not be triggered

F81966_DLL Function

 bool F81966_OPEN();
 void F81966_Init();
 void F81966_LPC_Write(BYTE LDNData, BYTE reg, BYTE value);
 BYTE F81966_LPC_Read(BYTE LDNData, BYTE reg);
 void F81966_LPC_Digital_Write_LOW(BYTE byteValue);
 void F81966_LPC_Digital_Write_HIGH(BYTE byteValue);
 BYTE F81966_LPC_Digital_Read_LOW();
 BYTE F81966_LPC_Digital_Read_HIGH();
 void F81966_LPC_Set_WDT_Enable(BYTE byteValue);
 void F81966_LPC_Set_WDT_Disable();
 void EntryLPC();
 void ExitLPC();

Digital Input/Ooutput test

Image:F81966_io_define.jpg
sample code

Set CIO1 CIO2 Digital Output all high
F81966_LPC_Digital_Write_LOW(256);

Set CIO1 CIO2 Digital Output all low
F81966_LPC_Digital_Write_LOW(0);

Set CIO1 Digital Output bit 4 high
F81966_LPC_Digital_Write_LOW(16);

Set CIO2 Digital Output bit 10 high
F81966_LPC_Digital_Write_HIGH(4);

Read Din
value = F81966_LPC_Digital_Read_LOW();

Watch Dog test

sample code

Set WDT 10 sec
F81966_LPC_Set_WDT_Enable(10);
Disable WDT
F81966_LPC_Set_WDT_Disable();
Personal tools