-
26
Mar -
serial port interfacing using visual basic
- With 0 comments
serial port COM1 is a serial communication based physical interface, serial communication means that information transfers in or out one bit at a time, it has a 25-pin, look at the figure below to see it’s image
Serial port
To access this port usng visual basic you have to use ActiveX named MScomm
This ActiveX comes with visual bsic from microsoft, it is used to make a serial connection with other devices such as phone network or your custom circuit.
to download this ActiveX you can follow this link:
http://www.yes-tele.com/mscomm.ZIP from yes-tele.com
This ActiveX can be choosen and drag drop it to your form invisual basic.
At the first click on this ActiveX and go to OnComm()
event for it, this event run when there is a data recieved, you can directly receive data as the followig:
suppose we have a Mscomm instance called comm1 and a Text box called Text1
Private Sub comm1_OnComm()
if(Comm1.CommEvent=’comEvReceive’) Then
Text1.text=Comm1.Input ‘ get info from seral port Harper buy
End if
End Sub
That is to receive data, to send data using command button called Command1 you will do this :
Private Sub Command1_Click()
Comm1.Output = “1234″ ‘this is to out data
End Sub
You can download an advanced example about serial communcation from here: http://www.yes-tele.com/download/vb60.zip
*Note: All brand and product names are or may be trademarks of, and are used to identify products or services of, their respective owners.
**All download links are from its publishers sits.
- MSComm activex free download
- calculator using Parallel port interfacing with keypad
- Atmel AT89XXX AT89C2051 AT89s52 AT89c52 Programmer using Serial Port
- 3d text objects source code using visual basic
- serial communications roger stevens book
- Parallel port interfacing
- Telephone Directory source code with visual basic
- 3d buttons using visual basic
- download Parallel Port Viewer controller
- Dictionary using visual basic





