+ Post New Thread
Page 1 of 2 1 2 LastLast
Results 1 to 20 of 32
  1. #1
    Member level 5
    Points: 2,204, Level: 10

    Join Date
    May 2004
    Posts
    80
    Helped
    2 / 2
    Points
    2,204
    Level
    10

    RS 232 Serial Communication

    Hi..i currently working on a final semester project known as Programmable LED Dot Matrix Display System. I am going to use serial communication to interface with my circuitry. My choice is to use RS 232.

    How am i going to communicate with the serial port behind my computer??i prefer to use 9-pin serial port.

    Please help... :(

  2. #2
    Full Member level 3
    Points: 3,130, Level: 13

    Join Date
    Feb 2002
    Posts
    153
    Helped
    9 / 9
    Points
    3,130
    Level
    13

    Re: RS 232 Serial Communication

    The windows API have all the functions you need to control the serial port. It will be helpfull to tell us which kind of programming language you use. Because it exist a lot of components, to access the serial port more easily.
    But the first step will be the windows API!



  3. #3
    Member level 5
    Points: 2,204, Level: 10

    Join Date
    May 2004
    Posts
    80
    Helped
    2 / 2
    Points
    2,204
    Level
    10

    Re: RS 232 Serial Communication

    Window API? How to find that? I am sorry. This is the first time i do the interfacing stuffs.

    I would like to use visual basic 6.0 to communicate with the port. So is there any better programming language to be suggested?



  4. #4
    Full Member level 6
    Points: 6,941, Level: 19
    hugo's Avatar
    Join Date
    Jan 2000
    Location
    canada
    Posts
    323
    Helped
    55 / 55
    Points
    6,941
    Level
    19

    Re: RS 232 Serial Communication

    Hi,

    For serial port interfacing and visual basic look at :

    http://www.lvr.com

    bye



    •   AltAdvertisement

        
       

  5. #5
    Full Member level 3
    Points: 2,235, Level: 10

    Join Date
    Apr 2004
    Posts
    151
    Helped
    7 / 7
    Points
    2,235
    Level
    10

    Re: RS 232 Serial Communication

    I think you can use activeX object: MSCOMM to tranceiver with RS232



  6. #6
    Member level 1
    Points: 1,807, Level: 9
    duncan94022's Avatar
    Join Date
    May 2004
    Posts
    41
    Helped
    0 / 0
    Points
    1,807
    Level
    9

    Re: RS 232 Serial Communication

    I have found that the easiest way to debug a serial port application is to use HyperTerminal. You can check out the basic communication with your microcontroller before moving on to higher level sw like visual basic. HyperTerminal comes for free with every wondows computer 8O



  7. #7
    Junior Member level 3
    Points: 1,893, Level: 10

    Join Date
    Feb 2003
    Posts
    28
    Helped
    1 / 1
    Points
    1,893
    Level
    10

    Re: RS 232 Serial Communication

    For programming serial communitaion I recommed using comport library for Delphi or C++Builder, look at http://sourceforge.net/projects/comport/

    Bye



  8. #8
    Full Member level 4
    Points: 3,337, Level: 13

    Join Date
    Mar 2004
    Location
    UK
    Posts
    231
    Helped
    6 / 6
    Points
    3,337
    Level
    13

    Re: RS 232 Serial Communication

    Hi,

    The best source for those who want to learn RS232 communication and serial port interfacing is beyondlogic.org.

    www.beyondlogic.org/serial/serial.htm

    you can find solution of your problem there.



    •   AltAdvertisement

        
       

  9. #9
    Member level 5
    Points: 2,204, Level: 10

    Join Date
    May 2004
    Posts
    80
    Helped
    2 / 2
    Points
    2,204
    Level
    10

    RS 232 Serial Communication

    Wow..so many sources of information!Thanks guyz!

    Any of you have a sample program that test the 9pin serial port?

    By the way, how you know whether the serial port sent out the correct bits? How can i troubleshoot that issue?



    •   AltAdvertisement

        
       

  10. #10
    Full Member level 4
    Points: 4,353, Level: 15
    Antharax's Avatar
    Join Date
    Jan 2000
    Posts
    208
    Helped
    14 / 14
    Points
    4,353
    Level
    15

    Re: RS 232 Serial Communication

    For a simple gui program, with not to much data throughput and processing or critical timing Visual Basic is fine! For a beginner it's easier to work with!

    Antharax



  11. #11
    Member level 5
    Points: 2,204, Level: 10

    Join Date
    May 2004
    Posts
    80
    Helped
    2 / 2
    Points
    2,204
    Level
    10

    RS 232 Serial Communication

    Thanks Antharax for the advice...
    Now i feel so motivated to do the project..
    Thanks alot!!!



  12. #12
    Full Member level 4
    Points: 4,353, Level: 15
    Antharax's Avatar
    Join Date
    Jan 2000
    Posts
    208
    Helped
    14 / 14
    Points
    4,353
    Level
    15

    Re: RS 232 Serial Communication

    If you search for Serial Port Visual Basic on the internet, you can find allot of examples

    eg: http://www.ontrak.net/visual.htm

    And use duncan94022 's advice about using hyperterminal for debugging!

    Antharax



  13. #13
    Advanced Member level 1
    Points: 4,995, Level: 16

    Join Date
    Nov 2001
    Location
    india
    Posts
    401
    Helped
    27 / 27
    Points
    4,995
    Level
    16

    RS 232 Serial Communication

    Hai,

    u can use mscomm in vb r VC++

    in msdn cd u got the example file.

    its very easy.



  14. #14
    Advanced Member level 1
    Points: 10,571, Level: 24

    Join Date
    Dec 2001
    Posts
    414
    Helped
    12 / 12
    Points
    10,571
    Level
    24

    Re: RS 232 Serial Communication

    Pls ref this book "serial port complete",you also download this book from edonkey.



  15. #15
    Member level 5
    Points: 2,204, Level: 10

    Join Date
    May 2004
    Posts
    80
    Helped
    2 / 2
    Points
    2,204
    Level
    10

    RS 232 Serial Communication

    About mscomm...i did heard before of that.
    Actually what is it?Is it part of the VB?So...if i use VB to program my serial port..will i be using mscomm??
    Oh my goodness..i need to complete the interfacing stuff on next week..hope i can get more help from here...
    Thankx you all!!



  16. #16
    Junior Member level 1
    Points: 1,697, Level: 9

    Join Date
    May 2004
    Location
    Boston, MA
    Posts
    17
    Helped
    1 / 1
    Points
    1,697
    Level
    9

    Re: RS 232 Serial Communication

    Just browsing this forum, I found this topic on RS232 and Visual Basic.

    Here goes a small software I did to interfase a DSP through the serial port. Check the subroutines and you will find how to communicate, send and receive characters.

    You can try this easily: Get a computer with two serial ports (almost all new computers have two). Use a crossed serial cable (Rxd and Txd pins crossed) or just use wire wrap and connect the pins manually. Use your VB interfase connected to one port, and Hyperterminal connected to the second. Whatever you send in both, you should receive in the other one.

    Hope it helps,
    Mariano



  17. #17
    Member level 5
    Points: 2,204, Level: 10

    Join Date
    May 2004
    Posts
    80
    Helped
    2 / 2
    Points
    2,204
    Level
    10

    RS 232 Serial Communication

    Erm...erm...erm...
    You mean...i'll transmit data out and receive data in from the same port? This is to check whether am i sending the correct bits, right?
    What is hyperterminal?
    Thanks you all!!



  18. #18
    Newbie level 6
    Points: 1,584, Level: 9

    Join Date
    May 2004
    Posts
    13
    Helped
    0 / 0
    Points
    1,584
    Level
    9

    Re: RS 232 Serial Communication

    Serial ports come in two flavors DTE and DCE which stand for Data Terminal Equipment and Data Communications Equipmen. To connect a DTE to a DCE you need a normal cable. To connect a DTE to a DTE you need a crossover cable. A PC is a DTE so in order to connect it to another PC (or another port on the same PC) you need to make a special cable as described above.

    Hyperterminal is just a 'terminal' program which lets you transmit characters from and to the serial port on the PC.



  19. #19
    Junior Member level 3
    Points: 1,723, Level: 9

    Join Date
    Apr 2004
    Posts
    31
    Helped
    0 / 0
    Points
    1,723
    Level
    9

    RS 232 Serial Communication

    I use this one to peek what PC and target device talking, very useful tool.

    h**p://www.hhdsoftware.com/sermon.html



  20. #20
    Member level 5
    Points: 2,204, Level: 10

    Join Date
    May 2004
    Posts
    80
    Helped
    2 / 2
    Points
    2,204
    Level
    10

    RS 232 Serial Communication

    If i purchase a normal cable and i interconnect the TxD and RxD pin to test the sending and receiving of bits, will this work even it is not between two comps?



    •   AltAdvertisement

        
       

--[[ ]]--