Rewrote A2D.h and D2A.h. Small style changes to the source files.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32789 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
+18
-27
@@ -1,43 +1,34 @@
|
||||
/********************************************************************************
|
||||
/
|
||||
/ File: A2D.h
|
||||
/
|
||||
/ Description: Analog-to-Digital converter class header.
|
||||
/
|
||||
/ Copyright 1996-98, Be Incorporated, All Rights Reserved.
|
||||
/
|
||||
********************************************************************************/
|
||||
|
||||
|
||||
/*
|
||||
* Copyright 2009, Haiku, Inc. All rights reserved.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*/
|
||||
#ifndef _A2D_H
|
||||
#define _A2D_H
|
||||
|
||||
#include <BeBuild.h>
|
||||
#include <stddef.h>
|
||||
#include <SupportDefs.h>
|
||||
|
||||
/* -----------------------------------------------------------------------*/
|
||||
class BA2D {
|
||||
#include <stddef.h>
|
||||
|
||||
class BA2D {
|
||||
public:
|
||||
BA2D();
|
||||
virtual ~BA2D();
|
||||
virtual ~BA2D();
|
||||
|
||||
status_t Open(const char *portName);
|
||||
void Close(void);
|
||||
bool IsOpen(void);
|
||||
status_t Open(const char* portName);
|
||||
void Close();
|
||||
bool IsOpen();
|
||||
|
||||
ssize_t Read(ushort *buf);
|
||||
|
||||
/* -----------------------------------------------------------------------*/
|
||||
ssize_t Read(ushort* buf);
|
||||
|
||||
private:
|
||||
virtual void _ReservedA2D1();
|
||||
virtual void _ReservedA2D2();
|
||||
virtual void _ReservedA2D3();
|
||||
virtual void _ReservedA2D1();
|
||||
virtual void _ReservedA2D2();
|
||||
virtual void _ReservedA2D3();
|
||||
|
||||
int ffd;
|
||||
uint32 _fReserved[3];
|
||||
int fFd;
|
||||
uint32 _fReserved[3];
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif // _A2D_H
|
||||
|
||||
|
||||
+19
-29
@@ -1,45 +1,35 @@
|
||||
/********************************************************************************
|
||||
/
|
||||
/ File: D2A.h
|
||||
/
|
||||
/ Description: Digital-To-Analog converter class header.
|
||||
/
|
||||
/ Copyright 1996-98, Be Incorporated, All Rights Reserved.
|
||||
/
|
||||
********************************************************************************/
|
||||
|
||||
|
||||
/*
|
||||
* Copyright 2009, Haiku, Inc. All rights reserved.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*/
|
||||
#ifndef _D2A_H
|
||||
#define _D2A_H
|
||||
|
||||
#include <BeBuild.h>
|
||||
#include <stddef.h>
|
||||
#include <SupportDefs.h>
|
||||
|
||||
/* -----------------------------------------------------------------------*/
|
||||
class BD2A {
|
||||
#include <stddef.h>
|
||||
|
||||
class BD2A {
|
||||
public:
|
||||
BD2A();
|
||||
virtual ~BD2A();
|
||||
virtual ~BD2A();
|
||||
|
||||
status_t Open(const char *portName);
|
||||
void Close(void);
|
||||
bool IsOpen(void);
|
||||
status_t Open(const char* portName);
|
||||
void Close();
|
||||
bool IsOpen();
|
||||
|
||||
ssize_t Read(uint8 *buf);
|
||||
ssize_t Write(uint8 value);
|
||||
|
||||
/* -----------------------------------------------------------------------*/
|
||||
ssize_t Read(uint8* buf);
|
||||
ssize_t Write(uint8 value);
|
||||
|
||||
private:
|
||||
virtual void _ReservedD2A1();
|
||||
virtual void _ReservedD2A2();
|
||||
virtual void _ReservedD2A3();
|
||||
|
||||
virtual void _ReservedD2A1();
|
||||
virtual void _ReservedD2A2();
|
||||
virtual void _ReservedD2A3();
|
||||
|
||||
int ffd;
|
||||
uint32 _fReserved[3];
|
||||
int fFd;
|
||||
uint32 _fReserved[3];
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif //_D2A_H
|
||||
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include <A2D.h>
|
||||
|
||||
|
||||
BA2D::BA2D()
|
||||
{
|
||||
}
|
||||
@@ -16,27 +17,27 @@ BA2D::~BA2D()
|
||||
|
||||
|
||||
status_t
|
||||
BA2D::Open(const char *portName)
|
||||
BA2D::Open(const char* portName)
|
||||
{
|
||||
return B_ERROR;
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
BA2D::Close(void)
|
||||
BA2D::Close()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
bool
|
||||
BA2D::IsOpen(void)
|
||||
BA2D::IsOpen()
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
ssize_t
|
||||
BA2D::Read(ushort *buf)
|
||||
BA2D::Read(ushort* buf)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -16,27 +16,27 @@ BD2A::~BD2A()
|
||||
|
||||
|
||||
status_t
|
||||
BD2A::Open(const char *portName)
|
||||
BD2A::Open(const char* portName)
|
||||
{
|
||||
return B_ERROR;
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
BD2A::Close(void)
|
||||
BD2A::Close()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
bool
|
||||
BD2A::IsOpen(void)
|
||||
BD2A::IsOpen()
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
ssize_t
|
||||
BD2A::Read(uint8 *buf)
|
||||
BD2A::Read(uint8* buf)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user