Author Topic: PLCBus devices setup  (Read 3391 times)

pezho

  • Newbie
  • *
  • Posts: 12
    • View Profile
PLCBus devices setup
« on: January 04, 2011, 01:21:13 pm »
Hi Guys!
I use the PLCBus devices were purchased from Shanghai Super Smart (www.s10.cn)
I have computer interface PLCBUS-T 1141 usb (http://www.plcbus.com.cn/Html/news/1440.html), Transceiver Module PLCBUS-T 4023G (http://www.plcbus.com.cn/Html/news/1462.html) and various lighting modules which I can operate via remote PLC-RF 4073E (http://www.plcbus.com.cn/Html/news/1477.html) and in Win XP, but never in LinuxMCE via Ruby or New Driver.

PLease kindly advise me that how I should setting up plcbus devices in LMCE.

bongowongo

  • wants to work for LinuxMCE
  • **
  • Posts: 826
    • View Profile
Re: PLCBus devices setup
« Reply #1 on: January 04, 2011, 01:35:36 pm »
I just missed you in IRC. Sorry.
Can you add lights in webadmin?

Gangsingen

  • Veteran
  • ***
  • Posts: 54
    • View Profile
Re: PLCBus devices setup
« Reply #2 on: January 04, 2011, 08:00:22 pm »
Hello guys!!

A few days ago I did a clean internet install of LMCE 810. I also did the apt-get update&upgrade to get the most recent updates to the software. Once I did that I plugged in my PLCBUS 1141 USB interface to see if the plug&play scripts worked.

All that happened was that LMCE found a "Generic USB to RS232 Dongle". I started (once again) to read the forums and found a solution for that problem here:http://forum.linuxmce.org/index.php?topic=11157.msg77351#msg77351.

Once I did that LMCE stopped recognizing the 1141 as a Generic USB to RS232 Dongle and started running some plug&play scripts when I plugged the 1141 in. Only problem was that the PLCBUS pnp script wasnt in the /usr/pluto/pnp directory.

Yesterday I ran apt-get update&upgrade again and the system was updated. Now I got the pnp scripts in place, yeah!!!!

Now when I plug the 1141 back in, the system doesn´t seem to react at all....no pnp scripts are launched or anything.....grrrrr.

I added the 1141 manually. In webadmin I went to Advanced>Configuration>Devices  and "Add a top level device". I found the PLCBUS template#1920 and added it to the system. I set the "COM Port on PC" to /dev/ttyUSB0 (the 1141 is the only USB device connected to the core).

I also added a light to the system with adress A1 and rebooted the system.....and it doesn´t work.

When I do a quick reload of the router I get this in the 1141 log:

Code: [Select]
========== NEW LOG SECTION ==========
1 01/04/11 19:55:26 47 (spawning-device) Starting... 1
1 01/04/11 19:55:27 47 (spawning-device) Found /usr/pluto/bin/PLCBUS
05 01/04/11 19:55:28.079 Connect() failed, Error Code 111 (Connection refused)) <0xb71e2ad0>
05 01/04/11 19:55:29.079 Connect() failed, Error Code 111 (Connection refused)) <0xb71e2ad0>
05 01/04/11 19:55:30.079 Connect() failed, Error Code 111 (Connection refused)) <0xb71e2ad0>
05 01/04/11 19:55:31.079 Connect() failed, Error Code 111 (Connection refused)) <0xb71e2ad0>
05 01/04/11 19:55:32.079 Connect() failed, Error Code 111 (Connection refused)) <0xb71e2ad0>
01 01/04/11 19:55:46.488 Open port: /dev/ttyUSB0 <0xb71e2ad0>
05 01/04/11 19:55:47.182 Creating child 48 <0xb71e2ad0>
05 01/04/11 19:55:47.182 Note: Device manager has attached a device of type 37 that this has no custom event handler for.  It will not fire events. <0xb71e2ad0>
05 01/04/11 19:55:47.182 Note: Device manager has attached a device of type 37 that this has no custom handler for.  This is normal for IR. <0xb71e2ad0>

When I then try to send a command to light A1 I get this in the log:
Code: [Select]
t 0 <0xb61dfb90>
01 01/04/11 19:57:27.148 COMMAND_Generic_On_CONST received for child A1 <0xb61dfb90>
01 01/04/11 19:57:27.148 Adding command to queue... <0xb61dfb90>
01 01/04/11 19:57:27.547 Send Queue Size: 1 <0xb71e1b90>
01 01/04/11 19:57:28.047 Send Queue Size: 1 <0xb71e1b90>
01 01/04/11 19:57:28.547 Send Queue Size: 1 <0xb71e1b90>
01 01/04/11 19:57:29.047 Send Queue Size: 1 <0xb71e1b90>
01 01/04/11 19:57:29.047 Sendcount exceeded, this was the last sent attempt, removing job... <0xb71e1b90>

Can you guys help me to track down the problem?
« Last Edit: January 04, 2011, 08:02:07 pm by Gangsingen »

bongowongo

  • wants to work for LinuxMCE
  • **
  • Posts: 826
    • View Profile
