* message having a given prespecified target message digest.
*
*
- *
* \version $Id$
* \author Daniele Basile <asterix@develer.com>
*/
#ifndef ALGO_MD2_H
#define ALGO_MD2_H
+#include <cfg/cfg_md2.h>
#include <cfg/compiler.h>
-#include <appconfig.h>
#define NUM_COMPUTE_ROUNDS 18 ///< Number of compute rounds.
#define COMPUTE_ARRAY_LEN CONFIG_MD2_BLOCK_LEN * 3 ///< Lenght of compute array.
* \author Daniele Basile <asterix@develer.com>
*/
-/*#*
- *#* $Log$
- *#* Revision 1.20 2007/06/07 16:06:39 batt
- *#* Fix some doxygen errors.
- *#*
- *#* Revision 1.19 2007/02/15 13:54:26 asterix
- *#* Rename randpool_getN in randpool_get. Fix bug in randpool_get.
- *#*
- *#* Revision 1.17 2007/02/15 13:40:42 asterix
- *#* Fix bug in randpool_add and randpool_strir.
- *#*
- *#* Revision 1.16 2007/02/13 15:11:37 asterix
- *#* Typo.
- *#*
- *#* Revision 1.14 2007/02/13 09:57:12 asterix
- *#* Add directive #if in struct EntropyPool, and remove #else in randpool_add.
- *#*
- *#* Revision 1.13 2007/02/12 18:25:34 asterix
- *#* Fix bug in randpool_getN.
- *#*
- *#* Revision 1.12 2007/02/12 09:47:39 asterix
- *#* Remove randpool_save. Add randpool_pool.
- *#*
- *#* Revision 1.10 2007/02/12 09:03:32 asterix
- *#* Add CONFIG_RANDPOOL_TIMER macro to swich on or off timer support
- *#*
- *#* Revision 1.9 2007/02/09 17:58:09 asterix
- *#* Add macro CONFIG_RANDPOOL_TIMER.
- *#*
- *#* Revision 1.6 2007/02/09 09:24:38 asterix
- *#* Typos. Add data_len in randpool_add and n_byte in randpool_push pototypes.
- *#*
- *#* Revision 1.3 2007/02/08 14:25:29 asterix
- *#* Write static funcion push_byte.
- *#*
- *#*/
-
#include "randpool.h"
#include "md2.h"
-#include <stdio.h> //sprintf();
-#include <string.h> //memset(), memcpy();
-
#include <cfg/compiler.h>
#include <cfg/debug.h> //ASSERT()
#include <cfg/macros.h> //MIN(), ROUND_UP();
+#include <stdio.h> //sprintf();
+#include <string.h> //memset(), memcpy();
+
#if CONFIG_RANDPOOL_TIMER
#include <drv/timer.h> //timer_clock();
#endif
#ifndef ALGO_RANDPOOL_H
#define ALGO_RANDPOOL_H
+#include <cfg/cfg_randpool.h>
#include <cfg/compiler.h>
-#include <appconfig.h>
/**
#define CPU_ATTR_H
#include "detect.h"
-#include <cfg/compiler.h> /* for uintXX_t */
-#include <cfg/arch_config.h> /* ARCH_EMUL */
-#include "appconfig.h" // CONFIG_FAST_MEM
+#include <cfg/cfg_attr.h> /* CONFIG_FAST_MEM */
+#include <cfg/compiler.h> /* for uintXX_t */
+#include <cfg/cfg_arch.h> /* ARCH_EMUL */
+
/**
* \name Macros for determining CPU endianness.
-/*!
+/**
* \file
* <!--
+ * This file is part of BeRTOS.
+ *
+ * Bertos 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 2 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.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ * As a special exception, you may use this file as part of a free software
+ * library without restriction. Specifically, if other files instantiate
+ * templates or use macros or inline functions from this file, or you compile
+ * this file and link it with other files to produce an executable, this
+ * file does not by itself cause the resulting executable to be covered by
+ * the GNU General Public License. This exception does not however
+ * invalidate any other reasons why the executable file might be covered by
+ * the GNU General Public License.
+ *
* Copyright 2007 Develer S.r.l. (http://www.develer.com/)
* -->
*
- * \version $Id$
- *
* \brief ADC hardware-specific definition
*
* \version $Id$
#include "adc_avr.h"
-#include <drv/adc.h>
-#include <appconfig.h>
-
+#include <cfg/cfg_adc.h>
+#include <cfg/cfg_kern.h>
#include <cfg/macros.h>
#include <cfg/compiler.h>
+#include <drv/adc.h>
+
#include <avr/io.h>
#include <avr/interrupt.h>
#if CONFIG_KERNEL
#include <cfg/module.h>
- #include <config_kern.h>
#include <kern/proc.h>
#include <kern/signal.h>
*
* -->
*
+ * \brief Low-level timer module for AVR (interface).
+ *
* \version $Id$
*
* \author Bernardo Innocenti <bernie@develer.com>
* \author Francesco Sacchi <batt@develer.com>
*
- * \brief Low-level timer module for AVR (interface).
*/
-/*#*
- *#* $Log$
- *#* Revision 1.32 2007/10/08 12:14:32 batt
- *#* Fix some review issues.
- *#*
- *#* Revision 1.31 2007/10/07 12:30:55 batt
- *#* Add default timer for AVR.
- *#*
- *#* Revision 1.30 2007/06/07 14:35:12 batt
- *#* Merge from project_ks.
- *#*
- *#* Revision 1.29 2007/03/21 11:01:36 batt
- *#* Add missing support for ATMega1281.
- *#*
- *#* Revision 1.28 2006/07/19 12:56:26 bernie
- *#* Convert to new Doxygen style.
- *#*
- *#* Revision 1.27 2006/05/18 00:38:24 bernie
- *#* Use hw_cpu.h instead of ubiquitous hw.h.
- *#*
- *#* Revision 1.26 2006/02/21 21:28:02 bernie
- *#* New time handling based on TIMER_TICKS_PER_SEC to support slow timers with ticks longer than 1ms.
- *#*
- *#* Revision 1.25 2005/07/19 07:26:37 bernie
- *#* Refactor to decouple timer ticks from milliseconds.
- *#*
- *#* Revision 1.24 2005/04/11 19:10:28 bernie
- *#* Include top-level headers from cfg/ subdir.
- *#*
- *#* Revision 1.23 2005/03/01 23:24:51 bernie
- *#* Tweaks for avr-libc 1.2.x.
- *#*
- *#* Revision 1.21 2004/12/13 12:07:06 bernie
- *#* DISABLE_IRQSAVE/ENABLE_IRQRESTORE: Convert to IRQ_SAVE_DISABLE/IRQ_RESTORE.
- *#*
- *#* Revision 1.20 2004/11/16 20:59:46 bernie
- *#* Include <avr/io.h> explicitly.
- *#*
- *#* Revision 1.19 2004/10/19 08:56:41 bernie
- *#* TIMER_STROBE_ON, TIMER_STROBE_OFF, TIMER_STROBE_INIT: Move from timer_avr.h to timer.h, where they really belong.
- *#*
- *#* Revision 1.18 2004/09/20 03:31:03 bernie
- *#* Fix racy racy code.
- *#*/
#ifndef DRV_TIMER_AVR_H
#define DRV_TIMER_AVR_H
-#include <appconfig.h> /* CONFIG_TIMER */
+#include "hw_cpu.h" /* CLOCK_FREQ */
+
+#include <cfg/cfg_timer.h> /* CONFIG_TIMER */
#include <cfg/compiler.h> /* uint8_t */
#include <cfg/macros.h> /* DIV_ROUND */
-#include <hw_cpu.h> /* CLOCK_FREQ */
+
/**
* \name Values for CONFIG_TIMER.
#include "eeprom.h"
+#include <cfg/cfg_eeprom.h> // CONFIG_EEPROM_VERIFY
#include <cfg/macros.h> // MIN()
#include <cfg/debug.h>
-#include <appconfig.h> // CONFIG_EEPROM_VERIFY
-
#include <cpu/attr.h>
#include CPU_HEADER(twi)
#ifndef DRV_EEPROM_H
#define DRV_EEPROM_H
+#include <cfg/cfg_eeprom.h>
#include <cfg/compiler.h>
-#include <appconfig.h>
/**
* \name Values for CONFIG_EEPROM_TYPE
*/
#include "hw_spi.h"
-#include <appconfig.h>
-
#include <cfg/macros.h>
#include <cfg/debug.h>
#ifndef DRV_FLASH25_H
#define DRV_FLASH25_H
-#include <kern/kfile.h>
#include <cfg/compiler.h>
+#include <cfg/cfg_flash25.h>
-
-#include <appconfig.h>
+#include <kern/kfile.h>
/**
* Type definition for serial flash memory.
*
*/
-#include <hw_kbd.h>
+#include "hw_kbd.h"
-#include <appconfig.h>
+#include <cfg/cfg_kbd.h>
+#include <cfg/debug.h>
+#include <cfg/module.h>
#include <drv/timer.h>
#include <drv/kbd.h>
-#include <cfg/debug.h>
-#include <cfg/module.h>
/* Configuration sanity checks */
-#if !defined(CONFIG_KBD_POLL) || (CONFIG_KBD_POLL != KBD_POLL_SOFTINT && CONFIG_KBD_POLL != CONFIG_POLL_FREERTOS)
- #error CONFIG_KBD_POLL must be defined to either KBD_POLL_SOFTINT or CONFIG_POLL_FREERTOS
+#if !defined(CONFIG_KBD_POLL) || (CONFIG_KBD_POLL != KBD_POLL_SOFTINT)
+ #error CONFIG_KBD_POLL must be defined to either KBD_POLL_SOFTINT
#endif
#if !defined(CONFIG_KBD_BEEP) || (CONFIG_KBD_BEEP != 0 && CONFIG_KBD_BEEP != 1)
#error CONFIG_KBD_BEEP must be defined to either 0 or 1
timer_add(&kbd_timer);
}
-#elif CONFIG_KBD_POLL == CONFIG_POLL_FREERTOS
-
-#include "FreeRTOS.h"
-#include "task.h"
-
-static portTASK_FUNCTION(kbd_task, arg)
-{
- for (;;)
- {
- kbd_poll();
- timer_delay(KBD_CHECK_INTERVAL);
- }
-}
+#else
+ #error "Define keyboard poll method"
#endif /* CONFIG_KBD_POLL */
timer_setDelay(&kbd_timer, ms_to_ticks(KBD_CHECK_INTERVAL));
timer_add(&kbd_timer);
-#elif CONFIG_KBD_POLL == CONFIG_POLL_FREERTOS
-
- /* Create a timer specific thread */
- xTaskCreate(kbd_task, "kbd", CONFIG_STACK_KBD,
- NULL, CONFIG_PRI_KBD, NULL);
-
#else
#error "Define keyboard poll method"
+
#endif
MOD_INIT(kbd);
#ifndef DRV_KBD_H
#define DRV_KBD_H
-#include <kbd_map.h>
+#include "kbd_map.h"
+
+#include <cfg/cfg_kbd.h> // CONFIG_KBD_OBSERVER
#include <cfg/compiler.h>
+
#include <mware/list.h>
-#include <appconfig.h> // CONFIG_KBD_OBSERVER
/**
* \name Keyboard polling modes.
* \{
*/
#define KBD_POLL_SOFTINT 1
-#define KBD_POLL_FREERTOS 2
/* \} */
/**
#include "hw_lcd.h"
-#include <cfg/arch_config.h>
+#include <cfg/cfg_arch.h>
#include <drv/lcd_hd44.h>
#include <drv/timer.h>
#ifndef DRV_LCD_HD44_H
#define DRV_LCD_HD44_H
-#include <appconfig.h>
+#include <cfg/cfg_lcd.h>
#include <cfg/compiler.h> /* For stdint types */
/**
#include CPU_HEADER(ser)
#endif
-#include <appconfig.h>
+#include <cfg/cfg_ser.h>
#include "hw_stepper.h"
#include "hw_sensor.h"
-#include "appconfig.h"
-
+#include <cfg/cfg_stepper.h>
#include <cfg/debug.h>
#include <kern/proc.h>
#include <algo/ramp.h>
+
#include <drv/stepper_at91.h>
#include <string.h> // memset
#define DRV_STEPPER_H
#include <cfg/compiler.h>
+
#include <algo/ramp.h>
// Forward declaration
*
* -->
*
+ * \brief Hardware independent timer driver (interface)
+ *
* \version $Id$
*
* \author Bernardo Innocenti <bernie@develer.com>
*
- * \brief Hardware independent timer driver (interface)
*/
#ifndef DRV_TIMER_H
#include <cfg/os.h>
#include <cfg/macros.h>
+
#include <cpu/attr.h>
#include <cpu/irq.h>
#include CPU_HEADER(timer)
#endif
-#include <mware/list.h>
+#include <cfg/cfg_timer.h>
#include <cfg/debug.h>
#include <cfg/compiler.h>
-#include <appconfig.h>
+
+#include <mware/list.h>
extern volatile ticks_t _clock;
#ifndef DRV_WDT_H
#define DRV_WDT_H
-#include <appconfig.h>
+#include <cfg/cfg_wdt.h>
#include <cfg/compiler.h> // INLINE
-#include <cfg/arch_config.h>
+#include <cfg/cfg_arch.h>
/* Configury sanity check */
#if !defined(CONFIG_WATCHDOG) || (CONFIG_WATCHDOG != 0 && CONFIG_WATCHDOG != 1)
#ifndef HW_LCD_H
#define HW_LCD_H
-#include <appconfig.h>
-
-#include <cfg/macros.h> /* BV() */
+#include <cfg/cfg_lcd.h> /* CONFIG_LCD_4BIT */
+#include <cfg/macros.h> /* BV() */
#include <cfg/debug.h>
#include <cpu/attr.h>
#ifndef KERN_PROC_H
#define KERN_PROC_H
+#include <cfg/cfg_kern.h>
#include <cfg/compiler.h>
+
#include <cpu/irq.h>
-#include <config_kern.h>
/* Fwd decl */
struct Process;
#define KERN_EVENT_H
#include <cfg/compiler.h>
-#include <appconfig.h>
+#include <cfg/cfg_kern.h>
#if CONFIG_KERNEL
- #include <config_kern.h>
#if defined(CONFIG_KERN_SIGNALS) && CONFIG_KERN_SIGNALS
#include <kern/signal.h>
#endif
#ifndef NET_POCKETBUS_H
#define NET_POCKETBUS_H
-#include "appconfig.h" //for CONFIG_POCKETBUS_BUFLEN
+#include <cfg/cfg_pocketbus.h> /* for CONFIG_POCKETBUS_BUFLEN */
#include <cfg/compiler.h>
#include <algo/rotating_hash.h>
#include "xmodem.h"
-#include <appconfig.h>
-#include <string.h> /* for memset() */
-#include <drv/ser.h>
-#include <algo/crc.h>
#include <cfg/debug.h>
+#include <cfg/cfg_xmodem.h>
+#include <drv/ser.h>
+#include <algo/crc.h>
+#include <string.h> /* for memset() */
/**
* \name Protocol control codes