Announcement

Collapse
No announcement yet.

PC Communication

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • PC Communication

    I need to send data to a PC. I'm using PicBasic Pro and a 16F616 processor.

    Does anyone have sample code for PC communication?

    Any help will be appreciated.

    Joe rapoza

  • #2
    Serout and Serout2

    I have used SEROUT and SEROUT 2 to send data to a computer many times via an RS-232 connection. These days, it is sometimes easier to use something like an FTDI USB to RS-232 chip to get around the problem of no serial ports on computers.

    However, SEROUT and SEROUT2 are very easy to use and allow you to use any port to send the data.

    I hope this helps somewhat.

    Comment


    • #3
      ve6cmm,

      Thanks for your reply. When you used the SERIN and SEROUT commands did you have to provide a separate clock. Does the processor provide the clock?

      I would like to use the Hypertex program in the PC to receive data. Can I use a null modem and connect the serial out data to the appropriate pin?

      You can tell this is my first time with this processor (16F616).

      Can you show me or tell me how to do this?

      Thanks for your help.

      Joe Rapoza

      Comment


      • #4
        PC Comms

        Hi Joe,

        I have used the commands on several different chips and it has worked fine. It is not a hardware based serial port, but this doesn't usually matter for getting data out. So far, I haven't used the hardware UART's as I haven't needed interrupts for incoming data. I have been programming on and off for years, but still a novice. It seems every time I need to use a micro, I have to relearn everything.

        To answer your question, the SEROUT and SEROUT2 commands do not require any clock lines. The data is sent is ASCII and only one pin is required.

        The info is starts at page 210 in the new PBP3 REFERENCE MANUAL ( July 12, 2011) or around page 134 in the earlier manuals. I tried to copy and past them into this post, but the formatting did not transfer, making the text pretty hard to read.

        Regards,

        Clint Millett, VE6CMM

        Comment

        Working...
        X