2474
|
1 ***************************************************
|
|
2
|
|
3 * Convert character in "B" to uppercase
|
|
4
|
|
5 * OTHER MODULES NEEDED: IS_LOWER
|
|
6
|
|
7 * ENTRY: B=ascii value of character to convert
|
|
8
|
|
9 * EXIT: B=ascii value of character in uppercase
|
|
10
|
|
11 * Note: control codes, etc. are not effected.
|
|
12
|
|
13
|
|
14 nam Convert Char to Uppercase
|
|
15 ttl Assembler Library Module
|
|
16
|
|
17
|
|
18 psect TO_UPPER,0,0,0,0,0
|
|
19
|
|
20 TO_UPPER:
|
|
21 pshs cc
|
|
22 lbsr IS_LOWER only lowercase can be converted to upper
|
|
23 bne toupx
|
|
24 subb #$20 make uppercase
|
|
25
|
|
26 toupx
|
|
27 puls cc,pc
|
|
28
|
|
29 endsect
|
|
30 |