TacOS  0.2
 Tout Structures de données Fichiers Fonctions Variables Définitions de type Énumérations Macros
Macros | Fonctions
Référence du fichier serial.c
#include <interrupts.h>
#include <ioports.h>
#include <drivers/serial.h>
#include <klog.h>
#include <ksem.h>
#include <kfcntl.h>
#include <kmalloc.h>
#include <tty.h>
#include <klibc/string.h>
#include "serial_masks.h"
Graphe des dépendances par inclusion de serial.c:

Macros

#define RX_BUFFER_SIZE   256
 
#define TX_BUFFER_SIZE   256
 
#define TX_FIFO_SIZE   16 /* D'après la datasheet du PC1550D, pas évident que ce soit le bon model */
 
#define UART_CLOCK_FREQ   115200
 
#define DATA   0
 
#define DL_LSB   0
 
#define INTERRUPT_ENABLE   1
 
#define DL_MSB   1
 
#define INTERRUPT_ID_REG   2
 
#define FIFO_CTRL   2
 
#define LINE_CTRL   3
 
#define MODEM_CTRL   4
 
#define LINE_STATUS   5
 
#define MODEM_STATUS   6
 
#define SCRATCH   7
 
#define write_register(PORT, REG, DATA)   outb(DATA,base_addr[PORT]+REG)
 
#define read_register(PORT, REG)   inb(base_addr[PORT]+REG)
 
#define TX_BUFFER_FULL(port)   ((tx_size[port] == TX_BUFFER_SIZE-1)?1:0)
 

Fonctions

void serial_isr (int id)
 Handler d'interruption du driver série.
 
int serial_init ()
 Fonction d'initialisation du driver série.
 

Description détaillée

Auteur
TacOS developers

LICENSE

Copyright (C) 2010-2014 TacOS developers.

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details at http://www.gnu.org/copyleft/gpl.html

You should have received a copy of the GNU General Public License along with this program; if not, see http://www.gnu.org/licenses.

DESCRIPTION

Serial communication driver