Rebase changes on upstream master

This brings in many of the changes from the PX4 fork on ATLFLight.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
This commit is contained in:
Mark Charlebois
2016-02-19 16:59:43 +01:00
committed by Julian Oes
parent 2938d23c6c
commit 014f15d8b0
28 changed files with 254 additions and 172 deletions
@@ -60,6 +60,11 @@ long PX4_TICKS_PER_SEC = sysconf(_SC_CLK_TCK);
#ifdef ENABLE_SHMEM
extern void init_params(void);
#ifdef ENABLE_SHMEM
extern void init_own_params(void);
extern unsigned int init_other_params(void);
extern unsigned int param_sync_done;
#endif
__END_DECLS
@@ -78,8 +83,9 @@ void init_once(void)
hrt_init();
#ifdef ENABLE_SHMEM
PX4_INFO("Syncing params to shared memory\n");
init_params();
PX4_INFO("Starting shared memory param sync\n");
init_own_params();
param_sync_done=init_other_params();
#endif
}
+6 -3
View File
@@ -1,6 +1,7 @@
/****************************************************************************
*
* Copyright (c) 2015 Vijay Venkatraman. All rights reserved.
* Copyright (c) 2015 Ramakrishna Kintada. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -31,6 +32,7 @@
*
****************************************************************************/
#include <px4_defines.h>
#include <px4_posix.h>
#include <string.h>
@@ -56,8 +58,8 @@
int mem_fd;
unsigned char *map_base, *virt_addr;
struct shmem_info *shmem_info_p;
static void *map_memory(off_t target);
struct shmem_info* shmem_info_p;
static void* map_memory(off_t target);
int get_shmem_lock(void);
void release_shmem_lock(void);
@@ -236,6 +238,7 @@ static void update_index_from_shmem(void)
release_shmem_lock();
}
static void update_value_from_shmem(param_t param, union param_value_u *value)
{
unsigned int byte_changed, bit_changed;