X10 Community Forum

💬General Category => General Discussion => Topic started by: pconroy on May 27, 2010, 12:03:46 AM

Title: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: pconroy on May 27, 2010, 12:03:46 AM
the saga continues...

Previously, I tried a very inexpensive, eBay bought, Hong Kong shipped, $1.99 USB to Serial adapter.  While it worked with my old Garmin GPS under Windows and Linux - it did not work with my CM11A or my Lacrosse Weather Station.

With another $5 burning a hole in my pocket, I tried one that said it had "Prolific PL-2303HX controller, excellent compatibility" chip inside.

See http://cgi.ebay.com/USB-RS-232-Serial-DB9-Adapter-MAC-Linux-Win-7-/270578333268?cmd=ViewItem&pt=AU_Laptop_Accessories&hash=item3effb9b654#ht_3174wt_859

The good news is that this one works under XP - the CM11A and the weather station seem to be working fine, although they've only been running for a couple of hours.

<Edited to say - with everyone's help - its working under Linux too: Ubuntu 10.04 and 9.10>


One more thing - by default the adapter stuck itself at COM5 (/dev/ttyS4).  That's not a problem for me, but you might want to make sure your software either supports COM5, or you play around in Device Manager and see if you can move it down to COM4, perhaps!

Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: Msradell on May 29, 2010, 04:46:54 PM
I've been using one of those for quite awhile to communicate with my Ocelot, it's been working very well.  I'm using it on a new laptop running Windows 7 x64.
Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: Charles Sullivan on May 30, 2010, 03:52:58 AM

pconroy:
A lot of these el-cheapo adapters don't support the serial status lines at all, and Linux support for some Prolific chipset versions is problematic.

If you have Heyu installed, see the description of 'heyu port_line_test' in the "EXPERIMENTAL STUFF" section of man page heyu(1).

Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: pconroy on May 30, 2010, 02:20:12 PM
Chas-  yeah...  I was hopeful seeing this one work beautifully under XP.
So it's for sure the Linux driver, not the device.

I'm OK running XP on the box.
I *wish* it was Linux, but it'll do for now.
Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: Charles Sullivan on May 30, 2010, 04:57:49 PM
Chas-  yeah...  I was hopeful seeing this one work beautifully under XP.
So it's for sure the Linux driver, not the device.

I'm OK running XP on the box.
I *wish* it was Linux, but it'll do for now.

Did you run the test?   Until you do you can't be sure.  The CM11A can be operated without serial status lines but the CM17A requires them.
Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: pconroy on May 30, 2010, 11:15:26 PM
Ok - I will when I get a chance.

Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: Brandt on May 31, 2010, 05:15:17 PM
I use the $15 FTDI one from Parallax

Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: pconroy on June 01, 2010, 12:08:42 PM
Ok - I will when I get a chance.



Charles - interesting. port_line_test shows CD, DSR and CTS toggling nicely.
RI (pin 9) doesn't - stays clear.


I'll have to look at my code that opens the port.
Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: pconroy on June 01, 2010, 12:39:00 PM
I use the $15 FTDI one from Parallax



Brandt - this one?

http://www.parallax.com/Store/Accessories/CablesConverters/tabid/166/CategoryID/40/List/0/SortField/0/Level/a/ProductID/378/Default.aspx

thanks - patrick
Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: pconroy on June 01, 2010, 02:35:17 PM
Chas-  yeah...  I was hopeful seeing this one work beautifully under XP.
So it's for sure the Linux driver, not the device.

I'm OK running XP on the box.
I *wish* it was Linux, but it'll do for now.

Did you run the test?   Until you do you can't be sure.  The CM11A can be operated without serial status lines but the CM17A requires them.


Where's the embarrassed icon???

Charles - heyu seems to be controlling the CM11A fine thru the adapter.
It's clearly my code................................

 :'(
Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: Brandt on June 01, 2010, 02:47:02 PM
I use the $15 FTDI one from Parallax



Brandt - this one?

http://www.parallax.com/Store/Accessories/CablesConverters/tabid/166/CategoryID/40/List/0/SortField/0/Level/a/ProductID/378/Default.aspx

thanks - patrick


Yep, that's the one I use with my cm11a
Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: Charles Sullivan on June 01, 2010, 03:03:21 PM
Chas-  yeah...  I was hopeful seeing this one work beautifully under XP.
So it's for sure the Linux driver, not the device.

I'm OK running XP on the box.
I *wish* it was Linux, but it'll do for now.

Did you run the test?   Until you do you can't be sure.  The CM11A can be operated without serial status lines but the CM17A requires them.


Where's the embarrassed icon???

Charles - heyu seems to be controlling the CM11A fine thru the adapter.
It's clearly my code................................

 :'(


Patrick,
Try running 'heyu fon Hu' to send an RF signal with a CM17A Firecracker.  (It doesn't matter if you don't actually have one attached.)  If the adapter doesn't support the serial status lines required for the CM17A, Heyu will display an error message to that effect.
Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: pconroy on June 01, 2010, 09:42:07 PM
Pass the eggs! I need some more on my face!!!
And I'll take some humble pie as well!     :'


