Difference between revisions of "Code Examples"
From GbdevWiki
(→GBDK C examples) |
(→Assembler examples: Add link to "useful ASM snippets" page) |
||
Line 40: | Line 40: | ||
* [[ASM Init| GB Initialization]] | * [[ASM Init| GB Initialization]] | ||
* [[ASM Joypad| Reading the joypad]] | * [[ASM Joypad| Reading the joypad]] | ||
+ | * [[ASM Snippets]] |
Revision as of 14:54, 12 February 2019
Simple GBBasic 2.10 example
10 rem Simple example 20 for i=1 to 16 30 u=rnd(1)*16 40 print u 50 delay 20 60 next i 70 end
GBDK C examples
receive byte across link cable
Simple GBDK example
#include <gb/gb.h> #include <stdio.h> void main() { printf("nHello World!"); }