Serial port:

I have had no luck loading any of the devices created by xml. Has anyone had any luck? I have tried the following.

D_GC100.xml
D_TestSerial.xml

After loading each of the files vera’s website refuses to load user data and I am unable to get back into the website. After loading the GC100 device, I had to do a factory reset to get back into vera’s website. After loading the testserial device, I had to flash the firmware to get back into vera’s website. If there is an easier way to get past this problem someone needs to let me know.

I am basically looking for a working device that I can modify to suite my needs.

Exactly!

MCV mentioned a new release in a few days (which was few days ago :)) - I hope it’ll be better.
Otherwise we’re stuck here until MCV guys show up on the forum.

The detection of serial ports is handled by serproxy (I’ll put a link to the source code here: http://wiki.micasaverde.com/index.php/Windows_Serial_Proxy). serproxy itself is a upnp device of type “serialportroot”. This is not a serial port–it’s just the serproxy which manages all the ports. That’s why setting baud raud for serproxy has no effect. serproxy will create as embedded/child devices each of the serial ports, which have the type “SerialPort”. It’s those embedded ports that you configure with the ‘serial port configuration’. The reason for this embedded structure is so you can have remote devices running serproxy that have their own ports, and the Luup engine can keep track of them. In other words, you may have 3 serial ports on the main Vera, and configure a cheap access point to run another 2 serial ports. Vera will show 5 ports, grouped into 2 compound devices, the first has the 3 ports, the 2nd has the other 2. They are all TCP/IP, so your Luup plugin doesn’t know the difference. The idea is that you can scatter cheap ethernet->rs232 devices around the house where they’re needed.

serproxy has a hardcoded list of recognized usbserial devices. It can’t just display all of them, because there are devices that are not RS232 ports that show up as usbserial devices, such as the Z-Wave dongle, Insteon, etc. I just updated serproxy so that in addition to the hardcoded list of known RS232 devices, it will also also read in the vendor/product ID’s from /etc/cmh/serproxy.ports. The format needs to be the vendor+model you see in: /proc/tty/driver/usb-serial. So I do this:

root@HomeControl:~# cat /proc/tty/driver/usb-serial
usbserinfo:1.0 driver:v1.4
0: module:cp210x name:"CP210X" vendor:10c4 product:ea60 num_ports:1 port:1 path:usb-00:03.1-1.1
1: module:ftdi_sio name:"FTDI FT232BM Compatible" vendor:0403 product:6001 num_ports:1 port:1 path:usb-00:03.1-1.2
root@HomeControl:~# echo "vendor:10c4 product:ea60" >> /etc/cmh/serproxy.ports

‘cat’ just means display the usb-serial. I then copy/paste the vendor+product into the echo line and the >> means append that data to /etc/cmh/serproxy.ports

When serproxy starts, it logs into /var/log/cmh/serproxy.log all the ports that it finds. serproxy starts automatically every time the Luup engine starts, which happens at bootup, and each time you hit ‘save’. Alternatively, instead of hitting ‘save’ in the web ui, you can just do ‘killall serproxy’ in a console to make serproxy restart. When it starts, for every serial device in the system you will see either:

==Found Serial Port …
or
==Skipping unknown Serial Port:

If the # of serial ports found doesn’t match what’s in the Luup engine’s database, it will synchronize and restart the engine. Once everything matches, it will log:

===Setting up serproxy

for every port that it’s starting up.

Thanks! So when the new serproxy will be available?

Said that, if non-devs try to get a plugin from the future repository, and find out that to make their trusty serial adapter work they have to edit system file… with vi… they sure will be pissed off.
Since this kind of hardware is somewhat diverse, it would be a good idea to make this list updateable via Vera UI, and/or make Vera to refresh it from findvera.com on boot, assuming you’ll be adding new devices based on trouble tickets.

Mizar, the Luup plugins shouldn’t be able to crash the engine. If they do, I want to (a) fix the engine, and (b) see what’s wrong with your plugins. I can’t reproduce the problem you’re having. So, can you ensure you’re running the latest release (765 as of today), and if it happens again, and you have a minute to let me know about it and don’t mind opening the tech support back door so I can look at your Vera, call our support number and ask for Aaron, or email me at aaron at mi…

It’s posted now. Re: non-devs, I think they’ll never get past insmod and cat and stuff like that… My goal is to have a link of ‘known good’ usb->rs232 adapters that the users can buy from which are automatically recognized and won’t give them any trouble.

@MCV, do you mind creating a Wiki page for Serial adapters, similar to how you’ve got them for ZWave devices.

You mention it here, and there’s the “sticky” Serial thread, but it’s hard to tell from the latter which ones have “made it in” to the default config, ones that people can then go on and try knowing it will at least auto-recognize it.

Once you formally add in the [tt]serproxy.ports[/tt] entry, or the hard-coded equiv in [tt]serproxy[/tt] itself, then it can be listed in the table (with whatever caveats are needed about full certification), along with the Vera version that it’s recognized in.

The one you reference here is [tt]UC232R-10[/tt] from http://www.futureelectronics.com, which is presumably the one that folks need for the Insteon/X-10 interface, but that’s not been made explicit in that separate post. Perhaps we can start the Wiki page with that.

I wish adapters behaved according to specification…
PL-2303 is officially supported and yet half of adapters based on it don’t work with Vera (while work perfectly with windows)

@nanckekr, you’ve been away for a while, but looks like you’re back now. Did you ever get success with your 8-port Serial adapter?

as in, working “end-to-end” recognized in Vera and showing as 8x Serial Port devices?

@MCV I’ve gone ahead and created a stub Wiki page to represent the “collective knowledge” of Serial/USB Interface’d devices.

It’s listed here:

http://wiki.micasaverde.com/index.php/Serial_Supported_Hardware

Feel free to add details to it as needed. I encourage others to add their experience to it as well so people will know what works, doesn’t work, (etc)

@325xi, LibraSun: Can you each add the devices you’ve been trialing?

Sorry to bring up an old topic… anyone have any idea if in UI3 and UI4, pl2303 is supported by serproxy out of the box? It seems pretty common, so I’m wondering if you still have ssh, and echo a product/vendor into a serproxy.ports file.

If you have the choice of buying one and its not something thats embedded in another device, then this one works out of the box:

http://parts.digikey.com/1/parts/1501993-cable-economy-usb-rs232-srl-conv-uc232r-10-chipi.html

Although I must add that after installing a second one along with a USB-UIRT it thinks its an Insteon device.

Stuck with an embedded serial device. It seems that UI4 beta still requires that you create the serproxy.ports file for the pl2303.

Thanks Strangely. Anyone have any experience using serproxy to connect to a serial device on another computer? How do I set up the device on the other computer? I imagine that I’d need to open the comm port to the network - just don’t know how. The info out there on serproxy seems limited.

@woodsby, both @strangely and I are connecting to Serial port devices over TCP using WizNet 110SR devices (and the IPSerial Plugin on code.mios.com).

These avoid the need for a PC in the middle of the equation.

If you need to have a PC, you end up running something like [tt]ser2net[/tt], [tt]serproxy[/tt] (the real one) or one of the many other IP <-> Serial port software converters. You’ll see a sample list at:

http://www.arduino.cc/playground/Interfacing/SerialNet

but there are a lot of others, depending upon your Platform.

In turn, each of these software solutions typically has a config file that specifies the IP-Port to use, along with the Serial/COM port Baud rate, Parity, Stop bits and so-on)

All Vera ends up going is “connecting” to a designated IP/Port combo and sending/receiving the Serial data across it.

Some other background that might help, if you happen to be poking around in this area.

Vera used to use the “real” [tt]serproxy[/tt] script, in the early days of Luup, but it was really buggy with small byte-count transmissions. They’ve since replaced the “innards” of this program with [tt]ser2net[/tt] but have kept the naming for the “wrapper” program, and it’s config files, that Vera uses to launch [tt]ser2net[/tt] (one ser2net process per each local/USB serial port)

Vera’s serproxy runs through the local USB ports, compares them against a known-list of USB-Serial provider/product codes (incl those in [tt]serproxy.ports[/tt]), and then attempts to lookup various Baud/Parity/Stop bit data from Vera (using a URL) before moving on to launch the [tt]ser2net[/tt] command with the right data.

So whilst the serproxy wrapper is locking ser2net to the local machine’s USB ports, you can deploy a version of it (or any other IP-Serial port software) to a remote machine… but you have to configure the Port/Baud/Parity etc.

Once that’s in place, you only have to be able to tell Vera that there’s a Serial Port running on a Remote IP Address, and it’ll take care of the rest of the connectivity (which is what IPSerial Plugin does, since there’s no way to manually register this stuff otherwise)

Running [tt]strings[/tt] over the executable, these are the Vendor/Product combos that seem to be built into [tt]serproxy[/tt]:

[tt] vendor:0403 product:6001
vendor:0403 product:6010
vendor:0856 product:ac33
[/tt]
I’ve added Bug# 1194:
[url=http://bugs.micasaverde.com/view.php?id=1194]http://bugs.micasaverde.com/view.php?id=1194[/url]

to get stuff formally added for pl2303 USB-Serial devices with (vendor:067b product:2303)

If you have others, I recommend we start filing Bugs against them, since the sticky forum posting hasn’t resulted in any additions to the listing above except the B&B Electronics one)

Thanks guessed. What I’m trying to do is plug USB-Serial RFID receivers to my computers around the house and connect them to vera. This should be a good start.

How about using an Asus 520 Router (it has USB) with a custom firmware? I think @guessed had good success running one of these with ser2net.

http://www.newegg.com/Product/Product.aspx?Item=N82E16833320023

Actually, I started looking at the wiznet device he mentioned, and for $25, that seems like the right approach - they offer the RFID receiver in a standard serial version, and it’s a few dollars cheaper.

Yup, and depending upon your cabling needs, there are multi-port WIZnets also (2 Port == WIZ125SR) as well as more expensive encased WiFi (1 Port == WIZ6000) althogh so far both @strangely and I have stuck with the single port versions.

Don’t forget the power cable :wink:

I thought he wanted to use the USB versions of the receivers though?

The wiznets are great though and the ironic thing is that I actually have mine powered by the aforementioned Asus Router which is now relegated to network switch duties for my phone, TV and wiznet.