📄 can.h
字号:
//******************************************************************************
//*
//* System On Chip(SOC)
//*
//* Copyright (c) 2002 sjsunny, Inc.
//* All rights reserved.
//*
//* This software is the confidential and proprietary information of Sjsunny Sci&Tech
//* , Inc("Confidential Information"). You Shall not disclose such
//* Confidential Information and shall use it only in accordance with the terms
//* of the license agreement you agreed with sjsunny.
//*
//*-----------------------------------------------------------------------------
//*
//* PG9315 BSP (Windows CE.NET)
//*
//* SJA1000 can bus control driver
//*
//* @author WZL@sjsunny.com
//*
//* @date 2005/04/01
//*
//* Log:
//* 2005/04/01 Start
//*
//******************************************************************************/
#ifndef __PGCAN_H__
#define __PGCAN_H__
#include <windows.h>
#include <CEDDK.h>
#define IOCTL_DRIVER_RESET 42
#define IOCTL_DRIVER_WORK 43
#define IOCTL_DRIVER_SET_BANDRATE 44
#define IOCTL_DRIVER_SET_OBJECT 45
#define IOCTL_DRIVER_SET_REG 46
#define IOCTL_DRIVER_DATA_WRITE 47
#define IOCTL_DRIVER_DATA_RECEIVE 48
#define IOCTL_DRIVER_SEND_REQ 49
#define IOCTL_DRIVER_SEND_QUIT 50
#define IOCTL_DRIVER_RELEASE_RBUFF 51
#define IOCTL_DRIVER_CLEAR_OVERLAP 52
#define IOCTL_DRIVER_SLEEP 53
#define IOCTL_DRIVER_CAN_EVENT 54
#define IOCTL_DRIVER_SET_CDR_OCR 55
#ifdef __cplusplus
extern "C" {
#endif
// can.h : Defines the entry point for the DLL application.
//
DWORD CAN_Init(LPCTSTR pContext, LPCVOID lpvBusContext);
BOOL CAN_Deinit( DWORD hDeviceContext );
DWORD CAN_Open( DWORD hDeviceContext, DWORD AccessCode, DWORD ShareMode );
BOOL CAN_Close( DWORD hOpenContext );
BOOL CAN_IOControl( DWORD hOpenContext, DWORD dwCode, PBYTE pBufIn, DWORD dwLenIn, PBYTE pBufOut, DWORD dwLenOut, PDWORD pdwActualOut );
void CAN_PowerUp( DWORD hDeviceContext );
void CAN_PowerDown( DWORD hDeviceContext );
DWORD CAN_Read( DWORD hOpenContext, LPVOID pBuffer, DWORD Count );
DWORD CAN_Write( DWORD hOpenContext, LPVOID pBuffer, DWORD Count );
DWORD CAN_Seek( DWORD hOpenContext, long Amount, WORD Type );
HANDLE m_hCanIntEvent;
#ifdef __cplusplus
}
#endif
#endif // __PGCAN_H__
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -