-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bell fix #35
bell fix #35
Conversation
removed old term_bell function. Tests ok for me. Reply here if good for you and Ill merge |
@@ -669,10 +669,28 @@ void uii_data_print(void) { | |||
asm("cmp #$0a"); | |||
asm("beq %g", skipline); | |||
#endif | |||
// check for bell character and perform sound if so | |||
asm("cmp #$07"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would change lines 673..689 in:
asm("cmp #$07");
asm("bne %g", skipbell);
asm("jsr %v", term_bell)
skipbell:
asm("jsr $ffd2");
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can also have conditional compiling, skipping term_bell on C128, since on C128 CHROUT of #7 char produces a bell sound
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
...but maybe your code is quicker, since it's directly ASM. In that case, let's remove the former term_bell function.
we can avoid code duplication at all calling term_bell from within asm
*asm("jsr %v", term_bell)*
…On Tue, Mar 26, 2019 at 3:01 PM Scott Hutter ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In src/ultimateterm.c
<#35 (comment)>
:
> @@ -187,7 +186,9 @@ void term_displayheader(void) {
void putstring_ascii(char *str) {
for (; *str; str++)
- if (*str != LF) *str==BELL ? term_bell() : putchar(ascToPet[*str]);
+ if (*str != LF) {
yeah, youre right. Ive reverted the term_bell function for that purpose
for now. As bad as duplicated code is, its very small. And, we can use the
bell function for other things as well, such as connection notification or
termination notification.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#35 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ACBUnQ4WjDzu6SBkq-Ir0Gy7Hwv6hpqsks5vaigvgaJpZM4cHHJ_>
.
--
Francesco Sblendorio
http://fsblendorio.blogspot.com
http://www.sblendorio.eu
|
makes sense - will do that |
Seems that the terminal bell stop sounding. I implemented the bell in the assembly code, which seems to work fine now. Please test and confirm