Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - guigolum

Pages: [1] 2 3
Developers / Re: knx, linuxmce, eib part, ... help?
« on: July 16, 2009, 06:18:40 pm »
:s i didnt even remember i had done that Telegram part...
(but now i remember i had some bad time translating the float value..)

well, thank you guy, i had not even tried to look in telegram.h/cpp.

what is the other problem now?

Developers / Re: knx, linuxmce, eib part, ... help?
« on: July 16, 2009, 12:09:48 pm »
may you explain me please?

Developers / Re: knx, linuxmce, eib part, ... help?
« on: July 11, 2009, 10:16:32 pm »
Ho my..
I took a look in my code, and am just .. well, I can't find the words. Sooo dirty.
May i try to modify it a bit? removing a big part of those macros..

I would need a way to compile on lmce however.(or i can develop w/o a dev environment, but can't ensure it will compile :p )

I received a mail telling me there was a bug with :
Here's the thing.
We notice a problem in dimming and floatpoint telegram. I explain... the "shortdata" (guessing is 1 bit boolean datatype) telegram works fine. In both direction, menaing the DCE > EIB > eibd > KNX chain works fine and the KNX > eibd > EIB > DCE too.

We have problem with "more than 1 bit datatype" value telegram.
I post two pair of example of Telegram sended One by EIB and one by ETS3.

1) ShortData - Switch ON a Lamp with adress 0/0/4 from 0.0.0 (wich is the pysical adress of eibd).

ETS3  ->  29 BC 00 00 00 04 E1 00 81
EIB     ->  29 BC 00 00 00 04 F1 00 81

Both of those working fine even there's a difference in the in the 7th byte.
2) Set the value of the dimmer to 123 (50% in mce) from phy.adress 0.0.0 to 1/0/0 Value object of the dimmer.

ETS3  ->  29 BC 00 00 08 00 E2 00 80 7F
EIB     ->  29 BC 00 00 08 00 F2 00 80 00

The ETS one works, in fact we found the Level Value in the last byte (7F), the EIB one is broken, we didn't have (always 00) in the value Byte.

I think there's a problem in the function that Build the telegram.

Can u tell me where i can look for debugging? i looked in the 8.10 EIB-eibd source but i did'n found the problem.
"if my memory works fine", when sending a shortdata, a part of the bis are useless, but necessary to reach a given length(see CSMA/CD protocol, which requires the frames to be long enough to allow jamming repliance on an error).

i'd rather get the knx specifications for the second part though..

