like debian are already pulled
git log > ChangeLog
- git commit -a
- git tag -a <version> # full x.y.z version
+ git commit -a -m'update ChangeLog for <version> release'
+ git tag -a <version> -m'Releasing <version>' # full x.y.z version
- make sure .git/gbp.conf set to use branch-<version> as upstream
return easy_mini_2_adc(sensor) * supply * 127/27;
}
+ static double easy_mini_3_voltage(int sensor) {
+ return easy_mini_1_voltage(sensor, 10000);
+ }
+
static double motor_pressure(double voltage) {
double base = 0.5;
double max = 4.5;
static final int idle_sensor_tmini3 = 109;
static final int idle_sensor_easytimer1 = 110;
static final int idle_sensor_easymotor2 = 111;
+ static final int idle_sensor_emini3 = 112;
public void provide_data(AltosDataListener listener, AltosLink link) throws InterruptedException, TimeoutException, AltosUnknownProduct {
for (int idler : idlers) {
case idle_sensor_emini2:
AltosSensorEMini.provide_data(listener, link, 2);
break;
+ case idle_sensor_emini3:
+ AltosSensorEMini.provide_data(listener, link, 3);
+ break;
case idle_sensor_tmini2:
AltosSensorTMini2.provide_data(listener, link);
break;
AltosIdler.idle_ms5607,
AltosIdler.idle_sensor_emini2),
+ new AltosIdler("EasyMini-v3",
+ AltosIdler.idle_ms5607,
+ AltosIdler.idle_sensor_emini3),
+
new AltosIdler("TeleMini-v1",
AltosIdler.idle_sensor_tm),
listener.set_apogee_voltage(AltosConvert.easy_mini_2_voltage(sensor_emini.apogee));
listener.set_main_voltage(AltosConvert.easy_mini_2_voltage(sensor_emini.main));
break;
+ case 3:
+ listener.set_battery_voltage(AltosConvert.easy_mini_3_voltage(sensor_emini.batt));
+ listener.set_apogee_voltage(AltosConvert.easy_mini_3_voltage(sensor_emini.apogee));
+ listener.set_main_voltage(AltosConvert.easy_mini_3_voltage(sensor_emini.main));
+ break;
}
} catch (TimeoutException te) {
Adjust existing telemetry decoders for new sensors
+ 9. AltosConvert.java
+
+ Add conversion functions for ADC values
+
altosuilib/
1. AltosUSBDevice.java
exit 1
esac
- echo "$PRODUCT-v$VERSION" serial "$serial" passed functional tests
+ echo "$PRODUCT-v$VERSION" serial "$serial" is ready to ship
+ echo "\007"
ret=0
;;
*)
;;
esac
-SERIAL=$SERIAL ./cal-freq $dev
+CALFILE=cal-$SERIAL.txt
+../ao-tools/ao-cal-freq/ao-cal-freq --output=$CALFILE --tty=$dev
+CAL_VALUE=`cat $CALFILE`
+echo $SERIAL","$CAL_VALUE >> cal_values
./test-telegps-v3
return 0;
}
}
- if (strcmp(this->status, "ready") != 0) {
+ if (strcmp(this->status, "open") == 0) {
printf("igniter %s status is %s\n", this->name, this->status);
free_igniters(all);
return 0;
dnl Process this file with autoconf to create configure.
AC_PREREQ(2.57)
-AC_INIT([altos], 1.9.16)
+AC_INIT([altos], 1.9.17)
ANDROID_VERSION=37
AC_CONFIG_SRCDIR([src/kernel/ao.h])
AM_INIT_AUTOMAKE([foreign dist-bzip2])
AM_MAINTAINER_MODE
-RELEASE_DATE=2023-04-27
+RELEASE_DATE=2023-08-30
AC_SUBST(RELEASE_DATE)
DOC_DATE=`LC_ALL=C date -d $RELEASE_DATE +'%d %b %Y'`
endif
RELNOTES_INC=\
+ release-notes-1.9.17.inc \
release-notes-1.9.16.inc \
release-notes-1.9.15.inc \
release-notes-1.9.14.inc \
--- /dev/null
+= Release Notes for Version 1.9.17
+include::release-head.adoc[]
+:doctype: article
+
+ Version 1.9.17
+
+ == AltOS
+
+ * Fix TeleMini v3 Monitor Idle support
+
+ * Support TeleMetrum v4.0 with uBlox-10 GPS module
+
+ * Improve igniter reporting via the beeper.
+
+ == AltosUI & TeleGPS application
+
+ * Add support for EasyMini v3 Monitor Idle
+
\ No newline at end of file
[appendix]
== Release Notes
+ :leveloffset: 2
+ include::release-notes-1.9.17.adoc[]
+
+ <<<<
:leveloffset: 2
include::release-notes-1.9.16.adoc[]
|TeleMetrum v4.0
|MS5607 30km (100k')
|ADXL375 200g
- |uBlox Max-8C
+ |uBlox Max-8C/10S
|-
|8MB
|40mW
defaults_DATA=altos-mapd-default
-systemddir=$(libdir)/systemd/system
+systemddir=$(bindir)/../lib/systemd/system
systemd_DATA=altos-mapd.service
#define AO_BATTERY_DIV_PLUS 56 /* 5.6k */
#define AO_BATTERY_DIV_MINUS 100 /* 10k */
+/*
+ * Voltage divider on ADC pyro battery sampler
+ */
+#define AO_PYRO_BATTERY_DIV_PLUS 100 /* 100k */
+#define AO_PYRO_BATTERY_DIV_MINUS 27 /* 27k */
+
/*
* Voltage divider on ADC igniter samplers
*/
#define AO_BATTERY_DIV_PLUS 56 /* 5.6k */
#define AO_BATTERY_DIV_MINUS 100 /* 10k */
+/*
+ * Voltage divider on ADC pyro battery sampler
+ */
+#define AO_PYRO_BATTERY_DIV_PLUS 100 /* 100k */
+#define AO_PYRO_BATTERY_DIV_MINUS 27 /* 27k */
+
/*
* Voltage divider on ADC igniter samplers
*/
#define AO_BATTERY_DIV_PLUS 56 /* 5.6k */
#define AO_BATTERY_DIV_MINUS 100 /* 10k */
+/*
+ * Voltage divider on ADC pyro battery sampler
+ */
+#define AO_PYRO_BATTERY_DIV_PLUS 100 /* 100k */
+#define AO_PYRO_BATTERY_DIV_MINUS 27 /* 27k */
+
/*
* Voltage divider on ADC igniter samplers
*/
#define HAS_BEEP 1
#define HAS_BATTERY_REPORT 1
-#define AO_STACK_SIZE 448
+#define AO_STACK_SIZE 432
#define IS_FLASH_LOADER 0
#ifndef _AO_CONFIG_H_
#define _AO_CONFIG_H_
+#include <ao.h>
+
+#if AO_PYRO_NUM
#include <ao_pyro.h>
+#endif
#ifndef USE_STORAGE_CONFIG
#define USE_STORAGE_CONFIG 1
#include "ao.h"
#define MUL(p,m) ((int32_t) AO_ADC_REFERENCE_DV * ((p) + (m)))
-#define ADD(p,m) (MUL(p,m)/2)
#define DIV(p,m) ((int32_t) AO_ADC_MAX * (m))
+#define ADD(p,m) (DIV(p,m) / 2)
#define scale(v,p,m) (((int32_t) (v) * MUL(p,m) + ADD(p,m)) / DIV(p,m))
#if HAS_APRS || HAS_BATTERY_REPORT
#include "ao.h"
#include <ao_data.h>
-#if AO_PYRO_NUM
#include <ao_pyro.h>
-#endif
#if HAS_IGNITE
struct ao_ignition ao_ignition[2];
value = AO_SENSE_MAIN(&packet);
break;
}
- if (value < AO_IGNITER_OPEN)
- return ao_igniter_open;
- else if (value > AO_IGNITER_CLOSED)
- return ao_igniter_ready;
- else
- return ao_igniter_unknown;
+ return ao_igniter_check(value, AO_SENSE_PBATT(&packet));
}
#define AO_IGNITER_SET_DROGUE(v) ao_gpio_set(AO_IGNITER_DROGUE_PORT, AO_IGNITER_DROGUE_PIN, v)
ao_data_get(&packet);
);
- value = (AO_IGNITER_CLOSED>>1);
value = AO_SENSE_PYRO(&packet, p);
- if (value < AO_IGNITER_OPEN)
- return ao_igniter_open;
- else if (value > AO_IGNITER_CLOSED)
- return ao_igniter_ready;
- else
- return ao_igniter_unknown;
+ return ao_igniter_check(value, AO_SENSE_PBATT(&packet));
}
void
void
ao_pyro_print_status(void);
+#ifndef AO_PYRO_BATTERY_DIV_PLUS
+#define AO_PYRO_BATTERY_DIV_PLUS AO_BATTERY_DIV_PLUS
+#define AO_PYRO_BATTERY_DIV_MINUS AO_BATTERY_DIV_MINUS
+#ifndef AO_SENSE_PBATT
+#define AO_SENSE_PBATT(p) ((p)->adc.v_batt)
+#endif
+#else
+#ifndef AO_SENSE_PBATT
+#define AO_SENSE_PBATT(p) ((p)->adc.v_pbatt)
+#endif
+#endif
+
+/*
+ * dv = (sensor * (p+m) * ref_dv)/ (max * m)
+ * value * (max * m) = (sensor * (p+m) * ref)
+ * value * (max * m) / ((p+m) * ref) = sensor
+ */
+
+#define AO_DV_MUL(p,m) ((int32_t) AO_ADC_MAX * (m))
+#define AO_DV_DIV(p,m) ((int32_t) AO_ADC_REFERENCE_DV * ((p) + (m)))
+#define AO_DV_ADD(p,m) (AO_DV_DIV(p,m) / 2)
+
+#define ao_decivolt_to_adc(dv, p, m) \
+ ((int16_t) (((int32_t) (dv) * AO_DV_MUL(p,m) + AO_DV_ADD(p,m)) / AO_DV_DIV(p,m)))
+
+#define AO_IGNITER_CLOSED_DV 35
+#define AO_IGNITER_OPEN_DV 10
+
+#define AO_PYRO_BATTERY_GOOD_DV 38
+
+#undef AO_IGNITER_OPEN
+#undef AO_IGNITER_CLOSED
+
+#define AO_IGNITER_OPEN ao_decivolt_to_adc(AO_IGNITER_OPEN_DV, AO_IGNITE_DIV_PLUS, AO_IGNITE_DIV_MINUS)
+#define AO_IGNITER_CLOSED ao_decivolt_to_adc(AO_IGNITER_CLOSED_DV, AO_IGNITE_DIV_PLUS, AO_IGNITE_DIV_MINUS)
+
+#define AO_PYRO_BATTERY_GOOD ao_decivolt_to_adc(AO_PYRO_BATTERY_GOOD_DV, AO_PYRO_BATTERY_DIV_PLUS, AO_PYRO_BATTERY_DIV_MINUS)
+
+/* For devices measuring the pyro battery voltage, we want to use a
+ * fraction of that. We'll use 15/16 of the battery voltage as a limit
+ * For devices not measuring the pyro battery voltage, we'll use 3.5V
+ * instead (this is just TeleMetrum, which permits external pyro
+ * batteries but has not provision to measure the voltage)
+ */
+
+static inline int16_t
+ao_igniter_closed_value(int16_t battery)
+{
+#if AO_PYRO_BATTERY_DIV_PLUS != AO_IGNITE_DIV_PLUS || AO_PYRO_BATTERY_DIV_MINUS != AO_IGNITE_DIV_MINUS
+ (void) battery;
+ return AO_IGNITER_CLOSED;
+#else
+ return (int16_t) (((int32_t) battery * 15) / 16);
+#endif
+}
+
+static inline int16_t
+ao_igniter_open_value(int16_t battery)
+{
+#if AO_PYRO_BATTERY_DIV_PLUS != AO_IGNITE_DIV_PLUS || AO_PYRO_BATTERY_DIV_MINUS != AO_IGNITE_DIV_MINUS
+ (void) battery;
+ return AO_IGNITER_OPEN;
+#else
+ return (int16_t) (((int32_t) battery * 1) / 8);
+#endif
+}
+
+static inline enum ao_igniter_status
+ao_igniter_check(int16_t value, int16_t battery)
+{
+ if (battery < AO_PYRO_BATTERY_GOOD)
+ return ao_igniter_open;
+ if (value < ao_igniter_open_value(battery))
+ return ao_igniter_open;
+ else if (value > ao_igniter_closed_value(battery))
+ return ao_igniter_ready;
+ else
+ return ao_igniter_unknown;
+}
+
#endif
#endif
}
+#define AO_STACK_CANARY_VALUE 0xbaadf00dU
+
void
ao_add_task(struct ao_task * task, void (*task_func)(void), const char *name)
{
task->task_id = task_id;
task->name = name;
task->wchan = NULL;
+#ifdef AO_STACK_CANARY
+ task->bottom_canary = AO_STACK_CANARY_VALUE;
+ task->top_canary = AO_STACK_CANARY_VALUE;
+#endif
/*
* Construct a stack frame so that it will 'return'
* to the start of the task
);
}
+#ifdef AO_STACK_CANARY
+static void
+ao_check_stack_canary(void)
+{
+ if (ao_cur_task->bottom_canary != AO_STACK_CANARY_VALUE)
+ ao_panic(AO_PANIC_STACK);
+ if (ao_cur_task->top_canary != AO_STACK_CANARY_VALUE)
+ ao_panic(AO_PANIC_STACK);
+}
+#else
+#define ao_check_stack_canary()
+#endif
+
uint8_t ao_task_minimize_latency;
/* Task switching function. */
ao_cur_task->max_run = run;
++ao_cur_task->yields;
#endif
+ ao_check_stack_canary();
ao_arch_save_regs();
ao_arch_save_stack();
}
#if USE_TLS
_set_tls(ao_stack_top(ao_cur_task));
#endif
+ ao_check_stack_canary();
ao_arch_restore_stack();
}
struct ao_list queue;
struct ao_list alarm_queue;
/* Provide both 32-bit and 8-bit stacks */
+#ifdef AO_STACK_CANARY
+ uint32_t bottom_canary;
+#endif
union {
uint32_t stack32[AO_STACK_SIZE>>2];
uint8_t stack8[AO_STACK_SIZE];
} AO_STACK_ALIGNMENT;
+#ifdef AO_STACK_CANARY
+ uint32_t top_canary;
+#endif
#if HAS_SAMPLE_PROFILE
uint32_t ticks;
uint32_t yields;
__flash_size = 28K;
__ram = 0x20000000;
__ram_size = 6k;
-__stack_size = 128;
+__stack_size = 256;
INCLUDE registers.ld
INCLUDE picolibc.ld
#include <ao_boot.h>
#include <ao_exti.h>
+#if AO_BOOT_PIN
int
ao_boot_check_pin(void)
{
stm_rcc.apb1enr &= ~(1UL << STM_RCC_APB1ENR_PWREN);
return v == AO_BOOT_APPLICATION_VALUE;
}
+#endif
#ifndef _AO_PINS_H_
#define _AO_PINS_H_
-#define AO_STACK_SIZE 512
+#define AO_STACK_SIZE 504
#define AO_HSE 32000000
#define AO_RCC_CFGR_PLLMUL STM_RCC_CFGR_PLLMUL_3
#include <ao_packet.h>
#include <ao_companion.h>
#include <ao_profile.h>
-#include <ao_pyro.h>
#include <ao_aes.h>
#include <ao_seven_segment.h>
#include <ao_quadrature.h>
#include <ao_packet.h>
#include <ao_companion.h>
#include <ao_profile.h>
-#include <ao_pyro.h>
#include <ao_aes.h>
#include <ao_seven_segment.h>
#include <ao_quadrature.h>
#include <ao_packet.h>
#include <ao_companion.h>
#include <ao_profile.h>
-#include <ao_pyro.h>
#include <ao_aes.h>
#include <ao_seven_segment.h>
#include <ao_quadrature.h>
#include <ao_packet.h>
#include <ao_companion.h>
#include <ao_profile.h>
-#include <ao_pyro.h>
#include <ao_aes.h>
#include <ao_seven_segment.h>
#include <ao_quadrature.h>
#include <ao_packet.h>
#include <ao_companion.h>
#include <ao_profile.h>
-#include <ao_pyro.h>
#include <ao_aes.h>
#include <ao_button.h>
#include <ao_lco.h>
#define AO_BATTERY_DIV_PLUS 56 /* 5.6k */
#define AO_BATTERY_DIV_MINUS 100 /* 10k */
+/*
+ * Voltage divider on ADC pyro battery sampler
+ */
+#define AO_PYRO_BATTERY_DIV_PLUS 100 /* 100k */
+#define AO_PYRO_BATTERY_DIV_MINUS 27 /* 27k */
+
/*
* Voltage divider on ADC igniter samplers
*/
#define AO_BATTERY_DIV_PLUS 56 /* 5.6k */
#define AO_BATTERY_DIV_MINUS 100 /* 10k */
+/*
+ * Voltage divider on ADC pyro battery sampler
+ */
+#define AO_PYRO_BATTERY_DIV_PLUS 100 /* 100k */
+#define AO_PYRO_BATTERY_DIV_MINUS 27 /* 27k */
+
/*
* Voltage divider on ADC igniter samplers
*/
#define AO_BATTERY_DIV_PLUS 56 /* 5.6k */
#define AO_BATTERY_DIV_MINUS 100 /* 10k */
+/*
+ * Voltage divider on ADC pyro battery sampler
+ */
+#define AO_PYRO_BATTERY_DIV_PLUS 100 /* 100k */
+#define AO_PYRO_BATTERY_DIV_MINUS 27 /* 27k */
+
/*
* Voltage divider on ADC igniter samplers
*/
#define AO_BATTERY_DIV_PLUS 56 /* 5.6k */
#define AO_BATTERY_DIV_MINUS 100 /* 10k */
+/*
+ * Voltage divider on ADC pyro battery sampler
+ */
+#define AO_PYRO_BATTERY_DIV_PLUS 100 /* 100k */
+#define AO_PYRO_BATTERY_DIV_MINUS 27 /* 27k */
+
/*
* Voltage divider on ADC igniter samplers
*/
#define AO_BATTERY_DIV_PLUS 56 /* 5.6k */
#define AO_BATTERY_DIV_MINUS 100 /* 10k */
+/*
+ * Voltage divider on ADC pyro battery sampler
+ */
+#define AO_PYRO_BATTERY_DIV_PLUS 100 /* 100k */
+#define AO_PYRO_BATTERY_DIV_MINUS 27 /* 27k */
+
/*
* Voltage divider on ADC igniter samplers
*/
#define AO_BATTERY_DIV_PLUS 56 /* 5.6k */
#define AO_BATTERY_DIV_MINUS 100 /* 10k */
+/*
+ * Voltage divider on ADC pyro battery sampler
+ */
+#define AO_PYRO_BATTERY_DIV_PLUS 100 /* 100k */
+#define AO_PYRO_BATTERY_DIV_MINUS 27 /* 27k */
+
/*
* Voltage divider on ADC igniter samplers
*/
#define AO_BATTERY_DIV_PLUS 56 /* 5.6k */
#define AO_BATTERY_DIV_MINUS 100 /* 10k */
+/*
+ * Voltage divider on ADC pyro battery sampler
+ */
+#define AO_PYRO_BATTERY_DIV_PLUS 100 /* 100k */
+#define AO_PYRO_BATTERY_DIV_MINUS 27 /* 27k */
+
/*
* Voltage divider on ADC igniter samplers
*/
*/
#define AO_SERIAL_SPEED_UBLOX AO_SERIAL_SPEED_9600
+#define AO_UBLOX_VERSION 10
#define HAS_SERIAL_1 1
#define USE_SERIAL_1_STDIN 0
#define HAS_SERIAL_1 0
#define HAS_BATTERY_REPORT 1
-#define AO_STACK_SIZE 448
+#define AO_STACK_SIZE 428
#define IS_FLASH_LOADER 0