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

PiOS.win32: Various fixes to get it working again, added a sim_win32 option to the main makefile.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2249 ebee16cc-31ac-478f-84a7-5cbb03baadba
This commit is contained in:
cwabbott 2010-12-18 18:41:37 +00:00 committed by cwabbott
parent e84b222272
commit 0b985b2168
4 changed files with 18 additions and 2 deletions

View File

@ -44,6 +44,9 @@ areyousureyoushouldberunningthis:
@echo " sim_posix - Build OpenPilot simulation firmware for"
@echo " a POSIX compatible system (Linux, Mac OS X, ...)"
@echo " sim_posix_clean - Delete all build output for the POSIX simulation"
@echo " sim_win32 - Build OpenPilot simulation firmware for"
@echo " Windows using mingw and msys"
@echo " sim_win32_clean - Delete all build output for the win32 simulation"
@echo
@echo " [GCS and UAVObjects]"
@echo " gcs - Build the Ground Control System application"
@ -235,3 +238,9 @@ sim_posix_%: uavobjects
mkdir -p $(BUILD_DIR)/simulation
$(MAKE) OUTDIR="$(BUILD_DIR)/simulation" -C $(ROOT_DIR)/flight/OpenPilot --file=$(ROOT_DIR)/flight/OpenPilot/Makefile.posix $*
.PHONY: sim_win32
sim_win32: sim_win32_exe
sim_win32_%: #uavobjects
mkdir -p $(BUILD_DIR)/simulation
$(MAKE) OUTDIR="$(BUILD_DIR)/simulation" -C $(ROOT_DIR)/flight/OpenPilot --file=$(ROOT_DIR)/flight/OpenPilot/Makefile.win32 $*

View File

@ -145,6 +145,7 @@ SRC += $(OPUAVOBJ)/manualcontrolsettings.c
SRC += $(OPUAVOBJ)/attitudedesired.c
SRC += $(OPUAVOBJ)/stabilizationsettings.c
SRC += $(OPUAVOBJ)/ahrsstatus.c
SRC += $(OPUAVOBJ)/i2cstats.c
SRC += $(OPUAVOBJ)/baroaltitude.c
SRC += $(OPUAVOBJ)/ahrscalibration.c
SRC += $(OPUAVOBJ)/attitudeactual.c
@ -160,6 +161,8 @@ SRC += $(OPUAVOBJ)/velocityactual.c
SRC += $(OPUAVOBJ)/guidancesettings.c
SRC += $(OPUAVOBJ)/firmwareiapobj.c
SRC += $(OPUAVOBJ)/ratedesired.c
SRC += $(OPUAVOBJ)/pipxtrememodemsettings.c
SRC += $(OPUAVOBJ)/pipxtrememodemstatus.c
endif
## PIOS Hardware (win32)

View File

@ -205,6 +205,9 @@ static void objectUpdatedCb(UAVObjEvent * ev)
/**
* Called periodically to update the I2C statistics
*/
#if defined(ARCH_POSIX) || defined(ARCH_WIN32)
static void updateI2Cstats() {}
#else
static void updateI2Cstats()
{
I2CStatsData i2cStats;
@ -220,6 +223,7 @@ static void updateI2Cstats()
i2cStats.last_error_type = history.type;
I2CStatsSet(&i2cStats);
}
#endif
/**
* Called periodically to update the system stats

View File

@ -252,7 +252,7 @@ static DWORD WINAPI tick_generator(LPVOID lpParameter)
if(SignalObjectAndWait(hIsrMutex, hTickAck, 2000, FALSE) == WAIT_TIMEOUT)
{
printf("Tick generator: timed out at SignalObjectAndWait\n");
return 0;
exit(1);
}
}
}
@ -356,7 +356,7 @@ portBASE_TYPE xPortStartScheduler( void )
if(WaitForMultipleObjects(2, hObjList, TRUE, 2000) == WAIT_TIMEOUT)
{
printf("vPortStartScheduler: timed out at WaitForMultipleObjects\n");
return 0;
exit(1);
}
psSim=(SSIM_T *)*pxCurrentTCB;