what template did you use? "dimming lamp"?(if you don't understand my question, then i need to get a fresh look at lmce ^^ )
btw, does it work if you use shutters/blinders/drapes/thermostat template?

I didnt see any obvious bug(but my lack of using cpp templates and inheritance properly.. and my baaad english :p ), so it MAY be a bug from martin koegler's eibd.
what I actually did: I used another program(with the agreement from its creator), wich name is "eibd", and that translate telegrams to the port we use(such as usb, serial port..)
my programm only tells how lmce shall behave with that one program(it's a wrapper - and a weird one), both in emitting orders and in receiving datas. While emitting, on a dimming light, you have the following code in knxdevice.h:
class LightSwitchdimmable:public knxDevice
      DEVICEHEADER( LightSwitchdimmable , 2, "\0\1" ) ;
      virtual Telegram *Command_On(){return createsTelegramFromAddress(1,0);};
      virtual Telegram *Command_Off(){return createsTelegramFromAddress(0,0);};
      virtual Telegram *Command_Set_Level(int level){return createcharTelegramFromAddress(level,1);};
that means, a EIB lightswitchdimmable, when receiving the order "set_level' from lmce, will create a "char" telegram(that means, with a small data) with the data given inside, and send it to it's adress number "1"(so, the second one you fill in lmce administration pannel) with order "set".
the translation from lmce to the "knxdevice" (in my code) is made in function "EIB::ReceivedCommandForChild(args)" in file EIB.cpp, l113. Basically, what we do is:
- check if the device exists in lmce
- translate the data according to the order to send to this and the knxdevice we refer to. In the case of a set_lvl, the line 137 tells us we transalte the level in this way:"         int level= ((unsigned int)atoi(pMessage->m_mapParameters[COMMANDPARAMETER_Level_CONST].c_str())*255)/100;". that is, we use the parameter referenced by "COMMANDPARAMETER_Level_CONST" in the order sent, which is an int, and translate it from a % base ton a /255 base. maybe an error here, if the COMMANDPARAMETER_Level_CONST is not used in lmce.
so, what one should do is:
- add a spy to know if the data is well transfered(I mean, print the value of level on the logger on this line 137)
- if it works, print the ptel data after it is created, to see if it has a good shortdata. Actually, that is already done in the EIB log (/var/log/EIB ? can't remember), by the line 160 in EIB.cpp.
so, the code you may add is
Code: [Select]
LoggerWrapper::GetInstance()->Write(LV_STATUS, "  setlevel made lvl %i from data %s", level, pMessage->m_mapParameters[COMMANDPARAMETER_Level_CONST].c_str()); between l 137 and 138

btw there is an obvious leak in EIB.cpp, l 165. after "sendTelegram(ptel);", one should had "delete(ptel)" which is allocated on the stack

damn, this editing form is small..

Developers / Re: knx, linuxmce, eib part, ... help?
« on: September 18, 2008, 05:52:50 pm »
ok, i have several questions:

1) will you put the "shutters", "blinds" templates? actually, what templates your programm uses, and which of them do you add? i'd like to make my programm work on your specifications

2) how can i get sources of the next version lmce? i mean, i worked on the 7.10, but it seemed not to work with thelast version sources. there was some issues, or i didn't understand well, maybe. is the charon merge source compilable? i need to try and test my programm with the good sources :/

Developers / Re: knx, linuxmce, eib part, ... help?
« on: September 12, 2008, 04:01:44 pm »
hum.. so basically i tryed to do some work that was already being done?

hmm :'(

Developers / Re: knx, linuxmce, eib part, ... help?
« on: September 09, 2008, 05:28:06 pm »
i meant i was in vacations and thus could not work(i don't ever have a server to use for work). now i'm back to school, mickael can let me work and make improvments on lmce.

thank you however :) but if you want to help me, please try to use my program, and then tell me your feelings, and improvments i could do :)

Developers / Re: knx, linuxmce, eib part, ... help?
« on: September 08, 2008, 11:00:07 pm »
devices to deliver? hu?

well, i've decided to make a page on the wiki for an how-to install my EIB:
so that now i can modify the doc w/o having to change the full file.

later i will have to modify some other files too.

feel free to ask here or in the wiki discussion.

Developers / Re: knx, linuxmce, eib part, ... help?
« on: September 07, 2008, 05:43:01 pm »
i need device to work, but my boss should let me make some work more now. i just need to talk to him a bit, to work later. don't worry i have linuxmce, but i couldnt work in august(vacations)

i will post later.

rages: you should d/l the file i linked before, and then compile the source . actually it stil works only for the linuxmce 7.10, i need to be able to use the sources corectly and i think their was still some problmes with sources, wich didn't allow me to compile from next version's source. any how, i have had some thoughts in my vacations and i think i made really dirty programmer job, so i will surely rewrite parts of the code. when i have time, and fully fonctionnal material.

Developers / Re: knx, linuxmce, eib part, ... help?
« on: August 04, 2008, 09:48:40 am »
i am in vacation now... and for 3 weeks.

i can't anymore try to compile/test. i keep thinking about what i could change(in the code), but it's just thoughts.
now i would need ppl to try to compile and test my program. all required is written in the README.. just need feedbacks to improve my work.

