Merge branch 'master' of ssh://git.gag.com/scm/git/fw/altos
authorBdale Garbee <bdale@gag.com>
Mon, 4 Apr 2022 07:22:04 +0000 (01:22 -0600)
committerBdale Garbee <bdale@gag.com>
Mon, 4 Apr 2022 07:22:04 +0000 (01:22 -0600)
17 files changed:
altosui/AltosUI.app/Contents/MacOS/JavaApplicationStub
altosui/Instdrv/NSIS/Includes/java.nsh
altosui/install-macosx
configure.ac
libaltos/Makefile-standalone
libaltos/libaltos.dylib
micropeak/MicroPeak.app/Contents/MacOS/JavaApplicationStub
src/aes/ao_aes_tables.c
src/aes/ao_aes_tables.h
src/kernel/ao_ignite.c
src/kernel/ao_pyro.c
src/kernel/ao_pyro.h
src/stm/ao_timer.c
src/stm32f4/ao_timer.c
src/stm32l0/ao_timer.c
src/stmf0/ao_timer.c
telegps/TeleGPS.app/Contents/MacOS/JavaApplicationStub

index aa96638f5cf9822d1ca1fda58eccc6579903a4f2..9b7cb7078bce137d5889192008cc186c651c899e 100755 (executable)
@@ -393,7 +393,7 @@ fr)
        MSG_INSTALL_JAVA="Java doit être installé sur votre système.\nRendez-vous sur java.com et suivez les instructions d'installation..."
        MSG_LATER="Plus tard"
        MSG_VISIT_JAVA_DOT_COM="Java by Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java by AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java by Adoptium"
     ;;
 
 # German
@@ -409,7 +409,7 @@ de)
        MSG_INSTALL_JAVA="Auf Ihrem System muss die 'Java'-Software installiert sein.\nBesuchen Sie java.com für weitere Installationshinweise."
        MSG_LATER="Später"
        MSG_VISIT_JAVA_DOT_COM="Java von Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java von AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java von Adoptium"
     ;;
 
 # Simplified Chinese
@@ -425,7 +425,7 @@ zh)
        MSG_INSTALL_JAVA="你需要在Mac中安装Java运行环境!\n访问 java.com 了解如何安装。"
        MSG_LATER="稍后"
        MSG_VISIT_JAVA_DOT_COM="Java by Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java by AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java by Adoptium"
     ;;
 
 # Spanish
@@ -441,7 +441,7 @@ es)
        MSG_INSTALL_JAVA="¡Necesita tener JAVA instalado en su Mac!\nVisite java.com para consultar las instrucciones para su instalación..."
        MSG_LATER="Más tarde"
        MSG_VISIT_JAVA_DOT_COM="Java de Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java de AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java de Adoptium"
     ;;
 
 # English | default
@@ -457,7 +457,7 @@ en|*)
        MSG_INSTALL_JAVA="You need to have JAVA installed on your Mac!\nVisit java.com for installation instructions..."
        MSG_LATER="Later"
        MSG_VISIT_JAVA_DOT_COM="Java by Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java by AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java by Adoptium"
     ;;
 esac
 
@@ -829,10 +829,10 @@ if [ -z "${JAVACMD}" ] || [ ! -x "${JAVACMD}" ] ; then
                stub_logger "[EXIT 3] ${MSG_NO_SUITABLE_JAVA_EXPANDED}"
 
                # display error message with AppleScript
-               osascript -e "tell application \"System Events\" to display dialog \"${MSG_ERROR_LAUNCHING}\n\n${MSG_NO_SUITABLE_JAVA_EXPANDED}\n${MSG_NO_SUITABLE_JAVA_CHECK}\" with title \"${CFBundleName}\"  buttons {\" OK \", \"${MSG_VISIT_JAVA_DOT_COM}\", \"${MSG_VISIT_ADOPTOPENJDK}\"} default button 1${DialogWithIcon}" \
+               osascript -e "tell application \"System Events\" to display dialog \"${MSG_ERROR_LAUNCHING}\n\n${MSG_NO_SUITABLE_JAVA_EXPANDED}\n${MSG_NO_SUITABLE_JAVA_CHECK}\" with title \"${CFBundleName}\"  buttons {\" OK \", \"${MSG_VISIT_JAVA_DOT_COM}\", \"${MSG_VISIT_ADOPTIUM}\"} default button 1${DialogWithIcon}" \
                                -e "set response to button returned of the result" \
                                -e "if response is \"${MSG_VISIT_JAVA_DOT_COM}\" then open location \"https://www.java.com/download/\"" \
-                               -e "if response is \"${MSG_VISIT_ADOPTOPENJDK}\" then open location \"https://adoptopenjdk.net/releases.html\""
+                               -e "if response is \"${MSG_VISIT_ADOPTIUM}\" then open location \"https://adoptium.net/releases.html\""
                # exit with error
                exit 3
 
@@ -840,10 +840,10 @@ if [ -z "${JAVACMD}" ] || [ ! -x "${JAVACMD}" ] ; then
                # log exit cause
                stub_logger "[EXIT 1] ${MSG_ERROR_LAUNCHING}"
                # display error message with AppleScript
-               osascript -e "tell application \"System Events\" to display dialog \"${MSG_ERROR_LAUNCHING}\n\n${MSG_INSTALL_JAVA}\" with title \"${CFBundleName}\" buttons {\"${MSG_LATER}\", \"${MSG_VISIT_JAVA_DOT_COM}\", \"${MSG_VISIT_ADOPTOPENJDK}\"} default button 1${DialogWithIcon}" \
+               osascript -e "tell application \"System Events\" to display dialog \"${MSG_ERROR_LAUNCHING}\n\n${MSG_INSTALL_JAVA}\" with title \"${CFBundleName}\" buttons {\"${MSG_LATER}\", \"${MSG_VISIT_JAVA_DOT_COM}\", \"${MSG_VISIT_ADOPTIUM}\"} default button 1${DialogWithIcon}" \
                                        -e "set response to button returned of the result" \
                                        -e "if response is \"${MSG_VISIT_JAVA_DOT_COM}\" then open location \"https://www.java.com/download/\"" \
-                                       -e "if response is \"${MSG_VISIT_ADOPTOPENJDK}\" then open location \"https://adoptopenjdk.net/releases.html\""
+                                       -e "if response is \"${MSG_VISIT_ADOPTIUM}\" then open location \"https://adoptium.net/releases.html\""
                # exit with error
                exit 1
        fi
index c7ec9ca9d08d70b2b129753efb6b6a3688048207..5fa82eef82552e123c65ba68db79b7d7f28f6f04 100644 (file)
@@ -150,7 +150,7 @@ var quit
 var skip
 
 Function GetJRE
-  ${OpenURL} "adoptopenjdk.net"
+  ${OpenURL} "adoptium.net"
   MessageBox MB_OK "Click OK to continue after completing the Java Install."
 FunctionEnd
 
index e97a002ae2e08fb4f7a7219efa86b2c4a87c7ae4..721a3d1cf79c7660d6a6f5eea089ff5c0e155ab6 100755 (executable)
@@ -20,11 +20,11 @@ case `id -u` in
 esac
 
 # Check for java
-if ls "$JVM" | grep -q adopt; then
-    echo "Adopt OpenJDK already present"
+if ls "$JVM" | grep -q temurin; then
+    echo "Adoptium already present"
 else
-    open https://adoptopenjdk.net/
-    osascript -e 'display dialog "Install Java from https://adoptopenjdk.net then click Continue" buttons {"Continue"} default button 1 with title "Install Java"' >/dev/null
+    open https://adoptium.net/
+    osascript -e 'display dialog "Install Java from https://adoptium.net then click Continue" buttons {"Continue"} default button 1 with title "Install Java"' >/dev/null
 fi
 
 cd "$dir"
