Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

make the blink attribute accessible for status display

  • Loading branch information...
commit a291c3ed8f1ead67fdefb492c2291c262aa0725d 1 parent 5c6825e
@fhars authored
Showing with 31 additions and 7 deletions.
  1. +20 −7 kernel.dasm16
  2. +11 −0 readme.md
View
27 kernel.dasm16
@@ -678,6 +678,14 @@
SET A, [_pc_curr_proc]
SET PC, _pc_set_cell_color
+; set the blink attribute for the current process status cell
+;
+; input A: : blink on (1) or blink off (0)
+:status_blink
+ SET C, A
+ SET A, [_pc_curr_proc]
+ SET PC, _pc_set_cell_blink
+
; print the hex representation of a number in the status cell
;
; the function sets the custom status bit which disables the default
@@ -821,12 +829,11 @@
SET Y, 0x777F ; keep characters and colors
SET PC, _pc_set_status_l
-; set blink for a process status cell
+; set blink attribute for a process status cell
;
; input A: the process slot number
-; input C: highlight (1) or unhighlight (0)
-
-:_pc_set_cell_hilit
+; input C: blink on (1) or blink off (0)
+:_pc_set_cell_blink
JSR _pc_calc_set_cell
; set the blink bit for an array of screen cells
@@ -960,9 +967,15 @@
SET PC, loop4
; the end is an endless loop
- SET A, 0
-:crash JSR yield
- ADD A, 1
+ SET I, 0
+:crash SET A, I
+ JSR yield
+ SET B, I
+ AND B, 0x0fff
+ SET A, 1
+ IFE B, 0
+ JSR status_blink
+ ADD I, 1
SET PC, crash
:show_foobar
View
11 readme.md
@@ -129,6 +129,17 @@ JSR status_color
will set the foreground to green (2) and the background to red (4)
+status_blink
+------------
+
+```status_blink``` sets the blink attribute of the current process
+status cell if A is 1 and clears it otherwise. The blink bit is also
+cleared if the user tabs to or from the process. ```status_blink``` is
+meant as a way for processes that are not currently displayed to
+notify the user that something has happened that requires immediate
+attention.
+
+
status_i2hex
------------
Please sign in to comment.
Something went wrong with that request. Please try again.