Developers / Re: knx, linuxmce, eib part, ... help?
« on: August 01, 2008, 09:57:27 pm »
it was my "stage" so i didn't mean to be paid :)

plus, i am not sure if it works now. so i wouldn't want to get monney for something that may not work.

it works on 710 version(at least, mine). i need ppl to try to make it and use it on a charon-merge station. i can no more try it by myself, since i am in vaccancy and have no knx at home..

Developers / Re: knx, linuxmce, eib part, ... help?
« on: August 01, 2008, 04:26:43 pm »
sensors done( 1 min..) , READ command done(even if it doesn't exist in the sql), so that now when the EIB gets a connection, it asks to every child it owns it state

sending the file as a mantis bug report

just untar the file, read the README
ther are some syntax errors with charon-merge source. need to put a m_ before each " mapParameterFind( "or smthg like this, not sure exactly about what has to be done.

i may work later on that, i think i got some issues yet(basically with eibd..)

Developers / Re: knx, linuxmce, eib part, ... help?
« on: August 01, 2008, 12:56:02 am »
ok, i remade the full code (but still used some part), to be able to make future changes more easy.

i still need to handle the sensors, but that's versy easy. and then, to test.. and make doc. the doc i am making should allow later changes in the templates, quite easily(made of how-to)

the installation is described in the README.txt

basically, i just need now to do some minor changes, then i will send a version to hari. hopping it will work on charon-merge, i have not been able to compile on it(sefgaults when loading getConfig() )

there still may be some bugs, such as memory lacks, i'm not used to map and vector use, plus the templates need to be done(several of them)

ps: i spent today 17H to rewrite the full code. but it was very funny! sure i liked this project!

Developers / Re: knx, linuxmce, eib part, ... help?
« on: July 30, 2008, 02:49:24 pm »
"ppl" is normal linuxmce users.

when you install one dcedevice, you have to configure it. for eibd, you need to know how it connects to gateway. so users must enter either the fulla arg path to eibd, or the couple"bus/address"

and i can't u/l my sources on sqlcvs. only the sqltemplates. and i don't want to make things crash :/

i'm changing the EIB template now. then i will update my code to let users fill their configuration, and make some doc on my code. then i have to get newest templates in order to get a good knx implementation.(EVENT_Level_Changed ...)

then i should change the switch lamp, since it should not receive a COMMAND_SET_LEVEL when one tells it to be put to "on"..
anyhow, i still need to u/l my sources..

Developers / Re: knx, linuxmce, eib part, ... help?
« on: July 30, 2008, 07:52:54 am »
eibd needs to know what is the bus it uses to reach the knx:
eibd --help
supported URLs are:

atm i use eibd with ipt:

i just need to fill the function
void EIB::getAway() in eib.cpp to modify string EIB.sgateway so that it gets the correct eibd format

so i would need:
either ppl to put the full line as arg,
or ppl to just fill the kind of connection to use, + the address
we could anyhow use the three, and modify sgateway according to what was filled. but i think the best would be to ask ppl to fill interface + address.

Developers / Re: knx, linuxmce, eib part, ... help?
« on: July 29, 2008, 03:37:16 pm »

i'm proud to tell you i made something like the EIB but working with eibd.

it still isn't configurable, since i didn't touch the template. it gives the same things that gives the actual EIB, even if there seems to be some bugs still(maybe due to eibd itself ..)
actually i build it with the 710 branch's source, and took much fro the former EIB. to make it work you need to install the eibd:

thanx alot to hari who told me to use pthreads, i didn't know them before and.. well, they seem to work.

now i need to implement the real knx protocol, that is, listening from knx's lamps all the stuff to fire correct events. i need to change its template too, and then implement its configuration... but i don't know how to (i mean, i would need to use sqlcvs..)
how i am supposed to u/l the sources, btw?
the code is atm in 'debugging' mode; so the logs are VERY FULL. there is no more segfault atm, but it will for sure need more tests.

Pages: [1] 2 3