Array of string to send with TX int ?


Closed Thread
Results 1 to 19 of 19

Hybrid View

  1. #1
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default Re: Array of string to send with TX int ?

    I still don't get what you're trying to sove with this arfraywrite thing, but maybe the following may give you so idea?
    Code:
            ADDR        VAR WORD
            CHAR        VAR BYTE
            CLEAR
            
            goto OVERDT             
            string1     CON EXT
            string2     CON EXT
            string3     CON EXT
            
            eostring1   CON EXT
            eostring2   CON EXT
            eostring3   CON EXT
            
            string4     CON EXT
            stringend   con ext
            asm     
    string1       dt "_this is string1"
    eostring1 =$-1
    
    string2       dt "_this is string2"
    eostring2 =$-1
    
    string3       dt "_this is string3"
    eostring3 =$-1
    
    stringend
            #define s4  "yaya dada String 4 "
            #define s5  "Plah plah plah string 5 "
    string4         dt s4,s5, 0 
            endasm
    OVERDT:
            ADDR=string4
    MAIN:
            READCODE  ADDR, CHAR
            IF CHAR THEN
                    hserout [char]
                    ADDR=ADDR+1
                    GOTO MAIN
                    ENDIF
                    
            HSEROUT [13,10,REP "-"\80,13,10] 
               
            for addr = string1 to eostring1
                    readcode ADDR, CHAR
                    HSEROUT [CHAR]
                    next
                    
            HSEROUT [13,10,REP "-"\80,13,10,"DONE !"]
    SPIN:   GOTO SPIN
    Case not, well, sorry
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  2. #2


    Did you find this post helpful? Yes | No

    Default Re: Array of string to send with TX int ?

    ok,
    basically, the following is a responce to an HTTP request, just a string stuff, not impossible to assemble, and that will display on a web page through a TCP thing.

    HTTP/1.0 200 OK
    Date: Fri, 31 Dec 1999 23:59:59 GMT
    Content-Type: text/html
    Content-Length: 1354
    <html>
    <body>
    <h1>Happy New Millennium!</h1>
    (more file contents)
    .
    ...........try to add some PIC data stuff in here
    .
    </body>
    </html>

    so thats that part of being able to make string array and be able to send out when ready ????

    Name:  Untitled.jpg
Views: 876
Size:  35.8 KB
    don
    Last edited by amgen; - 17th August 2011 at 19:18.

  3. #3
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default Re: Array of string to send with TX int ?

    Well you definitely don't need any array to do that, it sucks way too much RAM for absolutely nothing. What I feel you should do is a kind of template
    Header
    extrastuff
    footer

    send the header, then the extra stuff and finally the footer. A flag for each part sent should do the trick... At least, from what I feel.

    And still, it shouldn't be faster than a couple of HSEROUT line... but more flexible if you're using asm DT/DB/DATA/DA.

    I'll continue to follow this thread, it's interesting while I'm not sure I still understand the requirement
    Last edited by mister_e; - 17th August 2011 at 19:39.
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  4. #4


    Did you find this post helpful? Yes | No

    Default Re: Array of string to send with TX int ?

    Steve,
    That is good but for 1 or 2 issues,
    In the header, you need to know the 'total length' of bytes you are sending because that will 'finish off the transmission and stop IE from continuing to wait for more.
    The 18f2525 and other's have 4K bytes ram so an array or 2 of [1000] still leaves plenty or ram.....

    don

  5. #5
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default Re: Array of string to send with TX int ?

    That's the kind of missing info I needed But it's still doable using the DT/DATA thing at running time.

    Oh well. Keep us inform
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

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