index 7ed519d1df8bd88814f4c2402d5b207df595deb2..7c204d0a02699f6936d24c77a5e3e2594b2a02cf 100644 (file)
@@ -18,13 +18,13 @@ dnl
 dnl Process this file with autoconf to create configure.
 
 AC_PREREQ(2.57)
-AC_INIT([altos], 1.9.10.2)
+AC_INIT([altos], 1.9.10.3)
 ANDROID_VERSION=34
 AC_CONFIG_SRCDIR([src/kernel/ao.h])
 AM_INIT_AUTOMAKE([foreign dist-bzip2])
 AM_MAINTAINER_MODE
 
-RELEASE_DATE=2022-01-11
+RELEASE_DATE=2022-02-09
 AC_SUBST(RELEASE_DATE)
 
 DOC_DATE=`LC_ALL=C date -d $RELEASE_DATE +'%d %b %Y'`
index 77c7cca514f1e6196288eefbd5d6372821bc00a8..dce602a9e340bc8a3ba8eed4b56e576aba75343b 100644 (file)
@@ -34,11 +34,11 @@ OS_SRCS=libaltos_posix.c libaltos_darwin.c
 #      -iwithsysroot /System/Library/Frameworks/CoreFoundation.framework/Headers
 
 XCODE=/Applications/Xcode.app
-SDK=$(XCODE)/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk
+SDK=$(XCODE)/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.1.sdk
 MINVERSION=10.5
 
 OS_LIB_CFLAGS=\
-       -DDARWIN -DPOSIX_TTY -arch x86_64 -isysroot $(SDK) \
+       -DDARWIN -DPOSIX_TTY -arch x86_64 -arch arm64 -isysroot $(SDK) \
        -mmacosx-version-min=10.5 \
        -iwithsysroot /System/Library/Frameworks/JavaVM.framework/Headers \
        -iwithsysroot /System/Library/Frameworks/IOKit.framework/Headers \
index 0d5b9c46309e1ec164fbe924bb3921b099bb8013..fcc46efea5733327847446f80ed741da13e52711 100755 (executable)
Binary files a/libaltos/libaltos.dylib and b/libaltos/libaltos.dylib differ
index aa96638f5cf9822d1ca1fda58eccc6579903a4f2..9b7cb7078bce137d5889192008cc186c651c899e 100755 (executable)
@@ -393,7 +393,7 @@ fr)
        MSG_INSTALL_JAVA="Java doit être installé sur votre système.\nRendez-vous sur java.com et suivez les instructions d'installation..."
        MSG_LATER="Plus tard"
        MSG_VISIT_JAVA_DOT_COM="Java by Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java by AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java by Adoptium"
     ;;
 
 # German
@@ -409,7 +409,7 @@ de)
        MSG_INSTALL_JAVA="Auf Ihrem System muss die 'Java'-Software installiert sein.\nBesuchen Sie java.com für weitere Installationshinweise."
        MSG_LATER="Später"
        MSG_VISIT_JAVA_DOT_COM="Java von Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java von AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java von Adoptium"
     ;;
 
 # Simplified Chinese
@@ -425,7 +425,7 @@ zh)
        MSG_INSTALL_JAVA="你需要在Mac中安装Java运行环境!\n访问 java.com 了解如何安装。"
        MSG_LATER="稍后"
        MSG_VISIT_JAVA_DOT_COM="Java by Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java by AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java by Adoptium"
     ;;
 
 # Spanish
@@ -441,7 +441,7 @@ es)
        MSG_INSTALL_JAVA="¡Necesita tener JAVA instalado en su Mac!\nVisite java.com para consultar las instrucciones para su instalación..."
        MSG_LATER="Más tarde"
        MSG_VISIT_JAVA_DOT_COM="Java de Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java de AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java de Adoptium"
     ;;
 
 # English | default
