Skip to content
Snippets Groups Projects
Commit 9ffeecdf authored by Andrew Tridgell's avatar Andrew Tridgell
Browse files

APM: fixed some compiler warnings

parent 63ca982f
No related branches found
No related tags found
No related merge requests found
......@@ -43,7 +43,7 @@ static void reload_commands_airstart()
static struct Location get_cmd_with_index(int16_t i)
{
struct Location temp;
int32_t mem;
uint16_t mem;
// Find out proper location in memory by using the start_byte position + the index
// --------------------------------------------------------------------------------
......@@ -53,22 +53,22 @@ static struct Location get_cmd_with_index(int16_t i)
}else{
// read WP position
mem = (WP_START_BYTE) + (i * WP_SIZE);
temp.id = eeprom_read_byte((uint8_t*)mem);
temp.id = eeprom_read_byte((uint8_t*)(uintptr_t)mem);
mem++;
temp.options = eeprom_read_byte((uint8_t*)mem);
temp.options = eeprom_read_byte((uint8_t*)(uintptr_t)mem);
mem++;
temp.p1 = eeprom_read_byte((uint8_t*)mem);
temp.p1 = eeprom_read_byte((uint8_t*)(uintptr_t)mem);
mem++;
temp.alt = (long)eeprom_read_dword((uint32_t*)mem);
temp.alt = (long)eeprom_read_dword((uint32_t*)(uintptr_t)mem);
mem += 4;
temp.lat = (long)eeprom_read_dword((uint32_t*)mem);
temp.lat = (long)eeprom_read_dword((uint32_t*)(uintptr_t)mem);
mem += 4;
temp.lng = (long)eeprom_read_dword((uint32_t*)mem);
temp.lng = (long)eeprom_read_dword((uint32_t*)(uintptr_t)mem);
}
// Add on home altitude if we are a nav command (or other command with altitude) and stored alt is relative
......
......@@ -120,15 +120,6 @@ static void process_next_command()
}
}
/**************************************************/
// These functions implement the commands.
/**************************************************/
static void process_nav_cmd()
{
//gcs_send_text_P(SEVERITY_LOW,PSTR("New nav command loaded"));
handle_process_nav_cmd();
}
static void process_non_nav_command()
{
//gcs_send_text_P(SEVERITY_LOW,PSTR("new non-nav command loaded"));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment