Fork of Smoothie to port to mbed non-LPC targets.

Dependencies:   mbed

Fork of Smoothie by Stéphane Cachat

Committer:
Michael J. Spencer
Date:
Fri Feb 28 18:52:52 2014 -0800
Revision:
2:1df0b61d3b5a
Update to latest Smoothie.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
Michael J. Spencer 2:1df0b61d3b5a 1 /*
Michael J. Spencer 2:1df0b61d3b5a 2 * Copyright (c) 2006, Swedish Institute of Computer Science.
Michael J. Spencer 2:1df0b61d3b5a 3 * All rights reserved.
Michael J. Spencer 2:1df0b61d3b5a 4 *
Michael J. Spencer 2:1df0b61d3b5a 5 * Redistribution and use in source and binary forms, with or without
Michael J. Spencer 2:1df0b61d3b5a 6 * modification, are permitted provided that the following conditions
Michael J. Spencer 2:1df0b61d3b5a 7 * are met:
Michael J. Spencer 2:1df0b61d3b5a 8 * 1. Redistributions of source code must retain the above copyright
Michael J. Spencer 2:1df0b61d3b5a 9 * notice, this list of conditions and the following disclaimer.
Michael J. Spencer 2:1df0b61d3b5a 10 * 2. Redistributions in binary form must reproduce the above copyright
Michael J. Spencer 2:1df0b61d3b5a 11 * notice, this list of conditions and the following disclaimer in the
Michael J. Spencer 2:1df0b61d3b5a 12 * documentation and/or other materials provided with the distribution.
Michael J. Spencer 2:1df0b61d3b5a 13 * 3. Neither the name of the Institute nor the names of its contributors
Michael J. Spencer 2:1df0b61d3b5a 14 * may be used to endorse or promote products derived from this software
Michael J. Spencer 2:1df0b61d3b5a 15 * without specific prior written permission.
Michael J. Spencer 2:1df0b61d3b5a 16 *
Michael J. Spencer 2:1df0b61d3b5a 17 * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
Michael J. Spencer 2:1df0b61d3b5a 18 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
Michael J. Spencer 2:1df0b61d3b5a 19 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
Michael J. Spencer 2:1df0b61d3b5a 20 * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE
Michael J. Spencer 2:1df0b61d3b5a 21 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
Michael J. Spencer 2:1df0b61d3b5a 22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
Michael J. Spencer 2:1df0b61d3b5a 23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
Michael J. Spencer 2:1df0b61d3b5a 24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
Michael J. Spencer 2:1df0b61d3b5a 25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
Michael J. Spencer 2:1df0b61d3b5a 26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
Michael J. Spencer 2:1df0b61d3b5a 27 * SUCH DAMAGE.
Michael J. Spencer 2:1df0b61d3b5a 28 *
Michael J. Spencer 2:1df0b61d3b5a 29 * This file is part of the uIP TCP/IP stack
Michael J. Spencer 2:1df0b61d3b5a 30 *
Michael J. Spencer 2:1df0b61d3b5a 31 * $Id: clock-arch.c,v 1.2 2006/06/12 08:00:31 adam Exp $
Michael J. Spencer 2:1df0b61d3b5a 32 */
Michael J. Spencer 2:1df0b61d3b5a 33
Michael J. Spencer 2:1df0b61d3b5a 34 /**
Michael J. Spencer 2:1df0b61d3b5a 35 * \file
Michael J. Spencer 2:1df0b61d3b5a 36 * Implementation of architecture-specific clock functionality
Michael J. Spencer 2:1df0b61d3b5a 37 * \author
Michael J. Spencer 2:1df0b61d3b5a 38 * Adam Dunkels <adam@sics.se>
Michael J. Spencer 2:1df0b61d3b5a 39 */
Michael J. Spencer 2:1df0b61d3b5a 40
Michael J. Spencer 2:1df0b61d3b5a 41 #include "clock-arch.h"
Michael J. Spencer 2:1df0b61d3b5a 42 static clock_time_t Ticks;
Michael J. Spencer 2:1df0b61d3b5a 43
Michael J. Spencer 2:1df0b61d3b5a 44 void do_tick() {
Michael J. Spencer 2:1df0b61d3b5a 45 Ticks++;
Michael J. Spencer 2:1df0b61d3b5a 46 }
Michael J. Spencer 2:1df0b61d3b5a 47
Michael J. Spencer 2:1df0b61d3b5a 48 /*---------------------------------------------------------------------------*/
Michael J. Spencer 2:1df0b61d3b5a 49 clock_time_t clock_time(void)
Michael J. Spencer 2:1df0b61d3b5a 50 {
Michael J. Spencer 2:1df0b61d3b5a 51 return Ticks;
Michael J. Spencer 2:1df0b61d3b5a 52 }
Michael J. Spencer 2:1df0b61d3b5a 53 /*---------------------------------------------------------------------------*/