Readit News logoReadit News
ge0rg commented on SonyShell – An effort to “SSH into my Sony DSLR”   github.com/goudvuur/sonys... · Posted by u/beligum
dvdkon · 3 months ago
Great to see another Samsung NX hacker in the wild! I'm in the process of developing a mod for my NX300 and NX30 (with the NX2000 likely compatible). It doesn't do anything yet, but I've got a lot of work done on hooking ARM code [0] and compiling modern C++ for the cameras.

Personally I think the NX300/30/2000 are the most hackable cameras ever made, even compared to the NX1/500. The read-only rootfs isn't really a barrier, since the software runs a shell script from the SD card on boot (or rather resume from hibernation, it's a pretty clever system). And unlike the newer models, they don't have an RTOS coprocessor, so everything is handled in the easier-to-modify Linux code. It's not a design decision I would have made, but it makes in-depths mods easier.

The older cameras are also easy to unbrick, since the bootloader files used for firmware flashing without a working OS were released in the FLOSS code dump. The availability of some C headers in that dump is the cherry on top.

I'll admit I'd still rather have an NX500, I just bought the NX300 because I'm cheap :)

[0]: https://gitlab.com/dvdkon/pahil

ge0rg · 3 months ago
Yeah, I've documented a thing or two about the NX series on https://op-co.de/blog/tags/samsung-nx/

Regarding the RTOS, I took my NX300 from the shelf some weeks ago to make a few shots for the live demo at https://programm.froscon.org/froscon2025/talk/fc37ae17-9264-... and OH MY FSCKING GOD IT'S SLOW! I made a burst shot of a model train approaching, and the camera was busy processing it for multiple minutes. The NX500 is lightning fast in comparison, and the NX1 is even snappier.

So what do you plan to do with the ARM hook? I've poked at different places of di-camera-binary, but never at the processing pipeline, and there are soooo many things to reverse-engineer, and I'm but one person!

ge0rg commented on SonyShell – An effort to “SSH into my Sony DSLR”   github.com/goudvuur/sonys... · Posted by u/beligum
bayindirh · 3 months ago
Actually, half of the problem is vertical integration inside Sony cameras. It's all Sony from sensors to DSPs, and everything is designed and built by them.

The current firmware looks like a embedded Linux system designed for fast boot and is largely immutable, so the thing is pretty tightly secured down. You can put the board to flash mode and update the firmware, but that's all apparently.

Someone over DPReview was taking deltas of the file trees between firmware update packages to guess what has been updated, but going one step further was nigh impossible.

Sony doesn't even bin the DSPs from model to model, but create model-specific ones with different model numbers, and solder DRAM on top of them for latency and signal quality, so the cameras are complete black boxes.

The only missing thing is a complete epoxy pour over the board, but that thing gets hot and needs the case as a heat-sink, so it's not possible at this stage.

ge0rg · 3 months ago
The other half of the problem is what to gain from a root shell. You can't influence the stages of the image processing without a PhD in Sony DSP Reverse Engineering, and so what remains is probably hooking into the camera controls and injecting key events to re-invent time-lapse timers or bulb exposures, and removing the 30min video recording limit.

This is where the NX mod project arrived - additional hooks into the camera controls and a few changes to internal registers left over by Samsung engineers for debugging, like silent shutter or the 30min limit.

ge0rg commented on SonyShell – An effort to “SSH into my Sony DSLR”   github.com/goudvuur/sonys... · Posted by u/beligum
jauntywundrkind · 3 months ago
The fact that USB ptp is some baseline is kind of exceedingly great, even if yeah in practice it'a a huge mess of vendor extensions tacked on. I like trying to have some collaboration & specs! It's a monster oh sure but gphoto2 probably wouldn't have come about, as a sick compendium of all camera backs & vendor extensions, if there wasn't a common thread, common binding for cameras! Once you go from USB to IP you're (generally) untethered unmoored from anything shared!

What's done here is super admirable & super neat. But it's even more spelunking into the unknown than USB ptp imo! Thankfully there's some pretty old school direct on-the-line protocols that are kinda just working!

It's interesting to me at least to navel gaze over. The attempt to have common tools versus the just doing whatever.

One of my favorite connectivity solutions ever was the Nvidia Shield Controller (2015). A wifi (wifi direct/wifi-p2p at that!) video gaming controller. With audio that uses ozproto's stack, a usb-over-ip setup! Something about just tunneling USB being conceptually easier to reason about & do than deciding what IP services to make for a controller is so elegant and neat and weird. https://github.com/devmapal/nvidia-shield-controller-driver

ge0rg · 3 months ago
When reverse-engineering some of the Samsung NX camera firmware files, I found USB-PTP code that implements different custom remote commands <https://chaos.social/@ge0rg/114723076401717110> but I'm not deep enough into PTP to make sense of them.

Is there anywhere a group focusing on understanding and re-implementing custom PTP protocols?

ge0rg commented on SonyShell – An effort to “SSH into my Sony DSLR”   github.com/goudvuur/sonys... · Posted by u/beligum
underlines · 3 months ago
Reading the title, I thought: finally someone rooted/jailbroke sony cameras.

On Canon you can run Magic Lantern, an extensive mod that adds many features to Canon cameras.

Even Samsung N1 had SD Card loadable mods before they moved away from the camera market.

Rooting sony seems impossible, I never saw someone Working on it Since their Fullframe lineup launched.

ge0rg · 3 months ago
The last two generations of Samsung NX cameras were built around Tizen Linux, and it was (and still is) easy to get a root shell on them. They still make great photos and you still can buy them used for a good price.

NX300/NX30/NX2000 had a read-only rootfs, but for NX500 and NX1 there was a persistent mod that extended camera functionality with a menu, and you can actually SSH into them and rsync your photos... while shooting!

Background: I've recently taken over maintenance of the NX-KS mod at https://github.com/ge0rg/nx-ks-mod

ge0rg commented on Reverse-engineering Fujitsu M7MU RELC hardware compression   op-co.de/blog/posts/fujit... · Posted by u/ge0rg
bragr · 8 months ago
Interesting write-up. Does anyone have any context about Fujitsu RELC? Why a proprietary algorithm? Any particular advantages or features?
ge0rg · 8 months ago
Looks like it was invented by two Fujitsu engineers, is free of patents and maybe was optimized for hardware implementation? I've linked some Japanese sources in the post, but I don't speak Japanese and the auto translation is not easy to read.

u/ge0rg

KarmaCake day3481April 1, 2010
About
Ph.D., IT Security consultant, geek.

[ my public key: https://keybase.io/ge0rg; my proof: https://keybase.io/ge0rg/sigs/IbGDkSaF88bGZ5TR2pBfzVgSpIjQIR2ujem0AQx0qms ]

View Original