It;s working - under Ubuntu 10.04 and 9.10. 

Your port_test forced me to go back and retrace my steps.  I'm still not sure what I did wrong - I suspect I screwed up the permissions on /dev/ttyUSB0 -- but whatever it was it's gone.

So this little $5 USB/Serial adapter is working for me, on XP and Ubuntu Linux -- and it's receiving commands from the CM11A and my weather station.  Both HeyU and my software are working with it.



My thanks to you guys for the help!!!
Now I can unplug XP and run Linux on the lil' laptop!    ;D
Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: Charles Sullivan on June 01, 2010, 10:26:40 PM

Patrick,
I'd still appreciate knowing the results of either the port_line_test or even running just 'heyu fon Hu' with your $5 adapter. ("Hu" being any Housecode|unit address, e.g., A1.)

The only way I can provide knowledgeable advice to others is by having feedback from users like you.

Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: Brandt on June 02, 2010, 01:46:29 AM

Patrick,
I'd still appreciate knowing the results of either the port_line_test or even running just 'heyu fon Hu' with your $5 adapter. ("Hu" being any Housecode|unit address, e.g., A1.)

The only way I can provide knowledgeable advice to others is by having feedback from users like you.



On that note, I have a cm17a inline with my $15 ftdi parallax adapter as well as the cm11a and the fon and foff commands work perfect. I suppose you already knew that seeing how it is FTDI based...
Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: pconroy on June 02, 2010, 12:15:12 PM

Patrick,
I'd still appreciate knowing the results of either the port_line_test or even running just 'heyu fon Hu' with your $5 adapter. ("Hu" being any Housecode|unit address, e.g., A1.)

The only way I can provide knowledgeable advice to others is by having feedback from users like you.



Charles,
I'll do it.  I've got a few minutes free @ work - I'll remote login at post the results.

Like I mentioned earlier - your port_line_test showed all pins toggling state nicely -- except for Ring indicator #9.

Stand by for the other test.
Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: pconroy on June 02, 2010, 12:27:03 PM
Ok - I will when I get a chance.



Charles - interesting. port_line_test shows CD, DSR and CTS toggling nicely.
RI (pin 9) doesn't - stays clear.


I'll have to look at my code that opens the port.


Charles,

"
$heyu fon A1
$"


No error message - all indications are that it worked.
Does that help?
Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: Charles Sullivan on June 02, 2010, 12:50:25 PM

Patrick,
I'd still appreciate knowing the results of either the port_line_test or even running just 'heyu fon Hu' with your $5 adapter. ("Hu" being any Housecode|unit address, e.g., A1.)

The only way I can provide knowledgeable advice to others is by having feedback from users like you.



Charles,
I'll do it.  I've got a few minutes free @ work - I'll remote login at post the results.

Like I mentioned earlier - your port_line_test showed all pins toggling state nicely -- except for Ring indicator #9.

Stand by for the other test.


Patrick,
The port_line_test results are all I needed.  Thanks.
Your results are what I've seen with an adapter I have with an older Prolific chipset.

Failure of the "fon" test would be expected from an adapter which doesn't support any status lines, which is not the case here.

I'm surprised you haven't reported getting the message "RI line may be stuck" when sending X10 commands with that adapter (unless you've already found the CHECK_RI_LINE config directive to perform/bypass the RI check).


 
Title: Re: Ongoing pursuit of a cheap USB/Serial adapter...
Post by: pconroy on June 02, 2010, 04:29:34 PM

Patrick,
I'd still appreciate knowing the results of either the port_line_test or even running just 'heyu fon Hu' with your $5 adapter. ("Hu" being any Housecode|unit address, e.g., A1.)

The only way I can provide knowledgeable advice to others is by having feedback from users like you.



Charles,
I'll do it.  I've got a few minutes free @ work - I'll remote login at post the results.

Like I mentioned earlier - your port_line_test showed all pins toggling state nicely -- except for Ring indicator #9.

Stand by for the other test.


Patrick,
The port_line_test results are all I needed.  Thanks.
Your results are what I've seen with an adapter I have with an older Prolific chipset.

Failure of the "fon" test would be expected from an adapter which doesn't support any status lines, which is not the case here.

I'm surprised you haven't reported getting the message "RI line may be stuck" when sending X10 commands with that adapter (unless you've already found the CHECK_RI_LINE config directive to perform/bypass the RI check).


 

Charles - I'm not running HeyU fulltime yet.
Still running my own software.

If I can get HeyU to send me the TCP packets I need - which I'm sure I'll be able to do - then I'll switch over.



Funny - that super cheap $1.99 adapter showed up as a Prolific 2303 in Linux and I couldn't make that work.
Now that I have proof of my own user error, I need to recheck it!