This page last changed on Feb 02, 2011 by frbusu.

Hi ppl,

I previously had a problem with KNX. I have since gotten into more technical detail ...into cemi frames etc... For writing values it is working perfectly, however i am currently trying to read some values. I have used this format for the CEMI Frame :

06
10
04 : Tunnel req
20
00
15

04
41 : Channel ID
03 : Seq Counter
00 : Reserved

11 : MC
00 : MC
8E : Control Field1
E0 : Control Field2
00 : Source Address Byte1
00 : Source Address Byte2
00 : Dest Add Byte1
01 : Dest Add Byte2
01
00 : KNX Command for read
00

When I send this, I expected to get a tunnel response, however I got nothing. I am perfectly able to write values and the heart beat implementation is also ok. I'm thinking I'm sending something wrong in terms of bytes but i'm not sure what. Can anyone help? Thanks

Regards,
Franco

Hi Franco,

I just found this thread - I guess you already fixed the issue.. However, I was facing the same problems as you when I worked on my project last week. I forgot to set the reading flag of the accessed actors - therefore I haven`t got a proper answer from the gateway. I am new to KNX so don`t blame me for that.
I took a look at what I`m sending over the ethernet for a read request. I think your Control Field 1 could cause the problem. I read that the last two bits of it has to be set to 0 otherwise the telegram wouldn`t be interpreted (and accepted) as a KNX telegram. So you should try to set this field to 8C.
Good luck!

Best regards,
Ulrich

Posted by usteu at Feb 14, 2011 09:57

Hi Ulrich,

Many thanks for your interest. As such, I was still lost there. In terms of control field i tried many variations 8C, 8E, 8F, 8A etc... I have to check the ETS settings for the reading flags...10x for mentioning it. So to be sure we're on the same page....i should set the reading flag of the actuator/s that i am trying to read from right?

I was even considering trying to write to XML file and read from it the sensor values instead of polling the sensors but it doesn't make that much sense and seems like a waste of resources.

In terms of the sequence counter byte are you still incrementing it whether it be a write of read request right?

Thanks and Regards,
Franco

Posted by frbusu at Feb 14, 2011 10:32

Hi Franco,

yes.. it is really a grueling work with this KNX telegrams. However, if you are able to write to certain addresses you should also be able to read from the bus - it is basically the same procedure. You just have to take care that the reading flag of the group address which you are trying to read from is set.
I`m playing around with the Code of OR KNX. I think you should either set the control field to 8C or AC - with AC the telegram is marked as repeated. My code is using AC all the time, so there should be no problem with marking the tunneling requests always as repeated.

Until now I`m listening to the bus and set the actuators to the certain values in my internal data structure. If I`m changing the page in the app I do send reading requests to all the items shown on that page, but I`m not explicitly waiting for the answers from the bus. It seems to work fine.. most times. But I`m not an expert at all - I don`t know whether this procedure is watertight.

With the sequence counter it`s like you said: it is incremented with each tunneling request (write or read doesn`t matter).

Anyways - I guess it is already working -> i bet it was the reading flag.

Best regards,
Ulrich

Posted by usteu at Feb 14, 2011 16:31
Document generated by Confluence on Jun 05, 2016 09:31