C Cross Compiler User’s Guide For STM8 CXSTM8 Users
CXSTM8_UsersGuide
CXSTM8_UsersGuide
CXSTM8_UsersGuide
User Manual:
Open the PDF directly: View PDF
Page Count: 456 [warning: Documents this large are best viewed by clicking the View PDF Link!]
- Preface
- Introduction
- Tutorial Introduction
- Programming Environments
- Introduction
- Modifying the Runtime Startup
- Initializing data in RAM
- Memory Models for code smaller than 64K
- Memory Models for code larger than 64K
- Handling Large Code and Constants
- Bit Variables
- The const and volatile Type Qualifiers
- Performing Input/Output in C
- Referencing Absolute Addresses
- Accessing Internal Registers
- Placing Data Objects in The Bss Section
- Placing Data Objects in Short Range Memory
- Placing Data Objects in Long Range Memory
- Placing Data Objects in the EEPROM Space
- Redefining Sections
- Inserting Inline Assembly Instructions
- Writing Interrupt Handlers
- Placing Addresses in Interrupt Vectors
- Inline Function
- Interfacing C to Assembly Language
- Register Usage
- Data Representation
- Using The Compiler
- Invoking the Compiler
- File Naming Conventions
- Generating Listings
- Generating an Error File
- Return Status
- Examples
- C Library Support
- Descriptions of C Library Functions
- Generate inline assembly code
- Abort program execution
- Find absolute value
- Arccosine
- Arcsine
- Arctangent
- Arctangent of y/x
- Convert buffer to double
- Convert buffer to integer
- Convert buffer to long
- Test or get the carry bit
- Round to next higher integer
- Verify the recorded checksum
- Verify the recorded checksum
- Verify the recorded checksum
- Verify the recorded checksum
- Cosine
- Hyperbolic cosine
- Divide with quotient and remainder
- Erase the full eeprom space
- Exit program execution
- Exponential
- Find double absolute value
- Copy a moveable code segment in RAM
- Round to next lower integer
- Find double modulus
- Extract fraction from exponent part
- Get character from input stream
- Get a text line from input stream
- Test the interrupt mask bit
- Test the interrupt line level
- Test for alphabetic or numeric character
- Test for alphabetic character
- Test for control character
- Test for digit
- Test for graphic character
- Test for lowercase character
- Test for printing character
- Test for punctuation character
- Test for whitespace character
- Test for uppercase character
- Test for hexadecimal digit
- Find long absolute value
- Scale double exponent
- Long divide with quotient and remainder
- Natural logarithm
- Common logarithm
- Test for maximum
- Scan buffer for character
- Compare two buffers for lexical order
- Copy one buffer to another
- Copy one buffer to another
- Propagate fill character throughout buffer
- Test for minimum
- Extract fraction and integer from double
- Raise x to the y power
- Output formatted arguments to stdout
- Put a character to output stream
- Put a text line to output stream
- Generate pseudo-random number
- Sin
- Hyperbolic sine
- Output arguments formatted to buffer
- Real square root
- Seed pseudo-random number generator
- Concatenate strings
- Scan string for first occurrence of character
- Compare two strings for lexical order
- Copy one string to another
- Find the end of a span of characters in a set
- Find length of a string
- Concatenate strings of length n
- Compare two n length strings for lexical order
- Copy n length string
- Find occurrence in string of character in set
- Scan string for last occurrence of character
- Find the end of a span of characters not in set
- Scan string for first occurrence of string
- Convert buffer to double
- Convert buffer to long
- Convert buffer to unsigned long
- Tangent
- Hyperbolic tangent
- Convert character to lowercase if necessary
- Convert character to uppercase if necessary
- Using The Assembler
- Invoking castm8
- Object File
- Listings
- Assembly Language Syntax
- Branch Optimization
- Old Syntax
- C Style Directives
- Assembler Directives
- Align the next instruction on a given boundary
- Define the default base for numerical constants
- Switch to the predefined .bsct section.
- Turn listing of conditionally excluded code on or off.
- Allocate constant(s)
- Allocate constant block
- Turn listing of debug directives on or off.
- Allocate variable(s)
- Conditional assembly
- Conditional assembly
- Stop the assembly
- End conditional assembly
- End conditional assembly
- End macro definition
- End repeat section
- Give a permanent value to a symbol
- Assemble next byte at the next even address relative to the start of a section.
- Generate error message.
- Conditional assembly
- Conditional assembly
- Conditional assembly
- Conditional assembly
- Conditional assembly
- Conditional assembly
- Conditional assembly
- Conditional assembly
- Conditional assembly
- Conditional assembly
- Conditional assembly
- Include text from another text file
- Turn on listing during assembly.
- Give a text equivalent to a symbol
- Create a new local block
- Define a macro
- Send a message out to STDOUT
- Terminate a macro definition
- Turn on or off listing of macro expansion.
- Turn off listing.
- Disable pagination in the listing file
- Creates absolute symbols
- Sets the location counter to an offset from the beginning of a section.
- Start a new page in the listing file
- Specify the number of lines per pages in the listing file
- Repeat a list of lines a number of times
- Repeat a list of lines a number of times
- Restore saved section
- Terminate a repeat definition
- Save section
- Turn on or off section crossing
- Define a new section
- Give a resetable value to a symbol
- Insert a number of blank lines before the next statement in the listing file.
- Place code into a section.
- Specify the number of spaces for a tab character in the listing file
- Define default header
- Declare bit symbol as being defined elsewhere
- Declare a variable to be visible
- Declare symbol as being defined elsewhere
- Using The Linker
- Debugging Support
- Programming Support
- Compiler Error Messages
- Modifying Compiler Operation
- STM8 Machine Library
- Update an int bitfield in external memory
- Quotient of unsigned char division
- Quotient of unsigned char division
- Eeprom char bit field update
- Write a char in eeprom
- Write a long int in eeprom
- Write a short int in eeprom
- Move a structure in eeprom
- Add float to float
- Compare floats
- Divide float by float
- Add float to float in memory
- Multiply float by float in memory
- Subtract float from float in memory
- Multiply float by float
- Negate a float
- Subtract float from float
- Convert float to integer
- Convert float into long integer
- Compare a float in memory to zero
- Get a long word from external memory
- Get a long word from external memory
- Get a word from external memory
- Get a word from external memory
- Quotient of integer division
- Integer multiplication
- Convert integer into float
- Convert integer into long
- Perform C switch statement on long
- Long integer addition
- Bitwise AND for long integers
- Long integer compare
- Quotient of long integer division
- Long addition
- Long bitwise AND
- Long shift left
- Long multiplication in memory
- Negate a long integer in memory
- Long bitwise OR
- Signed long shift right
- Long subtraction
- Unsigned long shift right
- Long bitwise exclusive OR
- Long integer shift left
- Remainder of long integer division
- Multiply long integer by long integer
- Negate a long integer
- Bitwise OR with long integers
- Long integer right shift
- Long test against zero
- Long integer subtraction
- Convert long integer into float
- Load memory into long register
- Quotient of unsigned long integer division
- Remainder of unsigned long integer division
- Unsigned long integer shift right
- Bitwise exclusive OR with long integers
- Compare a long integer to zero
- Put a long integer in external memory
- Put a long integer in external memory
- Put a word in extended memory
- Store long register in memory
- Store long register in external memory
- Quotient of signed char division
- Quotient of signed char division
- Multiply long integer by unsigned byte
- Quotient of unsigned integer division
- Convert unsigned integer into float
- Convert unsigned integer into long
- Convert unsigned long integer into float
- Copy a structure into another
- Copy a structure in external memory
- Copy a structure into another
- Copy a structure in external memory
- Compiler Passes