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/fs.asm

Effectus code Mads code Executable code
 org $2200

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

 .var var19750412_eff_ .word
 .var j_eff_=0 .word
 .var k_eff_=0 .word
hsc_eff_ equ 54276
 .var tmpl_eff_ .byte
 .var tmph_eff_ .byte
 .var tmp_eff_ .byte
 .var i_eff_ .word
sav_eff_ equ 88
clock_eff_ equ $14
nmi_eff_ equ $D40E
dlist_eff_ equ 560
vvblkd_eff_ equ $0224
col0_eff_ equ 708
col1_eff_ equ 709
 .array ndl_eff_ .byte = $ff
 112, 112, 112, 66, 64, 156, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 86, 216, 159, 65, 32, 156
 .end

; Effectus example:
;
; Finescroll by greblus

CHNDL_reff_ .proc
; (1)
 mva NDL_eff_[28] tmp_eff_
 #if .byte tmp_eff_<#2
; (2)
 mva #255 ndl_eff_[28]
; (3)
 sbb ndl_eff_[29] #1 tmp_eff_
; (4)
 mva TMP_eff_ ndl_eff_[29]
 #else
; (5)
 sbb ndl_eff_[28] #2 tmp_eff_
; (6)
 mva TMP_eff_ ndl_eff_[28]
 #end
from_else16
 rts

 .endp
SCROL_reff_ .proc
 mva J_eff_ hsc_eff_
 inw j_eff_
 #if .word j_eff_=#17
 chndl_reff_ 
 mwa #0 j_eff_
 inw k_eff_
 #end
 #if .word k_eff_=#14
 mva TMPL_eff_ ndl_eff_[28]
 mva TMPH_eff_ ndl_eff_[29]
 mwa #0 k_eff_
 #end
 .he  4C 62 E4
 rts

 .endp
MAIN_reff_
 Graphics #0
 mwa #NDL_eff_ dlist_eff_
 mwa #40000 sav_eff_
 mva #14 col0_eff_
 mva #14 col1_eff_
 mwa #1 I_eff_
 mwa #23 $A2
for_loop58
 jsr printf
 dta c'line: ',0
 jsr printf
 dta c'%',0
 dta a(i_eff_)
 PutE
 lda I_eff_
 cmp $A2
 lda I_eff_+1
 sbc $A3
 inw I_eff_
 jcc for_loop58
 jsr printf
 dta c'Action!',0
 mva NDL_eff_[28] tmpl_eff_
 mva NDL_eff_[29] tmph_eff_
 mwa CLOCK_eff_ i_eff_
 #while .byte clock_eff_=i_eff_
 #end
 mva #0 nmi_eff_
 mwa #SCROL_reff_ vvblkd_eff_
 mva #$40 nmi_eff_
loop74 jmp loop74
 jmp *

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

 run main_reff_