Get a 62.5% more program space easily


Results 1 to 6 of 6

Threaded View

  1. #3
    serandre's Avatar
    serandre Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by mister_e
    interesting idea if you only need plain text in Upper Case. Good job! Now how do you save this to your codespace?

    Did you already look here for a thread called Embedded String in your code space?
    See the short story there http://www.pbpgroup.com/modules/wfse...p?articleid=10

    Easier does it?
    In fact it's possible to use any character using a 5bits coding:

    Since A-Z is only 26 letters, the 5 bits coding has a remaining 5 position to be used as controls like bellow:

    I prefer to use the default as a lower case chars. (abcdef...)
    So A-Z are coded as a=1, b=2, c=3, d=4...till z=26

    As controls I use:
    0 - End of string
    27 - Space char
    28 - Begin/End mark for a upper case string
    29 - Begin/End mark for numbers 0-9
    30 - Begin/End mark for symbols +-,.!$%^ (max 26 symbols each one is a char A-Z)
    31 - Reserved, I have in nothing in mind in the moment :-)

    So I code the string this way:

    Source:
    "/t/hese /word/ is in upper case this year is [bjjf]"

    the ouput:
    "This WORD is in upper case this year is 2006"

    I am doing this ... errr... by hand :-) transforming the string directly to bits, it's a hell of work i know, I need just to create a program to translate the strings (Source above) to the bits and coded as i want.

    Well, this idea I took from the HTML format, so even with as little as 5 bits I can get any char in a compact size :-)
    Last edited by serandre; - 7th April 2006 at 03:36.

Similar Threads

  1. Presetting Configuration Fuses (PIC Defines) into your Program
    By Melanie in forum FAQ - Frequently Asked Questions
    Replies: 82
    Last Post: - 15th December 2013, 10:54
  2. Replies: 1
    Last Post: - 23rd May 2009, 10:22
  3. How much code space do PBP statements use.
    By Darrel Taylor in forum Code Examples
    Replies: 5
    Last Post: - 13th February 2009, 22:31
  4. Making Program Code Space your playground...
    By Melanie in forum Code Examples
    Replies: 15
    Last Post: - 19th July 2008, 09:26
  5. PIC16F684 Program question
    By Nicholas in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 28th December 2006, 15:30

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