@@ -457,7 +457,7 @@ en|*)
        MSG_INSTALL_JAVA="You need to have JAVA installed on your Mac!\nVisit java.com for installation instructions..."
        MSG_LATER="Later"
        MSG_VISIT_JAVA_DOT_COM="Java by Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java by AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java by Adoptium"
     ;;
 esac
 
@@ -829,10 +829,10 @@ if [ -z "${JAVACMD}" ] || [ ! -x "${JAVACMD}" ] ; then
                stub_logger "[EXIT 3] ${MSG_NO_SUITABLE_JAVA_EXPANDED}"
 
                # display error message with AppleScript
-               osascript -e "tell application \"System Events\" to display dialog \"${MSG_ERROR_LAUNCHING}\n\n${MSG_NO_SUITABLE_JAVA_EXPANDED}\n${MSG_NO_SUITABLE_JAVA_CHECK}\" with title \"${CFBundleName}\"  buttons {\" OK \", \"${MSG_VISIT_JAVA_DOT_COM}\", \"${MSG_VISIT_ADOPTOPENJDK}\"} default button 1${DialogWithIcon}" \
+               osascript -e "tell application \"System Events\" to display dialog \"${MSG_ERROR_LAUNCHING}\n\n${MSG_NO_SUITABLE_JAVA_EXPANDED}\n${MSG_NO_SUITABLE_JAVA_CHECK}\" with title \"${CFBundleName}\"  buttons {\" OK \", \"${MSG_VISIT_JAVA_DOT_COM}\", \"${MSG_VISIT_ADOPTIUM}\"} default button 1${DialogWithIcon}" \
                                -e "set response to button returned of the result" \
                                -e "if response is \"${MSG_VISIT_JAVA_DOT_COM}\" then open location \"https://www.java.com/download/\"" \
-                               -e "if response is \"${MSG_VISIT_ADOPTOPENJDK}\" then open location \"https://adoptopenjdk.net/releases.html\""
+                               -e "if response is \"${MSG_VISIT_ADOPTIUM}\" then open location \"https://adoptium.net/releases.html\""
                # exit with error
                exit 3
 
@@ -840,10 +840,10 @@ if [ -z "${JAVACMD}" ] || [ ! -x "${JAVACMD}" ] ; then
                # log exit cause
                stub_logger "[EXIT 1] ${MSG_ERROR_LAUNCHING}"
                # display error message with AppleScript
-               osascript -e "tell application \"System Events\" to display dialog \"${MSG_ERROR_LAUNCHING}\n\n${MSG_INSTALL_JAVA}\" with title \"${CFBundleName}\" buttons {\"${MSG_LATER}\", \"${MSG_VISIT_JAVA_DOT_COM}\", \"${MSG_VISIT_ADOPTOPENJDK}\"} default button 1${DialogWithIcon}" \
+               osascript -e "tell application \"System Events\" to display dialog \"${MSG_ERROR_LAUNCHING}\n\n${MSG_INSTALL_JAVA}\" with title \"${CFBundleName}\" buttons {\"${MSG_LATER}\", \"${MSG_VISIT_JAVA_DOT_COM}\", \"${MSG_VISIT_ADOPTIUM}\"} default button 1${DialogWithIcon}" \
                                        -e "set response to button returned of the result" \
                                        -e "if response is \"${MSG_VISIT_JAVA_DOT_COM}\" then open location \"https://www.java.com/download/\"" \
-                                       -e "if response is \"${MSG_VISIT_ADOPTOPENJDK}\" then open location \"https://adoptopenjdk.net/releases.html\""
+                                       -e "if response is \"${MSG_VISIT_ADOPTIUM}\" then open location \"https://adoptium.net/releases.html\""
                # exit with error
                exit 1
        fi
