Send binary file to pic over pc serial port


Results 1 to 21 of 21

Threaded View

  1. #5
    xnihilo's Avatar
    xnihilo Guest


    Did you find this post helpful? Yes | No

    Default

    Darrel,

    Thank you for the answers but i'm lost now...
    How does hyperterminal work when transfering a text file over com port? It simply sends all the file as a bytes stream and inserts a user defined delay between each of the bytes, until it reaches the eof? So that's why we don't need flow control?

    Then i have to poll a bit that will tell me when the 8 bits of the transfered byte have filled the usart buffer? And if so i copy the buffered byte in an array for example?

    Hserin takes care only of reading bits incoming on rx pin and setting the buf-full flag bit?

    Did i get it well?

    By the way, i remember from my old C programming days that there is a differece between Ascii and binary files (ascii may be interpreted for lf and cr characters... as this is no pc 'getch' handling we don't care if hyperterminal sends it as ascii, right?)

    One last thing, i've checked the dataseet for 18f252 and 452, besides the memory size and psp and i/o pins count, i could as well use a cheaper 252 instead of 452 if it is to receive a file from pc into an spi eeprom and then send it to a 16bits dac. Both pics can run at 40mhz with 10mhz crystal and pll?

    By the way... why would I need USART at all. Can't I poll an input pin connected to PC serial TX (out) and get bits one after another and build bites and transfer them to memory. I could even use an interrupt to know when a byte is incming...?
    Last edited by xnihilo; - 12th September 2008 at 20:58.

Similar Threads

  1. serial to PIC
    By kindows in forum mel PIC BASIC Pro
    Replies: 22
    Last Post: - 14th July 2009, 14:58
  2. HSERIN & Interupts (aka controlling PIC programs from a remote PC)
    By HankMcSpank in forum mel PIC BASIC Pro
    Replies: 16
    Last Post: - 17th June 2009, 15:46
  3. High Speed Serial Comm PC - PIC and PIC - PIC
    By manumenzella in forum mel PIC BASIC Pro
    Replies: 23
    Last Post: - 16th January 2007, 22:55
  4. Serial com PIC <> PC - what is best?
    By flotulopex in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 3rd January 2007, 09:37
  5. Serial communication PIC to PIC help.
    By Rubicon in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 24th January 2005, 16:45

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts