Brass Core Plugins

Brass Core Plugins

Directives

align

Sets the current program counter value to the next multiple of boundary.

big/little

Switches the compiler between big and little endian modes.

block

Increment the program counter and output counter by the specified amount.

breakpoint

resources://Core.Documentation/BreakpointDescription

clearpage

Clears the data output on a particular page.

define

 

defpage

Defines the base address and size of a page.

data

Defines bytes (.db/.byte), 16-bit words (.dw/.word) or 32-bit integers (.di/.int).

You may also define string literals using these directives.

echoln/echo

Writes the text representation of the specified expressions to the console.

echoln writes a new-line sequence at the end of the expression list.

if

Selects statements for execution based on the results of a series of conditionals.

emptyfill

Used to fill unused space in binaries for padding directives.

end

Stops all further assembling.

endmodule/module

Declares the beginning or end of a module.

endsection/section

Defines a code section.

enum

Declare an enumeration, a module containing a list of named constants as labels.

export/endexport

Disables or enables automatic exporting of label names.

fill

Writes a specified number of bytes into the output at the current location.

function/macro

Defines a function.

incbin

Insert all data from a binary file into the output at the current program counter position.

include

Loads and compiles file at the current source file position.

incsection

Inserts a code section at the current location.

inctext

Insert all data from a text file into the output, converting it to the current text encoding.

list/nolist

Disables or enables additions to the list file.

org

Sets the value of the current program counter and output counter.

page

Sets the current page number.

stringencoder

Sets the current string encoder to the one specified.

struct

 

undef

 

while/rept/for/loop

Repeats a series of statements in a loop.

Functions

abs

Returns the absolute value of a specified number.

acos

Returns the angle whose cosine is the specified number.

align

 

and

Returns true if all of the arguments are true; false if any one is false.

asin

Returns the angle whose sine is the specified number.

atan

Returns the angle whose tangent is the specified number.

atan2

Returns the angle whose tangent is the quotient of two specified numbers.

ceiling

Returns the smallest integer greater than or equal to the specified number.

char

Returns a character corresponding to the character code according to the current string encoding.

choose

Chooses a value from a list of values based on an index number. The list has a base index of 1, not 0.

cos

Returns the cosine of the specified angle.

cosh

Returns the hyperbolic cosine of the specified angle.

defined/undefined

defined() returns true if a label or macro is defined, false otherwise; undefined() returns true if the label or macro is undefined.

e/exp

Returns the natural logarithmic base specified by the constant e, or e raised to the specified power.

envvar

 

eval

Evaluates a snippet of code contained in a string.

false

Returns a constant that evaluates to false, or false if the conditional also evaluates to false.

fclose

Closes a file.

feof

Returns true if the file pointer is at the end of the file.

floor

Returns the largest integer less than or equal to the specified number.

fopen

Opens a file and returns a handle for subsequent file operations.

fpos

Returns the current position in the file.

freadtext

Reads all text data from a file.

freadw/freadi/fread

Reads data from a file and advances the pointer.

fseek

Seeks to a position within the file and returns the new position.

fsize

Returns the size of a file.

if

Returns true_value if condition evaluates to true, false_value otherwise.

isinf

Returns true if the expression evaluates to positive or negative infinity.

isnan

Returns true if the expression evaluates to NaN.

isneginf

Returns true if the expression evaluates to negative infinity.

isposinf

Returns true if the expression evaluates to positive infinity.

isstring

 

kb

Returns the number of bytes in value kilobytes.

line

Returns the current line number in the source file.

ln

Returns the natural logarithm of a specified number.

log

Returns the logarithm of a specified number in a specified base.

log10

Returns the base 10 logarithm of a specified number.

max

Returns the larger of two numbers.

min

Returns the smaller of two numbers.

now

Returns the current date and time.

or

Returns true if any of the arguments are true; false if they are all false.

outputwriteris/assembleris/stringencoderis

Returns true if the current plugin matches passed name.

pi

Returns the ratio of the circumference of a circle to its diameter, specified by the constant, π.

rand

Returns a random number between range specified.

round

Rounds a value to the nearest integer or specified number of decimal places.

sign

Returns a value indicating the sign of a number.

sin

Returns the sine of the specified angle.

sinh

Returns the hyperbolic sine of the specified angle.

sizeof

 

sqrt

Returns the square root of a specified number.

srand

Seeds the random number generator.

strformat

Returns a string with formatted numeric results.

strlength

Returns the number of characters of a string.

strlower/strupper

Converts all characters in a string to upper or lower case.

strreplace

Replaces all occurances of a string with another.

strsub

Retrieves a substring.

strtoken

Returns a string made up of the passed tokens.

tan

Returns the tangent of the specified angle.

tanh

Returns the hyperbolic tangent of the specified angle.

todegrees

Converts an angle in radians to one in degrees.

toradians

Converts an angle in degrees to one in degrees.

true

Returns a constant that evaluates to true, or true if the conditional also evaluates to true.

truncate

Calculates the integral part of a number.

userfunction

 

year/month/day/hour/minute/second

Extract a component from a date.

String Encoding

ascii

Provides an encoder for the ASCII (7-bit) character set.

utf16

Provides an encoder for the UTF-16 format.

utf32

Provides an encoder for the UTF-32 format.

utf7

Provides an encoder for the UTF-7 format.

utf8

Provides an encoder for the UTF-8 format.

Number Encoding

ubyte/byte

Defines an 8-bit byte.

uint/int

Defines a 32-bit integer.

word/uword

Defines a 16-bit word.

Output Writers

intelhex

Writes an 8-bit Intel HEX format object file.

raw

Writes output as a raw binary file.

rawpages

Writes output as a raw binary file of consecutive, padded pages.

Pages are output sequentially in the order of their indices, and each page in the binary is output at its declared size.

Unused regions of pages will be filled with the last defined empty fill value.

Listing Writers

emukonpatch

resources://Core.Documentation/EmukonPatchDescription

html

 

no$gmb

 

text

 

todo

Outputs a to-do list in XML format.

veradoc

Generates XML from compiled Vera documentation comments.