Skip to content

Instantly share code, notes, and snippets.

@a-a
Last active October 21, 2025 01:00
Show Gist options
  • Select an option

  • Save a-a/f52de60506f12375315bf2425f0b3ebb to your computer and use it in GitHub Desktop.

Select an option

Save a-a/f52de60506f12375315bf2425f0b3ebb to your computer and use it in GitHub Desktop.
lassen

Assisted cold starting a Trimble Lassen SK-8 II

like how humans can form emotional bonds to roombas, i just think its cool that we made silicon stargaze too ✨

Lassen will search using up to 8 channels, for any satellite at all.

When Lassen finds a satellite it will try to download almanac. You need stable lock for at least 15 minutes because the download is slow....

Help Lassen along by saying where you are, so it can figure out just how pretty the sky will be. But the sky moves, so if you have even a partial almanac download, tell lassen what week it is from the GPS epoch. Almanac time wraps too, so don't sweat the rollover. When Lassen knows where to look, and what time they will be there, the search is more effective.

I used the below warm.py to create the warm start hints. Officially you can also load almanac, but I figured downloading is also okay, I just wanted initial search to be faster.

Remember Start 0x10 and end 0x10 0x03, if sending outside of VTS.

Sure, it's no ublox zed. But it's nice to see they still have some life left.

If in doubt, consult the System Reference Manual

Troubleshooting

Poor SV lock

Old little receiver will struggle. Before warm starting:

  • Is your antenna away from noise sources?
  • Is it one of those horrible modern wideband antennas? Use an old L1 only antenna. Lassen only knows L1 anyways. Anything wider and you can desense the RX.
  • Don't worry about VTS saying the year is something in the 2000s. It's cosmetic. Just load the right week number and eventually it can burst to life. They wrap at 1024 anyways, so Lassen knows only dates until Jan 2016. Trimble say officially it's good until 2015. After then, your dates will be wonky, but almanac's week number wraps too. As I said, cosmetic.

NACK (or error in VTS) when sending 2E

Power cycle receiver. It's seen something from satellites and thinks you are lying to it. In fairness I would be confused if two sources tell me different things too.

Invalid TSIP sent by Lassen

Power cycle receiver. If battery is fitted, disconnect and make your beverage of choice, reconect after you are distracted for a while.

What happened? Not so sure, but I think something overflowed. Second time it seems to come back okay. I'm sure I read this in one of the manuals about WNRO events anyways.

#! /usr/bin/env python3
import struct
from datetime import datetime, timezone, timedelta
lat="51.5701055"
lon="-0.1016616"
alt="100"
# Command Packet 0x2B
# Bytes 0-3 Single: Latitude, Radians, north
# Bytes 4-7 Single: Longitude, Radians, east
# Bytes 8-11 Single: Altitude, Meters
# Command Packet 0x2E
# Bytes 0-3 Single: GPS Time of Week, Seconds
# Bytes 4-5 Integer: Extended GPS week number
def encsingle(in_str):
return fs(struct.pack('>f',float(in_str)).hex())
def fs(hex_str):
hex_str = hex_str.upper()
return ' '.join(hex_str[i:i+2] for i in range(0, len(hex_str), 2))
def enctime(utc_dt):
delta = utc_dt - datetime(1980, 1, 6, tzinfo=timezone.utc)
return (delta.days % 7) * 86400 + delta.seconds , delta.days // 7
print("2B"+" "+encsingle(lat)+" "+encsingle(lon)+" "+encsingle(alt))
tow, week = enctime(datetime.now(timezone.utc))
print("2E" +" "+ encsingle(tow) +" "+ fs(struct.pack('>H', week).hex()))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment