CS318 - Pintos
Pintos source browser for JHU CS318 course
Functions
speaker.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void speaker_on (int frequency)
 Sets the PC speaker to emit a tone at the given FREQUENCY, in Hz. More...
 
void speaker_off (void)
 Turn off the PC speaker, by disconnecting the timer channel's output from the speaker. More...
 
void speaker_beep (void)
 devices/speaker.h More...
 

Function Documentation

◆ speaker_beep()

void speaker_beep ( void  )

devices/speaker.h

devices/speaker.h

Definition at line 48 of file speaker.c.

References intr_get_level(), INTR_ON, speaker_off(), speaker_on(), and timer_msleep().

Referenced by vga_putc().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ speaker_off()

void speaker_off ( void  )

Turn off the PC speaker, by disconnecting the timer channel's output from the speaker.

Definition at line 39 of file speaker.c.

References inb(), intr_disable(), intr_set_level(), outb(), SPEAKER_GATE_ENABLE, and SPEAKER_PORT_GATE.

Referenced by speaker_beep(), and speaker_on().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ speaker_on()

void speaker_on ( int  frequency)

Sets the PC speaker to emit a tone at the given FREQUENCY, in Hz.

Definition at line 16 of file speaker.c.

References inb(), intr_disable(), intr_set_level(), outb(), pit_configure_channel(), SPEAKER_GATE_ENABLE, speaker_off(), and SPEAKER_PORT_GATE.

Referenced by speaker_beep().

Here is the call graph for this function:
Here is the caller graph for this function: