This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var sys = require("sys"), | |
net = require("net"), exec = require('child_process'); | |
var debug = 4; | |
//var client = net.createConnection(8000); | |
var __curr_process; | |
var client = net.createConnection(8000, "moodle.jdiez.me"); | |
client.setEncoding("UTF8"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
DCPU Debugging Symbols Standard | |
=============================== | |
Version 1.0, by the DCPU Toolchain team. | |
Definitions | |
----------- | |
[uint8_t] -> An unsigned 8-bit word | |
[uint16_t] -> " " 16-bit word. | |
[uint32_t] -> " " 32-bit word. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <avr/pgmspace.h> | |
#define LAYER_TIME 3333 | |
#define LAYER_BITS 16 | |
#define FRAME_TIME 20 | |
PROGMEM prog_uchar drip[] = | |
{ | |
/* snip */ | |
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
DT_PATH=$(HOME)/DCPUToolchain | |
CC=$(DT_PATH)/dtcc/dtcc | |
ASM=$(DT_PATH)/dtasm/dtasm | |
LD=$(DT_PATH)/dtld/dtld | |
EMU=$(DT_PATH)/dtemu/dtemu | |
STDLIB=$(DT_PATH)/stdlib-c/stdlib.dlib16 | |
KERNEL=$(DT_PATH)/kernel/stubsys.dkrn16 | |
JUMP=$(DT_PATH)/kernel/stubsys.djmp16 | |
INCLUDE=${DT_PATH}/stdlib-c/include |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void sped3_setup(void* pointer, unsigned int count) | |
{ | |
__asm | |
{ | |
SET PUSH, Y ; Preserve stack pointer | |
.IMPORT _stubapi_locate_device | |
SET A, 0x42ba ; Set the SPED3 ID (0x42babf3c) | |
SET B, 0xbf3c | |
JSR [_stubapi_locate_device] ; Call the locate_device system function |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void sped3_rotate(unsigned int alpha) | |
{ | |
__asm | |
{ | |
SET PUSH, Y | |
.IMPORT _stubapi_locate_device | |
SET A, 0x42ba | |
SET B, 0xbf3c | |
JSR [_stubapi_locate_device] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void nop() | |
{ | |
__asm | |
{ | |
SET PC, PC | |
} | |
} | |
void rotate() | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
unsigned int idx = 0; | |
void* vertices = 0x5000; | |
/* top */ | |
vertices[idx++] = 0x0000; | |
vertices[idx++] = 0x02ff; | |
vertices[idx++] = 0xff00; | |
vertices[idx++] = 0x02ff; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <ext/screen.h> | |
void main() | |
{ | |
sped3_setup(vertices, 8); | |
eputs("Setup done!", 0, 0); | |
eputs("Rotation angle: ", 0, 2); | |
while(1) | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import sys, requests | |
if __name__ == '__main__': | |
text = sys.stdin.readlines() | |
url = requests.post("http://paste.pm/post", {'content': text}).text | |
print "http://paste.pm" + url |
OlderNewer