/* Copyright (c) 2001-2009 by SoftIntegration, Inc. All Rights Reserved */
/* a sample program that sets up Baud rate
first then displays the speed. */
#include <stdlib.h>
#include <termios.h>

int main() {
    struct termios termios_p;
    speed_t speed;
    int x;
 
    speed = B1200;   /* set up 1200 Baud */
    cfsetispeed(&termios_p,speed);
    speed = cfgetispeed(&termios_p);
    printf("%d\n",speed);
}
