Gpio Programming Procedure - Sintrones VBOX-3200 User Manual

In-vehicle computing
Hide thumbs Also See for VBOX-3200:
Table of Contents

Advertisement

Read Ignition Register & Example Code
if
(pFunc != IntPtr.Zero)
{
UInt32
SetPortValType
SetPortVal = (SetPortValType)Marshal.GetDelegateForFunctionPointer(pFunc,
typeof(SetPortValType));
GetPortValType
GetPortVal = (GetPortValType)Marshal.GetDelegateForFunctionPointer(pFunc,
typeof(GetPortValType));
SetPortVal(0x4E, 0x87, 1);
SetPortVal(0x4E, 0x87, 1);
SetPortVal(0x4E, 0x07, 1);
SetPortVal(0x4F, 0x06, 1);
SetPortVal(0x4E, 0xD2, 1);
// Call WinIo to get value
bool
SetPortVal(0x4E, 0xAA, 1);

5.2.2 GPIO Programming Procedure

< // C# use Winio >
(1) Write Register & Example Code
IntPtr
pFunc = GetProcAddress(hMod, "SetPortVal");
if
(pFunc != IntPtr.Zero)
{
SetPortValType
typeof(SetPortValType));
SetPortVal(0x4E, 0x87, 1);
SetPortVal(0x4E, 0x87, 1);
SetPortVal(0x4E, 0x07, 1);
SetPortVal(0x4F, 0x06, 1);
SetPortVal(0x4E, 0xA1, 1);
SetPortVal(0x4F, 0xF0, 1);
SetPortVal(0x4E, 0xAA, 1);
}
User's Manual
PortVal;
Result1 = GetPortVal(0x4F, &PortVal, 1);
SetPortVal = (SetPortValType)Marshal.GetDelegateForFunctionPointer(pFunc,
// Enter Super IO
// Enter Super IO
// Select Logic 7 for GPIO
// Ignition Status Register bit4
// exit PNP mode
// Enter Super IO
// Enter Super IO
// Select Logic 7 for GPIO
//
// Set GPIO 5X Address
// Set GPO 0~3 value = "0" means output is low
// exit PNP mode
5.0 System Resource
// Read GPIO Status
Page 5-4

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the VBOX-3200 and is the answer not in the manual?

Table of Contents