Open hpeyrovi opened 13 years ago
double \ showed up as single \ in my msg above.
I have looked into your cbus.js and i have noticed that the command that you have programed into the javascript has \05 with double \ at the begining of the command but it should have \05 with single \ and i tried the double \ with my manual command and it would not work.
I think that two things should be changed in the javascript for this plugin to work for me:
1.Remove the checksum
2.replace \05 double \ with \05 single \
Actually the double \ \ is correct. It is required in JS because the \ is used as an escape character and so to create a single \ backslash character you actually have to use a double one . Only a single \ is sent to C-Bus.
The checksum error has one of several causes:
1)Sometimes even though you set Checksum mode in the PCI when you disconnect it seems to get unset. It does remain set if you can do it from another CNI/PCI using C-Bus Diagnostics. Ideally an initialisation string should be sent to the PCI on connection to ensure it's always in the right mode.
2)The checksum routine if presented with the wrong data returns AN ( truncated from NAN - not a number) which of course is not correct or even hex. CBus Checksum Error: Expected 'AN', received 'AD'
3) C-Bus State information is stored and read back from joins but you need / best to create all three joins in your GUI for each C-Bus group you use (analog, digital and serial). Not having them causes testing against undefined values in the code.
The C-Bus Level MMI messages are only being recognised if originated from and received through a fixed PCI/CNI unit address of 254.
I'm waiting to hear from Ben but I have changed the plugin code slightly and quite a bit of the Javascript to avoid these issues and I will fork it shortly and post an updated version. Let me know if that works for you.
If anyone wants to try out my changes before I add the fork email me (kevin) at my website domain xapautomation.org.
Kevin
Hi Kevin,
Thanks for your reply.
1) I set the mode of the PCI unit using C-Bus Diagnostics to smart and I check mark the checksum option. But when I do this a button created with a manual( not using the JS plugin ) serial string command such as \053800790F\x0D that is meant to turn on lighting group 15 won't work anymore and I get a checksum error. But without the checksum option active on the PCI it works fine. What do you mean by setting it using another PCI? How is an initialization string sent to the PCI to ensure that is always in the right mode? BY the way is it really necessary to have a checksum in your JS? Why not just remove the checksum?
2) I don’t think I'm sending wrong data because the I either input the command manually which always works if not checksum or I use the command generated by the JS.
3) how do I set all joins for a button on GUI? I thought it only had a digital join which was the base join plus the group address number. Let me know how I should do this.
Where would you post your updated plugin? Cause I got mine from Jarrod through Skype. Please give me the link where you would post any updates to the plugin.
Regards,
Hamed
-----Original Message----- From: xAPPO [mailto:reply@reply.github.com] Sent: Sunday, July 24, 2011 8:37 PM To: hpeyrovi@eim.ae Subject: Re: [C-Bus-guiDesigner-Plugin] C-Bus plugin Checksum error (#1)
Actually the double \ \ is correct. It is required in JS because the \ is used as an escape character and so to create a single \ backslash character you actually have to use a double one . Only a single \ is sent to C-Bus.
The checksum error has one of several causes:
1)Sometimes even though you set Checksum mode in the PCI when you disconnect it seems to get unset. It does remain set if you can do it from another CNI/PCI using C-Bus Diagnostics. Ideally an initialisation string should be sent to the PCI on connection to ensure it's always in the right mode.
2)The checksum routine if presented with the wrong data returns AN ( truncated from NAN - not a number) which of course is not correct or even hex. CBus Checksum Error: Expected 'AN', received 'AD'
3) C-Bus State information is stored and read back from joins but you need / best to create all three joins in your GUI for each C-Bus group you use (analog, digital and serial). Not having them causes testing against undefined values in the code.
The C-Bus Level MMI messages are only being recognised if originated from and received through a fixed PCI/CNI unit address of 254.
I'm waiting to hear from Ben but I have changed the plugin code slightly and quite a bit of the Javascript to avoid these issues and I will fork it shortly and post an updated version. Let me know if that works for you.
Kevin
Reply to this email directly or view it on GitHub: https://github.com/CommandFusion/C-Bus-guiDesigner-Plugin/issues/1#issuecomment-1641205
Hi Hamed,
1) You need to change your manual commands to include a checksum, or when you are sending commands outside of iViewer turn off the checksum mode either totally by editing the defaults or by first sending the approriate command string to the interface first. The details are in the Serial Interface User Guide downloadable from the public release of the C-Bus documentation on the Clipsal website (after agreeing to the conditions).
The checksum is a sensible inclusion to ensure messages are not damaged in some way during transmission. This can sometimes happen on receipt from the interface where long messages get truncated or concatenated within the TCP handling.
3) You include all the joins by creating GUI elements that hold them - even if they are not displayed or used. So create say a slider with an analog join and a button with a digital and serial join . My later code will not require this as the C-Bus state values are held elsewhere.
The updated plugin will be posted as a fork here on github.
K
Hi Kevin,
Thanks for your prompt reply.
So do you think I should wait for your updated plugin? Will the updated version fix my issue with the checksum?
How long before the new update is available?
Regards,
Hamed
-----Original Message----- From: xAPPO [mailto:reply@reply.github.com] Sent: Tuesday, July 26, 2011 4:20 PM To: hpeyrovi@eim.ae Subject: Re: [C-Bus-guiDesigner-Plugin] C-Bus plugin Checksum error (#1)
Hi Hamed,
1) You need to change your manual commands to include a checksum, or when you are sending commands outside of iViewer turn off the checksum mode either totally by editing the defaults or by first sending the approriate command string to the interface first. The details are in the Serial Interface User Guide downloadable from the public release of the C-Bus documentation on the Clipsal website (after agreeing to the conditions).
The checksum is a sensible inclusion to ensure messages are not damaged in some way during transmission. This can sometimes happen on receipt from the interface where long messages get truncated or concatenated within the TCP handling.
3) You include all the joins by creating GUI elements that hold them - even if they are not displayed or used. So create say a slider with an analog join and a button with a digital and serial join . My later code will not require this as the C-Bus state values are held elsewhere.
The updated plugin will be posted as a fork here on github.
K
Reply to this email directly or view it on GitHub: https://github.com/CommandFusion/C-Bus-guiDesigner-Plugin/issues/1#issuecomment-1653480
The forked version will still use checksums but I hope this will be transparent for you.
I hope to have something in the next few days. I need to familiarise myself with github , so far I have forked the repo but I will post here when there is something useful commited there for you to try.
Kevin
Hi Kevin,
Any update on the Cubs Plugin?
I still don’t have a working solution. I would appreciate if you could help.
Regards,
Hamed
-----Original Message----- From: xAPPO [mailto:reply@reply.github.com] Sent: Friday, July 29, 2011 8:11 PM To: hpeyrovi@eim.ae Subject: Re: [C-Bus-guiDesigner-Plugin] C-Bus plugin Checksum error (#1)
The forked version will still use checksums but I hope this will be transparent for you.
I hope to have something in the next few days. I need to familiarise myself with github , so far I have forked the repo but I will post here when there is something useful commited there for you to try.
Kevin
Reply to this email directly or view it on GitHub: https://github.com/CommandFusion/C-Bus-guiDesigner-Plugin/issues/1#issuecomment-1682239
I still haven't had any contact from the original author :-(
My updated version will make use of a new iViewer feature for 'tags' . This is needed to tidily support all the groups across mutiple C-Bus applications and networks. Originally it was estimated around July but a recent post to the CF group has indicated that the tag feature is being delayed because of Android development. As soon as that feature does get included in iViewer then I'll get something posted in a fork here. ITMT I'll contact you directly.
Kevin
Hi guys,
Sorry for my complete lack of attention to this project. I wasn't aware of this thread until I chanced upon it today - Kevin I emailed you mid December (I know, months after I was contacted...)
How are you getting on with it?
I didn't actually have a test system directly (hence the involvement of dogs_au AKA Scott from Australia - thanks Scott!), but do now (recently acquired a serial iTach).
I'd be happy to help as best I can to get this going. I'm NOT a certified C-Bus guy, just an enthusiast that delved head on into the serial protocol to try and make CF do some cool stuff.
I'll do my best to keep up to date with this going forward.
Cheers, Ben.
Hi Ben,
I still have problems with my c-bus PCI giving me a checksum error when I enable checksum and use the commands from the c-bus plug-in. Could you please help me solve this issue? I have tried all possible settings on PCI through the diagnostics program but I keep getting the same error. When I don’t have the checksum enabled on the pci and I simply create a command with the serial string to turn on/off a lighting group it works but off course I don’t have any feedback. Could you please let me what I should do for this to work?
Also do you have any plans to integrate other c-bus applications into the plug-in? I would like to be able to set temperature set points on my c-bus thermostats and be able to view the current temperature readings of the thermostat on iviewer. Do you think it is possible to implement this?
I look forward to your early reply.
-----Original Message----- From: mrgadget [mailto:reply@reply.github.com] Sent: Wednesday, January 25, 2012 11:36 AM To: hpeyrovi Subject: Re: [C-Bus-guiDesigner-Plugin] C-Bus plugin Checksum error (#1)
Hi guys,
Sorry for my complete lack of attention to this project. I wasn't aware of this thread until I chanced upon it today - Kevin I emailed you mid December (I know, months after I was contacted...)
How are you getting on with it?
I didn't actually have a test system directly (hence the involvement of dogs_au AKA Scott from Australia - thanks Scott!), but do now (recently acquired a serial iTach).
I'd be happy to help as best I can to get this going. I'm NOT a certified C-Bus guy, just an enthusiast that delved head on into the serial protocol to try and make CF do some cool stuff.
I'll do my best to keep up to date with this going forward.
Cheers, Ben.
Reply to this email directly or view it on GitHub: https://github.com/CommandFusion/C-Bus-guiDesigner-Plugin/issues/1#issuecomment-3647195
Hi,
I'd like to get this working for you as I know Scott in AU is using it extensively with no problems (that I'm aware of). I will have some time in about 2 weeks to have a look at this again.
Can you please email me (cf at nuttall.co.nz) network details and I'll set up a test network in a simlar way.
At this stage I've not got any plans to support other applications, however, there's nothing particularly complex in this addin that a reasonably proficient .NET coder (with some CBus serial protocol knowledge) couldn't get their teeth into - and it's open source! So this doesn't mean it won't happen, just I won't be doing it, at least not for a while.
Cheers, Ben
Hi,
I have the C-bus plugin installed and have a C-Bus system with a PCI module. Everything works fine as far as Guidesigner ( plugin comes up, XML file is loaded and the command are created) I have also made the required setting on the PCI modual such as: Smart Mode , Checksum , EXSTAT . When i upload the GUI file and i press the button that has a c-bus lighting command on the PCI i get a " checksum error " and the command is not executed. But i do receive feedback on iveiwer if i turn on the same group address through the wall switch. but i can not turn on/off the light.
I have tried creating a command manually without using the plugin for group address 15 and the command that works fine to turn on this group would be \053800790F\x0D which would give the same error if i have checksum enabled on the PCI so i would have to disable checksum for this command to work.
I have looked into your cbus.js and i have noticed that the command that you have programed into the javascript has \05 at the begining of the command but it should have \05 and i tried the \05 with my manual command and it would not work.
I think that two things should be changed in the javascript for this plugin to work for me:
what do you think?
Please email me at hpeyrovi@eim.ae