index 1bca227c1b9d92c680f36fafb783b12445daa87d..311b7b4e158a25121263f451760280fdadbf503a 100644 (file)
@@ -716,7 +716,7 @@ const word8x4 M1[4][256] = {
  },
 };
 
-const int xrcon[30] = {
+const word8 xrcon[30] = {
   0x01, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80, 0x1b, 0x36, 
   0x6c, 0xd8, 0xab, 0x4d, 0x9a, 0x2f, 0x5e, 0xbc, 0x63, 0xc6, 
   0x97, 0x35, 0x6a, 0xd4, 0xb3, 0x7d, 0xfa, 0xef, 0xc5, 0x91, 
index 73bcf3fbbab748dd6183f60662f22497cea6c969..cc005bfd90b657837c08077e990ae3af351f5f83 100644 (file)
@@ -4,7 +4,7 @@
 
 extern const word8x4 M0[4][256];
 extern const word8x4 M1[4][256];
-extern const int xrcon[30];
+extern const word8 xrcon[30];
 extern const word8 xS[256];
 extern const word8 xSi[256];
 
index d197239a991e60db1ce9d90b38b8611335e4b184..86a116d1f11addecf6d6d0d0009420df19e34266 100644 (file)
@@ -82,6 +82,9 @@ ao_igniter_fire(enum ao_igniter igniter, bool wait)
                ao_ignition[igniter].fired = 1;
                switch (igniter) {
                case ao_igniter_drogue:
+                       if (wait && ao_config.apogee_delay &&
+                           ao_config.ignite_mode != AO_IGNITE_MODE_MAIN)
+                               ao_delay(AO_SEC_TO_TICKS(ao_config.apogee_delay));
                        AO_IGNITER_SET_DROGUE(1);
                        ao_delay(AO_IGNITER_FIRE_TIME);
                        AO_IGNITER_SET_DROGUE(0);
index c9db061bfcf5f2bd74336b44f4afa16b821b2a71..ee94eca35c5c22c461cc576b3bf04cd7a4fadd8b 100644 (file)
@@ -101,7 +101,7 @@ ao_sample_max_orient(void)
  * of the requirements
  */
 static uint8_t
-ao_pyro_ready(struct ao_pyro *pyro)
+ao_pyro_ready(const struct ao_pyro *pyro)
 {
        enum ao_pyro_flag flag, flags;
 #if HAS_GYRO
@@ -264,10 +264,12 @@ ao_pyro_pins_fire(uint16_t fire)
        ao_delay(AO_MS_TO_TICKS(50));
 }
 
+static AO_TICK_TYPE pyro_delay_done[AO_PYRO_NUM];
+
 static uint8_t
 ao_pyro_check(void)
 {
-       struct ao_pyro  *pyro;
+       const struct ao_pyro    *pyro;
        uint8_t         p, any_waiting;
        uint16_t        fire = 0;
 
@@ -288,7 +290,7 @@ ao_pyro_check(void)
                any_waiting = 1;
                /* Check pyro state to see if it should fire
                 */
-               if (!pyro->delay_done) {
+               if (!pyro_delay_done[p]) {
                        if (!ao_pyro_ready(pyro))
                                continue;
 
@@ -296,31 +298,36 @@ ao_pyro_check(void)
                         * it expires
                         */
                        if (pyro->flags & ao_pyro_delay) {
-                               pyro->delay_done = ao_time() + pyro->delay;
-                               if (!pyro->delay_done)
-                                       pyro->delay_done = 1;
+                               AO_TICK_TYPE delay_done;
+                               AO_TICK_SIGNED delay = pyro->delay;
+                               if (delay < 0)
+                                       delay = 0;
+                               delay_done = ao_time() + (AO_TICK_TYPE) delay;
+                               if (!delay_done)
+                                       delay_done = 1;
+                               pyro_delay_done[p] = delay_done;
                        }
                }
 
                /* Check to see if we're just waiting for
                 * the delay to expire
                 */
-               if (pyro->delay_done) {
+               if (pyro_delay_done[p]) {
 
                        /* Check to make sure the required conditions
                         * remain valid. If not, inhibit the channel
                         * by setting the inhibited bit
                         */
                        if (!ao_pyro_ready(pyro)) {
-                               ao_pyro_inhibited |= (1 << p);
+                               ao_pyro_inhibited |= (uint16_t) (1 << p);
                                continue;
                        }
 
-                       if ((AO_TICK_SIGNED) (ao_time() - pyro->delay_done) < 0)
+                       if ((AO_TICK_SIGNED) (ao_time() - pyro_delay_done[p]) < 0)
                                continue;
                }
 
-               fire |= (1 << p);
+               fire |= (uint16_t) (1U << p);
        }
 
        if (fire) {
@@ -457,11 +464,11 @@ ao_pyro_put(void *base, uint8_t offset, uint8_t size, int32_t value)
        case 8:
                if (value < 0)
                        return false;
-               *((uint8_t *) ((char *) base + offset)) = value;
+               *((uint8_t *) ((char *) base + offset)) = (uint8_t) value;
                break;
        case 16:
        default:
-               *((int16_t *) (void *) ((char *) base + offset)) = value;
+               *((int16_t *) (void *) ((char *) base + offset)) = (int16_t) value;
                break;
        case 32:
                *((int32_t *) (void *) ((char *) base + offset)) = value;
@@ -515,7 +522,7 @@ ao_pyro_show(void)
 void
 ao_pyro_set(void)
 {
-       uint8_t p;
+       uint32_t        p;
        struct ao_pyro pyro_tmp;
        char    name[AO_PYRO_NAME_LEN];
        uint8_t c;
@@ -535,7 +542,7 @@ ao_pyro_set(void)
        if (ao_cmd_status != ao_cmd_success)
                return;
        if (AO_PYRO_NUM <= p) {
-               printf ("invalid pyro channel %d\n", p);
+               printf ("invalid pyro channel %lu\n", p);
                return;
        }
        memset(&pyro_tmp, '\0', sizeof (pyro_tmp));
@@ -568,7 +575,7 @@ ao_pyro_set(void)
                                r = -1;
                                ao_cmd_lex();
                        }
-                       r *= ao_cmd_decimal();
+                       r *= (int32_t) ao_cmd_decimal();
                        if (ao_cmd_status != ao_cmd_success)
                                return;
                        if (!ao_pyro_put(&pyro_tmp, ao_pyro_values[v].offset,
@@ -651,7 +658,7 @@ ao_pyro_update_version(void)
                char    *after_pyro_1_24 = pyro_base_1_24 + AO_PYRO_NUM * sizeof (struct ao_pyro_1_24);
 
                char    *config_end_1_25 = (void *) (&ao_config + 1);
-               size_t  to_move = config_end_1_25 - after_pyro_1_25;
+               size_t  to_move = (size_t) (config_end_1_25 - after_pyro_1_25);
 
                memmove(after_pyro_1_25, after_pyro_1_24, to_move);
 
index 4a8c3aabb1857c8adb4d7727f00bc4a5f0d4f407..f17abed377907fa0fa4eb5a5c34c7f30c5c1bc21 100644 (file)
@@ -76,8 +76,8 @@ struct ao_pyro {
        int32_t                 delay;
        uint8_t                 state_less, state_greater_or_equal;
        int16_t                 motor;
-       int32_t                 delay_done;
-       uint8_t                 _unused       /* was 'fired' */
+       uint32_t                _unused1;       /* was 'delay_done' */
+       uint8_t                 _unused2;       /* was 'fired' */
 };
 
 #define AO_PYRO_8_BIT_VALUE    (ao_pyro_state_less|ao_pyro_state_greater_or_equal)
index 0d81b5de47e6170fccfe160f34a90f4f9c1fa97b..eec0a35ad3dbc9807d4c9e5980d77a624a85134a 100644 (file)
@@ -69,7 +69,7 @@ void stm_systick_isr(void)
 #endif
                ao_task_check_alarm();
 #if AO_DATA_ALL
-               if (++ao_data_count == ao_data_interval) {
+               if (++ao_data_count == ao_data_interval && ao_data_interval) {
                        ao_data_count = 0;
 #if HAS_FAKE_FLIGHT
                        if (ao_fake_flight_active)
index 999b587f3e7933862bbad0f72e783e15f3c11dee..83ffe4a76a247db1c1080b1c677183d153c94931 100644 (file)
@@ -49,7 +49,7 @@ void stm_systick_isr(void)
 #endif
                ao_task_check_alarm();
 #if AO_DATA_ALL
-               if (++ao_data_count == ao_data_interval) {
+               if (++ao_data_count == ao_data_interval && ao_data_interval) {
                        ao_data_count = 0;
 #if HAS_FAKE_FLIGHT
                        if (ao_fake_flight_active)
index 89193333f5c32a138d2bd593ced54c2c04a1db1f..6d447fc96cc3324d0598ec71a21eb809153d3be9 100644 (file)
@@ -64,7 +64,7 @@ void stm_systick_isr(void)
                ++ao_tick_count;
                ao_task_check_alarm();
 #if AO_DATA_ALL
-               if (++ao_data_count == ao_data_interval) {
+               if (++ao_data_count == ao_data_interval && ao_data_interval) {
                        ao_data_count = 0;
 #if HAS_ADC
 #if HAS_FAKE_FLIGHT
index b0b6ec0a07e878d5f6c5dab4658468f7588c5f1f..5b180074c07d8ddf7b850bf7e527a25a5e62ed31 100644 (file)
@@ -62,7 +62,7 @@ void stm_systick_isr(void)
                ++ao_tick_count;
                ao_task_check_alarm();
 #if AO_DATA_ALL
-               if (++ao_data_count == ao_data_interval) {
+               if (++ao_data_count == ao_data_interval && ao_data_interval) {
                        ao_data_count = 0;
 #if HAS_ADC
 #if HAS_FAKE_FLIGHT
index aa96638f5cf9822d1ca1fda58eccc6579903a4f2..9b7cb7078bce137d5889192008cc186c651c899e 100755 (executable)
@@ -393,7 +393,7 @@ fr)
        MSG_INSTALL_JAVA="Java doit être installé sur votre système.\nRendez-vous sur java.com et suivez les instructions d'installation..."
        MSG_LATER="Plus tard"
        MSG_VISIT_JAVA_DOT_COM="Java by Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java by AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java by Adoptium"
     ;;
 
 # German
@@ -409,7 +409,7 @@ de)
        MSG_INSTALL_JAVA="Auf Ihrem System muss die 'Java'-Software installiert sein.\nBesuchen Sie java.com für weitere Installationshinweise."
        MSG_LATER="Später"
        MSG_VISIT_JAVA_DOT_COM="Java von Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java von AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java von Adoptium"
     ;;
 
 # Simplified Chinese
@@ -425,7 +425,7 @@ zh)
        MSG_INSTALL_JAVA="你需要在Mac中安装Java运行环境!\n访问 java.com 了解如何安装。"
        MSG_LATER="稍后"
        MSG_VISIT_JAVA_DOT_COM="Java by Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java by AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java by Adoptium"
     ;;
 
 # Spanish
@@ -441,7 +441,7 @@ es)
        MSG_INSTALL_JAVA="¡Necesita tener JAVA instalado en su Mac!\nVisite java.com para consultar las instrucciones para su instalación..."
        MSG_LATER="Más tarde"
        MSG_VISIT_JAVA_DOT_COM="Java de Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java de AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java de Adoptium"
     ;;
 
 # English | default
@@ -457,7 +457,7 @@ en|*)
        MSG_INSTALL_JAVA="You need to have JAVA installed on your Mac!\nVisit java.com for installation instructions..."
        MSG_LATER="Later"
        MSG_VISIT_JAVA_DOT_COM="Java by Oracle"
-       MSG_VISIT_ADOPTOPENJDK="Java by AdoptOpenJDK"
+       MSG_VISIT_ADOPTIUM="Java by Adoptium"
     ;;
 esac
 
@@ -829,10 +829,10 @@ if [ -z "${JAVACMD}" ] || [ ! -x "${JAVACMD}" ] ; then
                stub_logger "[EXIT 3] ${MSG_NO_SUITABLE_JAVA_EXPANDED}"
 
                # display error message with AppleScript
-               osascript -e "tell application \"System Events\" to display dialog \"${MSG_ERROR_LAUNCHING}\n\n${MSG_NO_SUITABLE_JAVA_EXPANDED}\n${MSG_NO_SUITABLE_JAVA_CHECK}\" with title \"${CFBundleName}\"  buttons {\" OK \", \"${MSG_VISIT_JAVA_DOT_COM}\", \"${MSG_VISIT_ADOPTOPENJDK}\"} default button 1${DialogWithIcon}" \
+               osascript -e "tell application \"System Events\" to display dialog \"${MSG_ERROR_LAUNCHING}\n\n${MSG_NO_SUITABLE_JAVA_EXPANDED}\n${MSG_NO_SUITABLE_JAVA_CHECK}\" with title \"${CFBundleName}\"  buttons {\" OK \", \"${MSG_VISIT_JAVA_DOT_COM}\", \"${MSG_VISIT_ADOPTIUM}\"} default button 1${DialogWithIcon}" \
                                -e "set response to button returned of the result" \
                                -e "if response is \"${MSG_VISIT_JAVA_DOT_COM}\" then open location \"https://www.java.com/download/\"" \
-                               -e "if response is \"${MSG_VISIT_ADOPTOPENJDK}\" then open location \"https://adoptopenjdk.net/releases.html\""
+                               -e "if response is \"${MSG_VISIT_ADOPTIUM}\" then open location \"https://adoptium.net/releases.html\""
                # exit with error
                exit 3
 
@@ -840,10 +840,10 @@ if [ -z "${JAVACMD}" ] || [ ! -x "${JAVACMD}" ] ; then
                # log exit cause
                stub_logger "[EXIT 1] ${MSG_ERROR_LAUNCHING}"
                # display error message with AppleScript
-               osascript -e "tell application \"System Events\" to display dialog \"${MSG_ERROR_LAUNCHING}\n\n${MSG_INSTALL_JAVA}\" with title \"${CFBundleName}\" buttons {\"${MSG_LATER}\", \"${MSG_VISIT_JAVA_DOT_COM}\", \"${MSG_VISIT_ADOPTOPENJDK}\"} default button 1${DialogWithIcon}" \
+               osascript -e "tell application \"System Events\" to display dialog \"${MSG_ERROR_LAUNCHING}\n\n${MSG_INSTALL_JAVA}\" with title \"${CFBundleName}\" buttons {\"${MSG_LATER}\", \"${MSG_VISIT_JAVA_DOT_COM}\", \"${MSG_VISIT_ADOPTIUM}\"} default button 1${DialogWithIcon}" \
                                        -e "set response to button returned of the result" \
                                        -e "if response is \"${MSG_VISIT_JAVA_DOT_COM}\" then open location \"https://www.java.com/download/\"" \
-                                       -e "if response is \"${MSG_VISIT_ADOPTOPENJDK}\" then open location \"https://adoptopenjdk.net/releases.html\""
+                                       -e "if response is \"${MSG_VISIT_ADOPTIUM}\" then open location \"https://adoptium.net/releases.html\""
                # exit with error
                exit 1
        fi