diff --git a/cereal/libcereal.a b/cereal/libcereal.a index e04dd8f8..5b1a1c69 100644 Binary files a/cereal/libcereal.a and b/cereal/libcereal.a differ diff --git a/opendbc_repo/opendbc/safety/modes/gm.h b/opendbc_repo/opendbc/safety/modes/gm.h index f3e9cc13..cfc6694d 100644 --- a/opendbc_repo/opendbc/safety/modes/gm.h +++ b/opendbc_repo/opendbc/safety/modes/gm.h @@ -689,7 +689,7 @@ static safety_config gm_init(uint16_t param) { const bool gm_ascm_int_stock_cam = gm_ascm_int && (gm_hw == GM_CAM) && gm_pcm_cruise && !gm_cam_long && !gm_pedal_long && !gm_cc_long; gm_steer_limits = GET_FLAG(param, GM_PARAM_BOLT_2017) ? &GM_BOLT_2017_STEERING_LIMITS : &GM_STEERING_LIMITS; - if (gm_hw == GM_ASCM || gm_ascm_int || gm_force_ascm) { + if ((gm_hw == GM_ASCM && !gm_sdgm) || gm_ascm_int || gm_force_ascm) { gm_long_limits = &GM_ASCM_LONG_LIMITS; } else { gm_long_limits = &GM_CAM_LONG_LIMITS; diff --git a/panda/board/obj/body_h7.bin.signed b/panda/board/obj/body_h7.bin.signed index 9f2f2489..ec434117 100644 Binary files a/panda/board/obj/body_h7.bin.signed and b/panda/board/obj/body_h7.bin.signed differ diff --git a/panda/board/obj/body_h7/bootstub.elf b/panda/board/obj/body_h7/bootstub.elf index f49640eb..cd4d2adc 100755 Binary files a/panda/board/obj/body_h7/bootstub.elf and b/panda/board/obj/body_h7/bootstub.elf differ diff --git a/panda/board/obj/body_h7/main.bin b/panda/board/obj/body_h7/main.bin index b7b4d8b3..4a7bf5f8 100755 Binary files a/panda/board/obj/body_h7/main.bin and b/panda/board/obj/body_h7/main.bin differ diff --git a/panda/board/obj/body_h7/main.elf b/panda/board/obj/body_h7/main.elf index 7b5bef91..57578b53 100755 Binary files a/panda/board/obj/body_h7/main.elf and b/panda/board/obj/body_h7/main.elf differ diff --git a/panda/board/obj/bootstub.body_h7.bin b/panda/board/obj/bootstub.body_h7.bin index 74eaa881..9583f729 100755 Binary files a/panda/board/obj/bootstub.body_h7.bin and b/panda/board/obj/bootstub.body_h7.bin differ diff --git a/panda/board/obj/bootstub.panda.bin b/panda/board/obj/bootstub.panda.bin index 7e5977b5..c3e26cfc 100755 Binary files a/panda/board/obj/bootstub.panda.bin and b/panda/board/obj/bootstub.panda.bin differ diff --git a/panda/board/obj/bootstub.panda_h7.bin b/panda/board/obj/bootstub.panda_h7.bin index 527cf7db..272d4b89 100755 Binary files a/panda/board/obj/bootstub.panda_h7.bin and b/panda/board/obj/bootstub.panda_h7.bin differ diff --git a/panda/board/obj/bootstub.panda_h7_remote.bin b/panda/board/obj/bootstub.panda_h7_remote.bin index 527cf7db..272d4b89 100755 Binary files a/panda/board/obj/bootstub.panda_h7_remote.bin and b/panda/board/obj/bootstub.panda_h7_remote.bin differ diff --git a/panda/board/obj/bootstub.panda_jungle_h7.bin b/panda/board/obj/bootstub.panda_jungle_h7.bin index cfed0f01..c3f88f79 100755 Binary files a/panda/board/obj/bootstub.panda_jungle_h7.bin and b/panda/board/obj/bootstub.panda_jungle_h7.bin differ diff --git a/panda/board/obj/bootstub.panda_remote.bin b/panda/board/obj/bootstub.panda_remote.bin index 7e5977b5..c3e26cfc 100755 Binary files a/panda/board/obj/bootstub.panda_remote.bin and b/panda/board/obj/bootstub.panda_remote.bin differ diff --git a/panda/board/obj/gitversion.h b/panda/board/obj/gitversion.h index 3dc9498d..22ce6e1a 100644 --- a/panda/board/obj/gitversion.h +++ b/panda/board/obj/gitversion.h @@ -1,2 +1,2 @@ extern const uint8_t gitversion[19]; -const uint8_t gitversion[19] = "DEV-ec152f73-DEBUG"; +const uint8_t gitversion[19] = "DEV-3bedeb4e-DEBUG"; diff --git a/panda/board/obj/panda.bin.signed b/panda/board/obj/panda.bin.signed index 1577cae3..7e7360ff 100644 Binary files a/panda/board/obj/panda.bin.signed and b/panda/board/obj/panda.bin.signed differ diff --git a/panda/board/obj/panda/bootstub.elf b/panda/board/obj/panda/bootstub.elf index f7f3c1f5..856de0d0 100755 Binary files a/panda/board/obj/panda/bootstub.elf and b/panda/board/obj/panda/bootstub.elf differ diff --git a/panda/board/obj/panda/main.bin b/panda/board/obj/panda/main.bin index 63b71ddb..1802b30c 100755 Binary files a/panda/board/obj/panda/main.bin and b/panda/board/obj/panda/main.bin differ diff --git a/panda/board/obj/panda/main.elf b/panda/board/obj/panda/main.elf index 3c6dfb3b..c0667959 100755 Binary files a/panda/board/obj/panda/main.elf and b/panda/board/obj/panda/main.elf differ diff --git a/panda/board/obj/panda_h7.bin.signed b/panda/board/obj/panda_h7.bin.signed index 406e6c5c..4064a98c 100644 Binary files a/panda/board/obj/panda_h7.bin.signed and b/panda/board/obj/panda_h7.bin.signed differ diff --git a/panda/board/obj/panda_h7/bootstub.elf b/panda/board/obj/panda_h7/bootstub.elf index 2278213b..5f5cddf0 100755 Binary files a/panda/board/obj/panda_h7/bootstub.elf and b/panda/board/obj/panda_h7/bootstub.elf differ diff --git a/panda/board/obj/panda_h7/main.bin b/panda/board/obj/panda_h7/main.bin index 68781c0c..38aff5e2 100755 Binary files a/panda/board/obj/panda_h7/main.bin and b/panda/board/obj/panda_h7/main.bin differ diff --git a/panda/board/obj/panda_h7/main.elf b/panda/board/obj/panda_h7/main.elf index fc8113e2..ddf58595 100755 Binary files a/panda/board/obj/panda_h7/main.elf and b/panda/board/obj/panda_h7/main.elf differ diff --git a/panda/board/obj/panda_h7_remote.bin.signed b/panda/board/obj/panda_h7_remote.bin.signed index e405448c..b7bdbf77 100644 Binary files a/panda/board/obj/panda_h7_remote.bin.signed and b/panda/board/obj/panda_h7_remote.bin.signed differ diff --git a/panda/board/obj/panda_h7_remote/bootstub.elf b/panda/board/obj/panda_h7_remote/bootstub.elf index 110f9966..d7508cd1 100755 Binary files a/panda/board/obj/panda_h7_remote/bootstub.elf and b/panda/board/obj/panda_h7_remote/bootstub.elf differ diff --git a/panda/board/obj/panda_h7_remote/main.bin b/panda/board/obj/panda_h7_remote/main.bin index e8bce800..b8156573 100755 Binary files a/panda/board/obj/panda_h7_remote/main.bin and b/panda/board/obj/panda_h7_remote/main.bin differ diff --git a/panda/board/obj/panda_h7_remote/main.elf b/panda/board/obj/panda_h7_remote/main.elf index c4182109..c057b325 100755 Binary files a/panda/board/obj/panda_h7_remote/main.elf and b/panda/board/obj/panda_h7_remote/main.elf differ diff --git a/panda/board/obj/panda_jungle_h7.bin.signed b/panda/board/obj/panda_jungle_h7.bin.signed index 21b0fcae..4456f14b 100644 Binary files a/panda/board/obj/panda_jungle_h7.bin.signed and b/panda/board/obj/panda_jungle_h7.bin.signed differ diff --git a/panda/board/obj/panda_jungle_h7/bootstub.elf b/panda/board/obj/panda_jungle_h7/bootstub.elf index 62c3075e..846fedb1 100755 Binary files a/panda/board/obj/panda_jungle_h7/bootstub.elf and b/panda/board/obj/panda_jungle_h7/bootstub.elf differ diff --git a/panda/board/obj/panda_jungle_h7/main.bin b/panda/board/obj/panda_jungle_h7/main.bin index d3714912..6beb82d6 100755 Binary files a/panda/board/obj/panda_jungle_h7/main.bin and b/panda/board/obj/panda_jungle_h7/main.bin differ diff --git a/panda/board/obj/panda_jungle_h7/main.elf b/panda/board/obj/panda_jungle_h7/main.elf index 79d9233e..90a7ffaa 100755 Binary files a/panda/board/obj/panda_jungle_h7/main.elf and b/panda/board/obj/panda_jungle_h7/main.elf differ diff --git a/panda/board/obj/panda_remote.bin.signed b/panda/board/obj/panda_remote.bin.signed index 55216ee5..24217c73 100644 Binary files a/panda/board/obj/panda_remote.bin.signed and b/panda/board/obj/panda_remote.bin.signed differ diff --git a/panda/board/obj/panda_remote/bootstub.elf b/panda/board/obj/panda_remote/bootstub.elf index 9708febf..f553abc9 100755 Binary files a/panda/board/obj/panda_remote/bootstub.elf and b/panda/board/obj/panda_remote/bootstub.elf differ diff --git a/panda/board/obj/panda_remote/main.bin b/panda/board/obj/panda_remote/main.bin index 4191781e..b9818a9c 100755 Binary files a/panda/board/obj/panda_remote/main.bin and b/panda/board/obj/panda_remote/main.bin differ diff --git a/panda/board/obj/panda_remote/main.elf b/panda/board/obj/panda_remote/main.elf index 6ac901f8..46f41a90 100755 Binary files a/panda/board/obj/panda_remote/main.elf and b/panda/board/obj/panda_remote/main.elf differ diff --git a/panda/board/obj/version b/panda/board/obj/version index 94fcdc73..23a9efb0 100644 --- a/panda/board/obj/version +++ b/panda/board/obj/version @@ -1 +1 @@ -DEV-ec152f73-DEBUG \ No newline at end of file +DEV-3bedeb4e-DEBUG \ No newline at end of file diff --git a/scripts/laptop_device_build.sh b/scripts/laptop_device_build.sh index 8dae02bb..18a92eb3 100755 --- a/scripts/laptop_device_build.sh +++ b/scripts/laptop_device_build.sh @@ -105,6 +105,7 @@ ensure_image_exists() { "${engine}" build --pull --platform linux/arm64 -f tools/laptop_device_build/Dockerfile -t "${IMAGE_NAME}" . fi assert_image_arch "${engine}" + ensure_image_capnp_version "${engine}" } assert_image_arch() { @@ -116,6 +117,41 @@ assert_image_arch() { fi } +expected_capnp_version() { + local raw_version="" + raw_version="$(sed -n 's/^#elif CAPNP_VERSION != \([0-9][0-9]*\)$/\1/p' "${ROOT_DIR}/cereal/gen/cpp/custom.capnp.h" | head -n 1)" + [[ -n "${raw_version}" ]] || err "Unable to determine expected Cap'n Proto version from cereal/gen/cpp/custom.capnp.h." + + local major=$(( raw_version / 1000000 )) + local minor=$(( (raw_version / 1000) % 1000 )) + local micro=$(( raw_version % 1000 )) + echo "${major}.${minor}.${micro}" +} + +image_capnp_version() { + local engine="$1" + "${engine}" run --rm --platform linux/arm64 "${IMAGE_NAME}" bash -lc "capnp --version | awk '{print \$4}'" 2>/dev/null || true +} + +ensure_image_capnp_version() { + local engine="$1" + local expected actual + expected="$(expected_capnp_version)" + actual="$(image_capnp_version "${engine}")" + + if [[ "${actual}" == "${expected}" ]]; then + return + fi + + echo "Container image ${IMAGE_NAME} has Cap'n Proto ${actual:-unknown}, expected ${expected}. Rebuilding it now..." + "${engine}" build --pull --platform linux/arm64 -f tools/laptop_device_build/Dockerfile -t "${IMAGE_NAME}" . + + actual="$(image_capnp_version "${engine}")" + if [[ "${actual}" != "${expected}" ]]; then + err "Container image ${IMAGE_NAME} still has Cap'n Proto ${actual:-unknown} after rebuild; expected ${expected}." + fi +} + assert_runtime_machine() { local engine="$1" local machine diff --git a/system/loggerd/encoderd b/system/loggerd/encoderd index 78d3cec5..42cbb65b 100755 Binary files a/system/loggerd/encoderd and b/system/loggerd/encoderd differ diff --git a/tools/laptop_device_build/Dockerfile b/tools/laptop_device_build/Dockerfile index 3d5151ca..8a4cf86c 100644 --- a/tools/laptop_device_build/Dockerfile +++ b/tools/laptop_device_build/Dockerfile @@ -1,5 +1,7 @@ FROM ghcr.io/commaai/openpilot-base-aarch64:latest +ARG CAPNP_VERSION=1.3.0 + ENV PYTHONUNBUFFERED=1 ENV UV_LINK_MODE=copy WORKDIR /work @@ -7,6 +9,8 @@ WORKDIR /work # Keep this image minimal; dependency resolution is done by uv inside the workspace. # rsync/ssh-client are needed for optional sysroot sync from a comma device. RUN apt-get update && apt-get install -y --no-install-recommends \ + ca-certificates \ + curl \ rsync \ openssh-client \ e2fsprogs \ @@ -14,12 +18,26 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ qemu-user-static \ gcc-aarch64-linux-gnu \ g++-aarch64-linux-gnu \ + cmake \ qtbase5-private-dev \ python3-pip \ xz-utils \ git \ && rm -rf /var/lib/apt/lists/* +RUN set -eux; \ + tmpdir="$(mktemp -d)"; \ + curl -fsSL "https://github.com/capnproto/capnproto/archive/refs/tags/v${CAPNP_VERSION}.tar.gz" | tar -xz -C "${tmpdir}"; \ + cmake -S "${tmpdir}/capnproto-${CAPNP_VERSION}/c++" -B "${tmpdir}/build" \ + -DBUILD_TESTING=OFF \ + -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_INSTALL_PREFIX=/usr/local; \ + cmake --build "${tmpdir}/build" -j"$(nproc)"; \ + cmake --install "${tmpdir}/build"; \ + ldconfig; \ + capnp --version; \ + rm -rf "${tmpdir}" + RUN /usr/bin/python3 -m pip install --no-cache-dir --break-system-packages uv # Fix for "dubious ownership" git errors when mounting folders on Linux hosts.