11.3Schristos/* $NetBSD: putchar.c,v 1.3 2014/02/24 22:31:56 christos Exp $ */ 21.1Spooka 31.1Spooka/*- 41.1Spooka * Copyright (c) 2010 The NetBSD Foundation, Inc. 51.1Spooka * All rights reserved. 61.1Spooka * 71.1Spooka * This code was written by Alessandro Forin and Neil Pittman 81.1Spooka * at Microsoft Research and contributed to The NetBSD Foundation 91.1Spooka * by Microsoft Corporation. 101.1Spooka * 111.1Spooka * Redistribution and use in source and binary forms, with or without 121.1Spooka * modification, are permitted provided that the following conditions 131.1Spooka * are met: 141.1Spooka * 1. Redistributions of source code must retain the above copyright 151.1Spooka * notice, this list of conditions and the following disclaimer. 161.1Spooka * 2. Redistributions in binary form must reproduce the above copyright 171.1Spooka * notice, this list of conditions and the following disclaimer in the 181.1Spooka * documentation and/or other materials provided with the distribution. 191.1Spooka * 201.1Spooka * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS 211.1Spooka * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED 221.1Spooka * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 231.1Spooka * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS 241.1Spooka * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 251.1Spooka * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 261.1Spooka * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 271.1Spooka * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 281.1Spooka * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 291.1Spooka * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 301.1Spooka * POSSIBILITY OF SUCH DAMAGE. 311.1Spooka */ 321.1Spooka 331.1Spooka#include <sys/types.h> 341.2Smartin#include "start.h" 351.2Smartin#include "common.h" 361.2Smartin 371.1Spooka/* Write a character to the USART 381.1Spooka */ 391.1Spookavoid 401.1Spookaputchar(int ch) 411.1Spooka{ 421.1Spooka PutChar((uint8_t)ch); 431.1Spooka} 441.1Spooka 45