1
0
mirror of https://bitbucket.org/librepilot/librepilot.git synced 2024-12-01 09:24:10 +01:00

Removed GPIO function from piso_sys, each module does their own GPIO setup.

pios_config.h to inc directory. 


git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@66 ebee16cc-31ac-478f-84a7-5cbb03baadba
This commit is contained in:
dankers 2009-12-15 12:17:11 +00:00 committed by dankers
parent ebcec5533f
commit 3117c9ac45
5 changed files with 8 additions and 49 deletions

View File

@ -35,7 +35,7 @@
/** /**
* Main function * OpenPilot Main function
*/ */
void OpenPilotInit(void) void OpenPilotInit(void)
{ {
@ -53,7 +53,7 @@ void OpenPilotInit(void)
-> MicroSD: Simply logs data to the MicroSD card -> MicroSD: Simply logs data to the MicroSD card
-> Telemetry: Sends telemetry using a queue -> Telemetry: Sends telemetry using a queue
- Supervisor should have highest possibly priority (Idle + 14?) - Supervisor should have highest possibly priority (Idle + 14) We only have 5 task levels, as long as it yeilds that is fine.
- Supervisor should also act as the warnings system, low batter etc) - Supervisor should also act as the warnings system, low batter etc)
- Supervisor should handle all telemetry inputs (not outputs), and act accordingly - Supervisor should handle all telemetry inputs (not outputs), and act accordingly
- ARC and HARC tasks should be split into two parts, gathering sensor data and acting on sensor data. - ARC and HARC tasks should be split into two parts, gathering sensor data and acting on sensor data.

View File

@ -47,7 +47,7 @@ void PIOS_SYS_Init(void)
/* Setup STM32 system (RCC, clock, PLL and Flash configuration) - CMSIS Function */ /* Setup STM32 system (RCC, clock, PLL and Flash configuration) - CMSIS Function */
SystemInit(); SystemInit();
/* Initialize NVIC */ /* Initialize Basic NVIC */
NVIC_Configuration(); NVIC_Configuration();
/* Initialize LEDs */ /* Initialize LEDs */
@ -69,15 +69,6 @@ void PIOS_SYS_Init(void)
} }
/**
* Configures base level GPIO ports.
*/
void GPIO_Configuration(void)
{
}
/** /**
* Configures Vector Table base location and SysTick * Configures Vector Table base location and SysTick
*/ */

View File

@ -3,8 +3,8 @@
* *
* @file pios_config.h * @file pios_config.h
* @author The OpenPilot Team, http://www.openpilot.org Copyright (C) 2009. * @author The OpenPilot Team, http://www.openpilot.org Copyright (C) 2009.
* @brief Main configuration header. * @brief PiOS configuration header.
* - Compile time configuration the project. * - Central compile time config for the project.
* @see The GNU Public License (GPL) Version 3 * @see The GNU Public License (GPL) Version 3
* *
*****************************************************************************/ *****************************************************************************/

View File

@ -59,7 +59,7 @@ int main()
/* Initialise OpenPilot */ /* Initialise OpenPilot */
OpenPilotInit(); OpenPilotInit();
/* *tart the task which calls the application hooks */ /* Start the task which calls the application hooks */
xTaskCreate(HooksTask, (signed portCHAR *)"Hooks", configMINIMAL_STACK_SIZE, NULL, PRIORITY_TASK_HOOKS, NULL); xTaskCreate(HooksTask, (signed portCHAR *)"Hooks", configMINIMAL_STACK_SIZE, NULL, PRIORITY_TASK_HOOKS, NULL);
/* Start the scheduler */ /* Start the scheduler */
@ -102,6 +102,7 @@ static void HooksTask(void *pvParameters)
void vApplicationIdleHook(void) void vApplicationIdleHook(void)
{ {
/* Called when the scheduler has no tasks to run */ /* Called when the scheduler has no tasks to run */
/* In here we could implement full stats for FreeRTOS /* In here we could implement full stats for FreeRTOS
Although this would need us to enable stats in FreeRTOS Although this would need us to enable stats in FreeRTOS
which is *very* costly. With the function below we can which is *very* costly. With the function below we can
@ -113,3 +114,4 @@ void vApplicationIdleHook(void)
ulIdleCycleCount++; ulIdleCycleCount++;
IdleTimePercent = ((ulIdleCycleCount / xTaskGetTickCount()) * 100); IdleTimePercent = ((ulIdleCycleCount / xTaskGetTickCount()) * 100);
} }

View File

@ -1,34 +0,0 @@
/**
******************************************************************************
*
* @file pios_config.h
* @author The OpenPilot Team, http://www.openpilot.org Copyright (C) 2009.
* @brief PiOS configuration header.
* - Central compile time config for the project.
* @see The GNU Public License (GPL) Version 3
*
*****************************************************************************/
/*
* 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.
*
* 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.,
* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifndef PIOS_CONFIG_H
#define PIOS_CONFIG_H
#endif /* PIOS_CONFIG_H */