Re: PLCBus devices setup
« Reply #3 on: January 04, 2011, 09:12:42 pm »
Gangsingen and Russian dude
I will update the wiki as we go along and get a workalble situation for everybody.
Delete all your PLCBus devices.
Reboot
Regen all orbiters
Plug in your PLCBus in a different port than you had it. It was good to say no to the usb to serial device, after that the plcbus script will run.
It will be in webadmin, a child of the core (if you plugged it in the core). DO NOT SELECT A PORT. Hari said it is automatic.
Reload router, Regen orbiters, just for the safe side reboot. Script will propable be visible for a short time.
Now add a light. Set it up in webadmin, give it an adress e.g. A1.
Reset the lighning device (blue led flashes repeatedly), and press test commands "on" You will here 1 or 2 buzz. Now you can control the device.
Be aware that in a dimmable device the light really goes slowly on........so give it a minute.......it is a bug hari is going to fix.


Gangsingen

  • Veteran
  • ***
  • Posts: 54
    • View Profile
Re: PLCBus devices setup
« Reply #4 on: January 05, 2011, 11:35:47 am »
Thanks for the advice Bongo!!

I removed all PLCBUS devices, regen orbiters, rebooted, updated the core via apt-get.

When I plug in the 1141 now it starts running scripts, 20_Denonreciever.sh and so forth, but no PLCBUS... The pnp script exists in the /usr/pluto/pnp directory, but isn´t executed.

Does the changes in the zwave template affect this? http://forum.linuxmce.org/index.php?topic=11157.msg77351#msg77351

bongowongo

  • wants to work for LinuxMCE
  • **
  • Posts: 826
    • View Profile
Re: PLCBus devices setup
« Reply #5 on: January 05, 2011, 12:16:11 pm »
Hmm
I do not know, I will ask hari

Gangsingen

  • Veteran
  • ***
  • Posts: 54
    • View Profile
Re: PLCBus devices setup
« Reply #6 on: January 09, 2011, 12:02:22 pm »
Heard anything yet?!

I suspect it has to do with my modified z-wave template.....is there a way to restore one single device template to its original?

Gangsingen

  • Veteran
  • ***
  • Posts: 54
    • View Profile
Re: PLCBus devices setup
« Reply #7 on: January 11, 2011, 10:14:16 am »
Looked closer at my PLCBUS device template. Is the "Plug&Play" section supposed to be empty?! This is what mine looks like!
« Last Edit: January 17, 2011, 09:54:10 am by Gangsingen »

Gangsingen

  • Veteran
  • ***
  • Posts: 54
    • View Profile
Re: PLCBus devices setup
« Reply #8 on: January 17, 2011, 09:56:21 am »
bump, see my post above.

bongowongo

  • wants to work for LinuxMCE
  • **
  • Posts: 826
    • View Profile
Re: PLCBus devices setup
« Reply #9 on: January 17, 2011, 05:07:44 pm »
That is indeed not correct.
Dis you do an apt-get update and apt-get upgrade?

Gangsingen

  • Veteran
  • ***
  • Posts: 54
    • View Profile
Re: PLCBus devices setup
« Reply #10 on: January 17, 2011, 06:50:16 pm »
That is indeed not correct.
Dis you do an apt-get update and apt-get upgrade?

Not since I took the screenshot. I´ll do an update and see if that fixes the problem.

pezho

  • Newbie
  • *
  • Posts: 12
    • View Profile
Re: PLCBus devices setup
« Reply #11 on: January 17, 2011, 11:28:02 pm »
Hi guys!
Somebody has set up plc-bus?
According to Bongowongo HOWTO my PC interface PLCBUS-T 1141 was found as PLCBUS and Transceiver Module PLCBUS-T 4023G (http://www.plcbus.com.cn/Html/news/1462.html) has been switched on automatically, but not created in webadmin. Then, I add new child manually via webadmin with address A1 (an Transceiver Module PLCBUS-T 4023G I can operate by Remote Control PLC-RF 4073E with address A1). After resetting an Transceiver Module PLCBUS-T 4023G I can't to learn it via TEST ON/OFF buttons in webadmin, but new set up of 4023 by 4073E has properly done. May be need more detailed instructions for learning devices? or devices have an errors in lmce?


bongowongo

  • wants to work for LinuxMCE
  • **
  • Posts: 826
    • View Profile
Re: PLCBus devices setup
« Reply #12 on: January 18, 2011, 11:37:10 am »
Pezho
You make a childevice in the webadmin, give it a letter A1. Quick reload router.
Reset the device, and sent on via the webadmin.
I never used RF devices.

pezho

  • Newbie
  • *
  • Posts: 12
    • View Profile
Re: PLCBus devices setup
« Reply #13 on: January 19, 2011, 01:23:42 am »
Bongo

I was mistaken in Transceiver Module PLCBUS-T 4023G assignment.
It is really intended for a signal transmission from the Remote Control (such as PLC-RF 4073E) to any PLC-Bus modules and can work as the switch on/off module also.

Could you please review my Log in attachment for errors. I see the Device died periodically.

hari

  • Administrator
  • LinuxMCE God
  • *****
  • Posts: 2421
    • View Profile
    • ago control
Re: PLCBus devices setup
« Reply #14 on: January 19, 2011, 12:53:30 pm »
you don't have a serial port specified in the device data... go to the web admin and fix it.

br Hari
rock your home - http://www.agocontrol.com home automation