1 //####COPYRIGHTBEGIN####
3 // ----------------------------------------------------------------------------
4 // Copyright (C) 1998, 1999, 2000 Red Hat, Inc.
6 // This program is part of the eCos host tools.
8 // This program is free software; you can redistribute it and/or modify it
9 // under the terms of the GNU General Public License as published by the Free
10 // Software Foundation; either version 2 of the License, or (at your option)
13 // This program is distributed in the hope that it will be useful, but WITHOUT
14 // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
15 // FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
18 // You should have received a copy of the GNU General Public License along with
19 // this program; if not, write to the Free Software Foundation, Inc.,
20 // 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
22 // ----------------------------------------------------------------------------
24 //####COPYRIGHTEND####
25 //=================================================================
31 //=================================================================
32 //=================================================================
33 //#####DESCRIPTIONBEGIN####
38 // Description: Class to drive the X10 controller. This header file is host-independent.
41 //####DESCRIPTIONEND####
44 #include "eCosSerial.h"
49 CX10(LPCTSTR pszPort);
51 bool Power(bool bOn,int cControl1,int cControl2,int &nErr); // Perform a reset on this port, with these control chars
52 bool Ok(){return m_Serial.Ok();}
55 bool PutChar (unsigned char c);
56 bool GetChar (unsigned char &c);
62 bool Send( char c1, char c2,int &nErr); // Send it these bytes and verify the returned checksum