Graphics

Graphics mode 9 demonstration
Effectus code ASM code Executable code

Graphics demonstration by w1k
Effectus code ASM code Executable code

Graphics mode 7 and parameter usage demonstration (drawing a triangle)
Effectus code ASM code Executable code

Fill routine demonstration
Effectus code ASM code Executable code

Butterfly by Michael Mitchell, provided to AtariAge by w1k
Effectus code ASM code Executable code


Arrays, sets, types, pointers

Demonstration of using array sets
Effectus code ASM code Executable code

Demonstration of using arrays for holding different types of values, such as numbers and strings
Effectus code ASM code Executable code

Demonstration of using arrays in loops (WHILE and FOR loop)
Effectus code ASM code Executable code

Demonstration of declaring type (struct) and its usage with variable
Effectus code ASM code Executable code

Demonstration od using records in array of custom type
Effectus code ASM code Executable code

Demonstration of using pointers using POINTER
Effectus code ASM code Executable code

BYTE ARRAY usage demonstration using direct memory assignment
Effectus code ASM code Executable code

CARD ARRAY usage demonstration using direct memory assignment
Effectus code ASM code Executable code


String manipulation

SCopy command demonstration
Effectus code ASM code Executable code

SCopyS command demonstration
Effectus code ASM code Executable code

SAssign command demonstration
Effectus code ASM code Executable code

String to number conversion using ValB, ValI and ValC commands
Effectus code ASM code Executable code

Number to string conversion using StrB, StrI and StrC commands
Effectus code ASM code Executable code

String input demonstration using InputS command
Effectus code ASM code Executable code

SCompare function demonstration
Effectus code ASM code Executable code


POKE and PEEK statement

Demonstration of using POKE statement
Effectus code ASM code Executable code

Demonstration of using PEEK statement
Effectus code ASM code Executable code


Branching/looping and conditional statements

IF / ELSE condition demonstration
Effectus code ASM code Executable code

FOR loop demonstration
Effectus code ASM code Executable code

WHILE loop demonstration
Effectus code ASM code Executable code

UNTIL loop demonstration
Effectus code ASM code Executable code

Demonstration od using DO OD loop
Effectus code ASM code Executable code

Demonstration of using EXIT command in loop statements
Effectus code ASM code Executable code

Loop effects by ascrnet
Effectus code ASM code Executable code

Demonstration of using IF statement with two conditions
Effectus code ASM code Executable code

ELSEIF example
Effectus code ASM code Executable code

Nested IF demonstration
Effectus code ASM code Executable code

IF condition demonstration using # (<>) operator
Effectus code ASM code Executable code

Demonstrating function execution in WHILE expression
Effectus code ASM code Executable code

Demonstrating function execution in IF and WHILE conditional expressions
Effectus code ASM code Executable code


PROCedures and FUNCtions

Demonstration of using local procedures
Effectus code ASM code Executable code

Demonstration of using local functions
Effectus code ASM code Executable code

Inline machine language usage in PROCedures
Effectus code ASM code Executable code

Inline machine language usage in FUNCtions
Effectus code ASM code Executable code

Calling OS routines
Effectus code ASM code Executable code


Arithmetic and bitwise operations

Arithmetics demonstration
Effectus code ASM code Executable code

Arithmetics demonstration of using operators MOD, ==+, ==-, ==*, and ==/
Effectus code ASM code Executable code

Demonstration of using logical (bitwise) operators
Effectus code ASM code Executable code


Printing characters on screen or other device

Demonstration of printing characters on screen
Effectus code ASM code Executable code

Demonstration of using PrintF command for printing formatted string on screen
Effectus code ASM code Executable code

Demonstration of printing characters on special device
Effectus code ASM code Executable code

Demonstration of printing text in graphics mode 2 (program by by ascrnet)
Effectus code ASM code Executable code


Disk input/output

Demonstration of reading characters one at a time from text file
Effectus code ASM code Executable code Disk image

Demonstration of reading lines of strings from text file
Effectus code ASM code Executable code Disk image


Misc

Sound demonstration
Effectus code ASM code Executable code

Joystick manipulation demonstration
Effectus code ASM code Executable code

Random number generator demonstration
Effectus code ASM code Executable code

Simple game using random number generator
Effectus code ASM code Executable code

INCLUDE demonstration (showing how to include library file to main program)
Effectus code ASM code Executable code

Custom user library as part of main program using INCLUDE statement
Effectus code

Keyboard device demonstration
Effectus code ASM code Executable code

Constants (DEFINE statement)
Effectus code ASM code Executable code

Using more than one operand in parameters
Effectus code ASM code Executable code

InputB, InputI and InputC function demonstration
Effectus code ASM code Executable code

Finescroll by greblus
Effectus code ASM code Executable code

ASCII demonstration
Effectus code ASM code Executable code



examples/code/math_test2.asm

Effectus code Mads code Executable code
 org $2200

 icl 'c:\atari\effectus\lib\common.asm'

 .var var19750412_eff_ .word
 .var n1_eff_ .word
 .var n2_eff_ .word
 .var i_eff_ .word

; Effectus example:
; Arithmetics demonstration


MAIN_reff_

 Put #125
 jsr printf
 dta c'Effectus example:',$9b,0
 jsr printf
 dta c'Arithmetics demonstration',$9b,0
 PutE

 mwa #4 n2_eff_

; Addition example
 mwa #7 n1_eff_
 adw n1_eff_ #2
 jsr printf
 dta c'%',$9b,0
 dta a(n1_eff_)

; Subtraction example
 mwa #240 n1_eff_
 sbw n1_eff_ #40
 jsr printf
 dta c'%',$9b,0
 dta a(n1_eff_)

; Multiplication example
 mwa #8 n1_eff_
 Mul16 n1_eff_, #10
 mwa  $A0 n1_eff_
 jsr printf
 dta c'%',$9b,0
 dta a(n1_eff_)

; Division example
 mwa #210 n1_eff_
 Div16 n1_eff_, #70
 mwa  $A0 n1_eff_
 jsr printf
 dta c'%',$9b,0
 dta a(n1_eff_)

 dew n1_eff_
 jsr printf
 dta c'%',$9b,0
 dta a(n1_eff_)

 mwa #8 n1_eff_
 Mul16 n1_eff_, n2_eff_
 mwa  $A0 n1_eff_
 jsr printf
 dta c'%',$9b,0
 dta a(n1_eff_)

 Div16 n1_eff_, n2_eff_
 mwa  $A0 n1_eff_
 jsr printf
 dta c'%',$9b,0
 dta a(n1_eff_)

; MOD examples
 jsr printf
 dta c'n1 = 10 MOD 4',$9b,0
 jsr printf
 dta c'n1 = ',0
 Mod8 #10, #4
 mwa  $A0 n1_eff_
 jsr printf
 dta c'%',$9b,0
 dta a(n1_eff_)
 PutE
 jsr printf
 dta c'i = 255 MOD 10',$9b,0
 jsr printf
 dta c'i = ',0
 Mod8 #255, #10
 mwa  $A0 i_eff_
 jsr printf
 dta c'%',$9b,0
 dta a(i_eff_)

 PutE
 PutE
 jsr printf
 dta c'End of program',$9b,0

 jmp *

 .link 'c:\atari\effectus\lib\runtime.obx'
 .link 'c:\atari\effectus\lib\printf.obx'
 .link 'c:\atari\effectus\lib\math.obx'

 run Main_reff_