Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > VB Script

Vista Tutorial - Communicating with RS232 (USB) Ports

Reply
 
Old 06-30-2009   #1 (permalink)
p byers
Guest


 
 

Communicating with RS232 (USB) Ports

I googled for an answer - found several expensive dlls/exes to download
!!

Found a Script that looks like it could work.

Dont have MSCommLib
Anyone got Instructions/Advice about obtaining/installing/regisrtering
it ??
(Lots of almost incomprehensible warnings about installation problems
given in Google !!)

Some help would be most helpful - please - thank you.

Pete(Northolt UK)


My System SpecsSystem Spec
Old 06-30-2009   #2 (permalink)
mr_unreliable
Guest


 
 

Re: Communicating with RS232 (USB) Ports

p byers wrote:
Quote:

> Dont have MSCommLib
> Anyone got Instructions/Advice about obtaining/installing/regisrtering
> it ??
Hi Pete,

If you google around, you will find that MSCommLib is a class
contained in MSComm32.ocx.

And MSComm32.ocx was a component shipped with VB6. Note that
VB.Net does not support serial communications, probably because
m$ thinks that serial comm is obsolete.

If you don't have vb6 installed, you best bet would be to find
a buddy with vb6 installed and "borrow" a copy. (Note that m$
may frown on this unless you sign an "End User License Agreement",
an EULA for short).

If you google some more, you will find some sites offering you
a copy of MSComm32.ocx, for example:

http://www.tech-archive.net/Archive/.../msg01077.html

but, I couldn't find an "offical microsoft" download for it.

cheers, jw
____________________________________________________________

You got questions? WE GOT ANSWERS!!! ..(but, no guarantee
the answers will be applicable to the questions)
My System SpecsSystem Spec
Old 06-30-2009   #3 (permalink)
mr_unreliable
Guest


 
 

oops

mr_unreliable wrote:
Quote:

> Note that VB.Net does not support serial communications,
> probably because m$ thinks that serial comm is obsolete.
>
oops, blush,stammer, WRONG!!!

vb.net supports serial communications as the "serialport"
subclass of the "System.IO.Ports" class.

http://msdn.microsoft.com/en-us/libr...erialport.aspx

So, if you don't happen to have vb6 around, you can write
an "interop" assembly for accessing your serial port in
vb.net. Then use "regasm" to register your assembly as
a COM component, and then use it from script.

mea culpa, mea culpa, mea culpa, jw
My System SpecsSystem Spec
Old 2 Weeks Ago   #4 (permalink)
Si Ballenger
Guest


 
 

Re: Communicating with RS232 (USB) Ports

On Tue, 30 Jun 2009 06:31:31 +0100, p byers <pb@newsgroup-ltd.co.uk>
wrote:
Quote:

>I googled for an answer - found several expensive dlls/exes to download
>!!
>
>Found a Script that looks like it could work.
>
>Dont have MSCommLib
>Anyone got Instructions/Advice about obtaining/installing/regisrtering
>it ??
>(Lots of almost incomprehensible warnings about installation problems
>given in Google !!)
>
>Some help would be most helpful - please - thank you.
>
>Pete(Northolt UK)
>
You can write to the comport like below, but no input from the
port.

Set fs=CreateObject("Scripting.FileSystemObject")
Set a = fs.CreateTextFile("COM1:",True)
a.write chr(255)
a.write chr(1)
a.write chr(127)
a.Close

My System SpecsSystem Spec
Reply

Thread Tools


Similar Threads
Thread Forum
usb to rs232 converter Vista hardware & devices
usb to rs232 cable install problems General Discussion
RS232 COM-Port handler VB Script
RS232 and Media Center Media Center
Serial RS232 Adapter for Windows Vista Vista hardware & devices


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46