Skip to content

Instantly share code, notes, and snippets.

View chrismatthieu's full-sized avatar
🚀
Hacking on robots!

Chris Matthieu chrismatthieu

🚀
Hacking on robots!
View GitHub Profile
@chrismatthieu
chrismatthieu / gist:ad3a6d083924af1468067778a50017fb
Last active October 21, 2026 00:51
Running Corebrum on Omarchy
Corebrum will run on that ThinkPad as the existing Linux binary. Omarchy is Arch, so skip the APT instructions in the README and install the release tarball plus a matching Zenoh router.
Checked on this machine: Omarchy 4.0.5, x86_64, glibc 2.44. uname -m printed x86_64. If it prints aarch64, use the aarch64 assets in the same steps. The binaries need only libc, libgcc, libm, and (for corebrum) libz. There is no Zenoh router package in the Arch repos. AUR has zenoh-c and zenoh-cpp, which are not this router. Corebrum 0.3.9 talks to Zenoh 1.10.1.
1. Install the two programs
The Corebrum git repo is private. The same 0.3.9 Linux archive is public, so GitHub login is not required:
https://corebrum-releases.s3.amazonaws.com/releases/v0.3.9/corebrum-x86_64-unknown-linux-gnu.tar.xz
sha256: 044a3fa539a081768e4fc04ba2a43f4ca75f9d7747ee2b2fde11ce9b89bd2399
# AgenticROS / OpenClaw Startup Optimization
## Purpose
This document describes a startup-performance problem discovered when loading AgenticROS as an OpenClaw plugin, the diagnostic changes made on a deployed NVIDIA Jetson installation, what we learned, and what still needs to be implemented cleanly in the AgenticROS source repository.
**Important:** The deployed copy under `~/.agenticros/plugin-deploy` contains experimental diagnostic modifications. Do **not** blindly copy that directory over the source repository.
The goal is to translate the proven optimizations into maintainable source changes while preserving all AgenticROS transports and functionality.
@chrismatthieu
chrismatthieu / gist:d7a6bb016a98df931e048c2a9ca82771
Created September 17, 2026 15:17
realsense mp4 video example
import pyrealsense2 as rs
import cv2
import numpy as np
width = 1280
height = 720
fps = 30
output_path = "realsense_rgb.mp4"
pipeline = rs.pipeline()
"I was thinking about building a new RealSense stereo camera demo project, but wanted to run it by you to see if it's practical. It might be interesting to use the RGB camera or sensor on the RealSense camera to film like a short movie, and then use the stereo depth sensors to set like the depth of the movie. Like, say, film everything one meter and closer, and then see if we can put a green screen on everything behind the one meter depth range or whatever variable we set, so that it's like filming on a green screen studio but in about in the real world. Do you think one, this is doable, and then do you think two, this is useful? I would call this a RealSense GreenScreen app"
Yes — this is very doable, and I think it could make a surprisingly compelling RealSense demo. In computer-vision terms, what you’re describing is essentially real-time depth keying: instead of chroma-keying pixels based on “is this pixel green?”, you key them based on “is this pixel farther than X meters away?”
With a RealSense stereo
You cannot set a temperature threshold on a RealSense camera via the SDK; instead, you can read the internal temperature and use the information to determine if the camera is operating within safe limits. The laser will automatically adjust power or shut off if the projector temperature exceeds a threshold (around \(60^{\circ }C\)) to protect the camera. You can access the temperature values like rs.option.asic_temperature or rs.option.projector_temperature through the SDK, for example, by using sensor.get_option() in Python. How to get the temperature Start streaming: Begin streaming from the camera using rs.pipeline() and pipeline.start().Get the sensor: Obtain the sensor object for the depth sensor using pipeline_profile.get_device().first_depth_sensor().Access the temperature option: Call sensor.get_option() with the appropriate option. For example, to get the ASIC temperature, use rs.option.asic_temperature.For D400 series: Use rs.option.projector_temperature or rs.option.asic_temperature.For L500 series
import rclpy
from rclpy.node import Node
from geometry_msgs.msg import Twist
class TwistSubscriber(Node):
def __init__(self):
super().__init__('twist_subscriber')
self.subscription = self.create_subscription(
Twist,
'cmd_vel',
import time
import json
def fibonacci_recursive(n):
"""Generate Fibonacci sequence using recursion (inefficient for large n)."""
if n <= 0:
return []
elif n == 1:
return [0]
elif n == 2:
@chrismatthieu
chrismatthieu / factorial.py
Created October 13, 2025 22:09
corebrum demo
import time
import json
def factorial(n):
"""Compute factorial of n recursively."""
if n < 0:
raise ValueError("Factorial is not defined for negative numbers")
if n == 0 or n == 1:
return 1
return n * factorial(n - 1)
#!/bin/bash
set -e # Exit immediately if a command exits with a non-zero status
# --- Helper Functions ---
# Function for timed confirmation, takes message and function name to run
timed_confirm() {
local message=$1
local function_to_run=$2
local timeout=5 # seconds
@chrismatthieu
chrismatthieu / Rules.md
Created September 9, 2025 20:08
National Coding Week (https://codingweek.org/) RealSense Developer Challenge — Rules

National Coding Week (https://codingweek.org/) RealSense Developer Challenge — Rules

Sponsor: RealSense, Inc. (the “Sponsor”).

Eligibility: Open to individuals 18 years or older. Void where prohibited. No purchase necessary.

How to Enter:

During National Coding Week, a new RealSense challenge will be posted daily on Reddit.