Skip to content

Instantly share code, notes, and snippets.

///// TODO : Replace <<LAN_INTERFACE>> with internal bridge or lan interface, replace <<<PPPOE_DIGI_INTERFACE>>> with the pppoe-digi interface
/ipv6 nd
set [ find default=yes ] disabled=yes
add advertise-dns=yes interface=<<LAN_INTERFACE>>
/ipv6 dhcp-client
add add-default-route=yes interface=<<<PPPOE_DIGI_INTERFACE>>> pool-name=pool6 request=address,prefix script=":del\
ay 5s;\
\n/ipv6 address remove [find advertise=yes]\
@coldcue
coldcue / encode_dji_oa5pro_video.sh
Last active August 11, 2026 19:33
Batch re-encode DJI Osmo Action 5 Pro footage to HEVC (libx265, HLG-safe, metadata transfer)
#!/bin/bash
# Batch re-encode DJI action-camera footage to HEVC (libx265, crf 24, medium
# preset). Developed and tested with DJI Osmo Action 5 Pro recordings:
# 4K 29.97 fps HEVC ~56 Mbps, 10-bit HLG HDR (BT.2020 / ARIB STD-B67),
# AAC-LC stereo audio, plus DJI extra tracks (djmd/dbgi telemetry with
# per-frame accelerometer, shutter speed and color temperature; a tmcd
# timecode track; embedded cover-art/preview JPEGs).
#
# What it does per file:
# - keeps only the main video + audio streams; audio is copied untouched
@coldcue
coldcue / encode_dji_oa4_dlogm_hdr_video.sh
Created August 12, 2026 07:20
DJI Osmo Action 4 D-Log M (10-bit) to HDR (HLG/BT.2020) batch encoder - outputs MP4s recognized as HDR on iPhone/QuickTime/TVs
#!/bin/bash
# Batch re-encode DJI Osmo Action 4 D-Log M (10-bit) footage to HEVC
# (libx265, crf 30, slow preset) as HDR .mp4 files that iPhones, QuickTime,
# Photos, Apple TV and HDR TVs recognize and play as HDR (HLG).
#
# Source format (Osmo Action 4, "10-bit D-Log M" color mode):
# 4K 29.97 fps HEVC ~90 Mbps, yuv420p10le, container/VUI tagged plain
# BT.709 limited range, AAC-LC stereo audio, plus DJI extra tracks
# (djmd/dbgi telemetry, tmcd timecode, embedded cover-art/preview JPEGs).
#