Hi,
sorry for my delayed answer. You need to do following:
To set BAOS module to the right mode you need to switch to link mode.
Replace following in /knxd/src/libserver/cemi.cpp:
CEMILayer2::Open ()
{
if (!Layer2::Open ())
return false;
const uchar t1[] = { 0xF6, 0x00, 0x08, 0x01, 0x34, 0x10, 0x01, 0x00 };
TRACEPRINTF (t, 1, this, "(CEMILayer2) Open");
iface->SendReset ();
iface->Send_Packet (CArray (t1, sizeof (t1)));
while (!iface->Send_Queue_Empty ())
{
pth_event_t
e = pth_event (PTH_EVENT_SEM, iface->Send_Queue_Empty_Cond ());
pth_wait (e);
pth_event_free (e, PTH_FREE_THIS);
}
return true;
}
replace in file : src/server/Makefile.am
-BACKEND_CONF= b-EIBNETIP.h b-FT12.h b-PEI16s.h b-TPUARTs.h b-EIBNETIPTUNNEL.h b-USB.h b-NCN5120.h b-DUMMY.h
+BACKEND_CONF= b-EIBNETIP.h b-FT12.h b-FT12cemi.h b-PEI16s.h b-TPUARTs.h b-EIBNETIPTUNNEL.h b-USB.h b-NCN5120.h b-DUMMY.h
create this file:
src/server/b-FT12cemi.h
/*
EIBD eib bus access and management daemon
Copyright (C) 2005-2011 Martin Koegler <mkoegler@auto.tuwien.ac.at>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
#ifndef C_FT12CEMI_H
#define C_FT12CEMI_H
#include "ft12.h"
#include "cemi.h"
#include "layer3.h"
#define FT12CEMI_URL "ft12cemi:/dev/ttySx\n"
#define FT12CEMI_DOC "ft12cemi connects over a serial line with the FT1.2 Protocol to a Boas module\n\n"
#define FT12CEMI_PREFIX "ft12cemi"
#define FT12CEMI_CREATE ft12cemi_Create
inline Layer2Ptr
ft12cemi_Create (const char *dev, L2options *opt)
{
return std::shared_ptr<CEMILayer2>(new CEMILayer2 (new FT12LowLevelDriver (dev, opt->t), opt));
}
#endif
add this one line with "+" src/server/layer2conf.h
add this one line with "+" in src/server/layer2create.h
After recompile it should work. Come back to me with your results :-)
Br, Robert
sorry for my delayed answer. You need to do following:
To set BAOS module to the right mode you need to switch to link mode.
Replace following in /knxd/src/libserver/cemi.cpp:
CEMILayer2::Open ()
{
if (!Layer2::Open ())
return false;
const uchar t1[] = { 0xF6, 0x00, 0x08, 0x01, 0x34, 0x10, 0x01, 0x00 };
TRACEPRINTF (t, 1, this, "(CEMILayer2) Open");
iface->SendReset ();
iface->Send_Packet (CArray (t1, sizeof (t1)));
while (!iface->Send_Queue_Empty ())
{
pth_event_t
e = pth_event (PTH_EVENT_SEM, iface->Send_Queue_Empty_Cond ());
pth_wait (e);
pth_event_free (e, PTH_FREE_THIS);
}
return true;
}
replace in file : src/server/Makefile.am
-BACKEND_CONF= b-EIBNETIP.h b-FT12.h b-PEI16s.h b-TPUARTs.h b-EIBNETIPTUNNEL.h b-USB.h b-NCN5120.h b-DUMMY.h
+BACKEND_CONF= b-EIBNETIP.h b-FT12.h b-FT12cemi.h b-PEI16s.h b-TPUARTs.h b-EIBNETIPTUNNEL.h b-USB.h b-NCN5120.h b-DUMMY.h
create this file:
src/server/b-FT12cemi.h
/*
EIBD eib bus access and management daemon
Copyright (C) 2005-2011 Martin Koegler <mkoegler@auto.tuwien.ac.at>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
#ifndef C_FT12CEMI_H
#define C_FT12CEMI_H
#include "ft12.h"
#include "cemi.h"
#include "layer3.h"
#define FT12CEMI_URL "ft12cemi:/dev/ttySx\n"
#define FT12CEMI_DOC "ft12cemi connects over a serial line with the FT1.2 Protocol to a Boas module\n\n"
#define FT12CEMI_PREFIX "ft12cemi"
#define FT12CEMI_CREATE ft12cemi_Create
inline Layer2Ptr
ft12cemi_Create (const char *dev, L2options *opt)
{
return std::shared_ptr<CEMILayer2>(new CEMILayer2 (new FT12LowLevelDriver (dev, opt->t), opt));
}
#endif
add this one line with "+" src/server/layer2conf.h
#ifdef HAVE_FT12 | ||
#include "b-FT12.h" | ||
+#include "b-FT12cemi.h" | ||
#endif | ||
#ifdef HAVE_EIBNETIP | ||
#include "b-EIBNETIP.h" |
#ifdef HAVE_FT12 | ||
L2_NAME (FT12) | ||
+ L2_NAME (FT12CEMI) | ||
#endif | ||
#ifdef HAVE_EIBNETIP | ||
L2_NAME (EIBNETIP) |
Br, Robert
Kommentar