From d8c80df020a2f6d0e80b9a681cdb4d1a99037ab2 Mon Sep 17 00:00:00 2001 From: Lyra Thorpe Date: Fri, 26 Jun 2026 17:42:46 +0100 Subject: [PATCH] feat(hello): add a Hellorld application just the docs example, but better commented --- code/hellorld/hello.c | 16 ++++++++++++++++ code/hellorld/hello.pr | 5 +++++ 2 files changed, 21 insertions(+) create mode 100644 code/hellorld/hello.c create mode 100644 code/hellorld/hello.pr diff --git a/code/hellorld/hello.c b/code/hellorld/hello.c new file mode 100644 index 0000000..507e066 --- /dev/null +++ b/code/hellorld/hello.c @@ -0,0 +1,16 @@ +/* + * hello.c + * + * Hellorld application using Psion's "CLIB" - just plain C, no Psion extensions + */ + +#include + +int main(VOID) { + // Does sprintf work here? The SDK is probably too old, but modern conventions would be nice + printf("Hellorld!"); + // Wait for a key to be pressed + getchar(); + // Exit, not sure why 0 is being passed as it's a void? But this is the SDK example code + return(0); +} diff --git a/code/hellorld/hello.pr b/code/hellorld/hello.pr new file mode 100644 index 0000000..3add08a --- /dev/null +++ b/code/hellorld/hello.pr @@ -0,0 +1,5 @@ +#system epoc img +#model small jpi + +#compile hello +#link hello