Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - abt port programming
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

abt port programming

 Post Reply Post Reply
Author
persepherone View Drop Down
Newbie
Newbie
Avatar

Joined: 15 December 2004
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote persepherone Quote  Post ReplyReply Direct Link To This Post Topic: abt port programming
    Posted: 25 December 2004 at 6:25am
i am working on a robotic interface project .presently we use outport commands of C to control the robotic vehicle. we call these complied subroutines from VB or from ASP. can anybody tell me if there is a direct way to implement it.i mean is there any command in VB or ASP which can send a desired byte on a desired port........
Back to Top
Mart View Drop Down
Senior Member
Senior Member
Avatar

Joined: 30 November 2002
Status: Offline
Points: 2304
Post Options Post Options   Thanks (0) Thanks(0)   Quote Mart Quote  Post ReplyReply Direct Link To This Post Posted: 25 December 2004 at 9:32am
Not in asp but in .net there are tonnes of examples over the internet of how to send commands via the com port, just do a google
Back to Top
dpyers View Drop Down
Senior Member
Senior Member


Joined: 12 May 2003
Status: Offline
Points: 3937
Post Options Post Options   Thanks (0) Thanks(0)   Quote dpyers Quote  Post ReplyReply Direct Link To This Post Posted: 25 December 2004 at 9:44am
In vb2-6 you can use most of the win api including the com port stuff and bit-level tcp/ip port stuff. I've written listening and sending apps for both.
 
Asp however is a subset of vb and doesn't include the ability to directly reference the win api. You can however, use vb 4+ to create a dll with an interface api that asp can use. Your current C interface will be faster though.
 
As Mart noted though, asp/vb .net is currently the best way to go for port manipulation through a web app.

Lead me not into temptation... I know the short cut, follow me.
Back to Top
persepherone View Drop Down
Newbie
Newbie
Avatar

Joined: 15 December 2004
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote persepherone Quote  Post ReplyReply Direct Link To This Post Posted: 27 December 2004 at 5:51am
thanx dpyers, 
Can U plz tell me the API that cud be useful to me..  BTW my currect C interface is not fast because i use compiled programs of C those i call from inside VB using the "shell" statement. if i cud implement it directly in VB or asp than their wud be no disk access & thus no delay .

also i tried to search on google but cannot strike to a appropritate solution. if any1 can provide me some solution or a link i wud be highly grateful.
Back to Top
Mart View Drop Down
Senior Member
Senior Member
Avatar

Joined: 30 November 2002
Status: Offline
Points: 2304
Post Options Post Options   Thanks (0) Thanks(0)   Quote Mart Quote  Post ReplyReply Direct Link To This Post Posted: 27 December 2004 at 9:05am
launching a process in asp.net is quite easy, if you are using inline code (not compiling the asp.net page) insert

<%@ Import Namespace="System.Diagnostics" %>

after the <%@ Page ... %> line. If you are using code behind put Imports System.Diagnostics in the imports section of the class. Then just use Process.Start("MyApp.exe", "parameter1 parameter2")
Back to Top
dpyers View Drop Down
Senior Member
Senior Member


Joined: 12 May 2003
Status: Offline
Points: 3937
Post Options Post Options   Thanks (0) Thanks(0)   Quote dpyers Quote  Post ReplyReply Direct Link To This Post Posted: 27 December 2004 at 9:38am

.net is the easier way to go. If you're using vb prior to .net though, look for books about the Win32 API for VB. Dan Appleman did a series of them. starting with the Win16 API for win 3.0 and going through to W2K. Carl Franklin also din some useful api books. He used to have a site called Carl and ?????'s Visual Basic ????? which was a very good resource for building components and dll's.

Appleman and Franklin cover the api quite well and have a lot of examples of bulding com port controls.
 
I've got a couple of different books entitled "Visual Basic Internet Programming" thaat cover the details of using the winsock api through vb for various specific internet protocols - e.g. ftp, http, gopher, etc.

Lead me not into temptation... I know the short cut, follow me.
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.