From d78062b1643006c59e325d4821361e56d9bd3b71 Mon Sep 17 00:00:00 2001 From: JozanLeClerc Date: Fri, 17 Apr 2020 17:15:51 +0200 Subject: Starting the main program, bus error somehow --- asm/jo_f_percent.asm | 2 +- asm/jo_f_status.asm | 2 +- asm/jo_r_lowbat.asm | 27 +++++++++++++++++++++++++++ 3 files changed, 29 insertions(+), 2 deletions(-) create mode 100644 asm/jo_r_lowbat.asm (limited to 'asm') diff --git a/asm/jo_f_percent.asm b/asm/jo_f_percent.asm index 76d792b..6ce918b 100644 --- a/asm/jo_f_percent.asm +++ b/asm/jo_f_percent.asm @@ -3,7 +3,7 @@ ;; File : jo_f_percent.asm /_________/ ;; ;; Author : Joe | ;; ;; Date : 04/2020 | ;; -;; Info : gets batt remaining capacity | ;; +;; Info : Gets batt remaining capacity | ;; ;; / | ;; ;; \ / ;; ;; \_____/ ;; diff --git a/asm/jo_f_status.asm b/asm/jo_f_status.asm index 326f58e..723df0b 100644 --- a/asm/jo_f_status.asm +++ b/asm/jo_f_status.asm @@ -3,7 +3,7 @@ ;; File : jo_f_status.asm /_________/ ;; ;; Author : Joe | ;; ;; Date : 04/2020 | ;; -;; Info : gets batt status | ;; +;; Info : Gets batt status | ;; ;; / | ;; ;; \ / ;; ;; \_____/ ;; diff --git a/asm/jo_r_lowbat.asm b/asm/jo_r_lowbat.asm new file mode 100644 index 0000000..42863b4 --- /dev/null +++ b/asm/jo_r_lowbat.asm @@ -0,0 +1,27 @@ +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;; ;; +;; File : jo_r_lowbat.asm /_________/ ;; +;; Author : Joe | ;; +;; Date : 04/2020 | ;; +;; Info : The main program | ;; +;; / | ;; +;; \ / ;; +;; \_____/ ;; +;; ;; +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + +section .text + extern sleep + extern jo_n_speak + global jo_r_lowbat + +jo_r_lowbat: + mov rdi, 0x2 + call sleep + mov rdi, msg + call jo_n_speak + xor rax, rax + retq + +section .data + msg: db "Welcome back, partner", 0x0 -- cgit v1.2.3