Jump to content

Lumix GX8 hacking: firmware decrypted, a working PC emulator, and a question about getting code onto the camera


gavenomix
 Share

Recommended Posts

Hi all,

Since I got my GX8 years ago when it came out, I've been dreaming about modding it. Enter the AI reverse-engineering era and I've made significant progress myself using Claude Code. I joined Anthropic's Cyber Verification Program for security research, and we've been doing the work carefully, mostly on an emulator built alongside the real camera.

Here is Claude's breakdown of where we're at:

******CLAUDE OUTPUT START******

- Firmware decrypted with the key read from my own camera over the service-mode USB (read-only). Method and tools: https://github.com/gavenomix/lumix-gx8-usb-service 
- A PC emulator that runs the real GX8 firmware: four ARM cores, the camera's own loaders,  menus, touch, Playback, live view with a stand-in picture, and the official firmware update from a pretend SD card. You click it in a browser. MIT licence, no firmware included - you bring your own: https://github.com/gavenomix/lumix-gx8-emulator
- Small mods run in the emulator: CineLike D/V selectable in P/A/S/M, and my own C code drawing on the shooting screen.

What I found when looking for a way to get code onto the actual camera:

1. No "run from the card" path in the stock GX8 firmware that I could find. In every start mode I could make the emulator do (normal, service, the hidden key combinations, wake, every dial position), the firmware only reads card files as data - the update file, ROM BACKUP files, a playback cache, logs. Nothing gets loaded and run. I also matched every card command against the file layer, and read the chip's top of memory on the real camera for any built-in factory boot code: nothing visible.
2. So, like the GM5 / GX9 work on GitHub (flickering-star), the only road I see is a signed-update workaround in one powered session. I've rehearsed it end to end in the emulator (it writes a small test mod and the camera boots with it), but I have not tried it on my camera. On the GX8 there's no factory recovery image route that I know of, and a power cut at the wrong moment of a flash looks unrecoverable, so I'm being slow about it.

Questions, if anyone can help:

- Andrew / Magic Lumix: on the GX80, does the USB "activation" leave something persistent in the camera (a setting, a flag), or is it RAM-only each time? I'd love to know whether the GX8, which is very close to the GX80, could ever take the same approach - the stock GX8 firmware doesn't seem to run anything from the card by itself.
- Anyone who has flashed a modified GX80 / GX85 / GX8 / G7: what was your way back if it went wrong? Has anyone recovered a bricked camera of this family?
- Hardware people: anyone with a spare GX8 / GX80 main board, or experience reading and writing the 1 Gbit NAND on these boards with a programmer? That would be the real safety net.
- And anyone who knows the Venus Engine hardware (timers, image processor, display, lens protocol) - lots of the emulator is educated guesswork, help welcome.

******CLAUDE OUTPUT END******

It's pretty wild I even got here. If there are any questions, I'll do my best to answer (or ask Claude to).

Link to comment
Share on other sites

EOSHD Pro Color 5 for Sony cameras EOSHD Z LOG for Nikon CamerasEOSHD C-LOG and Film Profiles for All Canon DSLRs
  • Administrators

Nice! Claude cyber verification programme look at you mr fancy pants! 😉

GX8 stick to RAM persistence only to be safe and see if it clears RAM between normal power on/off/sleep cycles. If it keeps RAM alive then that makes a hack that persists in just RAM more viable. If it clears it and cold boots every time then connecting to USB to re-hack it at every power cycle defeats the usability and you would need to look at the more risky firmware writes.

Regarding GX80/etc. way back in if anything goes wrong - there is officially no known way back from a brick yet. Camera crashes are common during the dev process but shouldn't brick it. If you start to mod the bootloader and make firmware writes, a bug there can be fatal however - and even Claude Mythos isn't bulletproof, it writes buggy code like even the best human coders occasionally does.

Safety net of physically reading NAND would be an incredible amount of expense and difficulty, involve opening the guts of the camera, in fact I doubt anyone outside of Panasonic service centres can do it. If something goes wrong, best just to buy another GX8.

Just a quick reminder for all those new folk joining - I am happy to help other people with hacks but please credit me on your social media / YouTube stuff and Github front page if you advance with the help of my advice.

Link to comment
Share on other sites

50 minutes ago, Andrew - EOSHD said:

Nice! Claude cyber verification programme look at you mr fancy pants! 😉

GX8 stick to RAM persistence only to be safe and see if it clears RAM between normal power on/off/sleep cycles. If it keeps RAM alive then that makes a hack that persists in just RAM more viable. If it clears it and cold boots every time then connecting to USB to re-hack it at every power cycle defeats the usability and you would need to look at the more risky firmware writes.

Regarding GX80/etc. way back in if anything goes wrong - there is officially no known way back from a brick yet. Camera crashes are common during the dev process but shouldn't brick it. If you start to mod the bootloader and make firmware writes, a bug there can be fatal however - and even Claude Mythos isn't bulletproof, it writes buggy code like even the best human coders occasionally does.

Safety net of physically reading NAND would be an incredible amount of expense and difficulty, involve opening the guts of the camera, in fact I doubt anyone outside of Panasonic service centres can do it. If something goes wrong, best just to buy another GX8.

Just a quick reminder for all those new folk joining - I am happy to help other people with hacks but please credit me on your social media / YouTube stuff and Github front page if you advance with the help of my advice.

Thanks Andrew! Good shout on RAM persistence. Full power-off cold boots (the firmware re-copies its RAM data at every start), but the bootloader has a wake-from-sleep path that skips reloading the program and keeps RAM. That's next on my list to check. If it holds, a RAM-only hack could survive sleep and only need re-applying after a real power-off. And on NAND: I can already read the whole chip over the service USB, it's writing it back from a dead camera that's the impossible part. Will credit you if this goes anywhere.

Link to comment
Share on other sites

9 minutes ago, Andrew - EOSHD said:

I might open source Magic Lumix this weekend.

The pro features aren't ready yet and will be for Patreon supporters but the hack itself - let's open it up

That seems like a solid middle ground. I’m personally very much in favor of open source but also get your reasons behind being hesitant. Makes sense. 

Link to comment
Share on other sites

10 hours ago, Andrew - EOSHD said:

I might open source Magic Lumix this weekend.

The pro features aren't ready yet and will be for Patreon supporters but the hack itself - let's open it up

A freemium model might be a good strategy for Magic Lumix.

It would generate some good will and build a solid user-base (which will help to fend off the inevitable haters and trolls) and also setup a pipeline for people who value the extra features enough to pay for them which rewards you for the hard work and creativity and risk you've put into building something like this.

I never understood the idea that creative people shouldn't get paid - the ideas of a "starving artist" somehow having more integrity and someone who isn't starving is a "sell-out" are completely toxic.  It takes many years to develop the skills and each piece of their work potentially took many hours of effort and often a surprising amount of raw materials and expenses to create.

A fair exchange is paying for what you like and find useful.

Link to comment
Share on other sites

  • Administrators

I really am in a bit of dilemma how to do it. I don't like the freemium and subscription models much, it's the model mobile apps use when they're not good enough to justify a one off tenner. I can't do this project to the standard I want to do it, for free. And at the same time, closed-source and paid doesn't seem like a great fit either. I'll really do have to choose one though don't i? 🙂

Link to comment
Share on other sites

  • Administrators

It all depends if it becomes a full time job - it is the sort of thing that can turn into one that's for sure, a permanent part of EOSHD or will it just be a flash in the pan? Anything more than a temporary hobby can't be developed and supported on no money, it'll have to have investment. So thanks to everyone who has donated so far.

Link to comment
Share on other sites

Quick update, and an answer to Andrew's RAM question.

Does the GX8 keep RAM over sleep? Read from the code and run in the emulator (not yet watched on the camera itself):

- On the GX8 "sleep" and "power off" are the same routine. There is no resume that carries on where it left off.
- A wake is a full restart: the loaders run again and jump into the main program at its normal entry. The only difference is that RAM is kept and the main program is not read from the chip again.
- On that restart the firmware re-copies all of its initialised data and clears its zeroed data, with no "is this a wake?" test in front of either. So a value poked into the firmware's data is back to its default after any sleep / wake, not just after a battery pull.
- The flip side: because the program image itself is not reloaded on a wake, a change made to the code as it sits in RAM should outlive a sleep and only go away when power is really removed. I have not tested that and I do not know yet whether the plug-in modules behave the same way.

So for the GX8: a RAM-only data tweak lasts one session; a RAM-only code change might last until the battery comes out. Both need the cable and a PC each time.

Other things from this week, all read-only on the camera:

- Pulling the USB cable in service mode and plugging it back in does not restart the camera; the service interface just comes back.
- A trap for anyone poking RAM on the ARM Lumix bodies: the service commands will happily take the 0x8xxxxxxx address of a RAM cell, but the firmware itself uses the low address, and the chip's page table maps both as separate cacheable views. Write and read back through the high one and you can "verify" a value the firmware never sees. Use the address the firmware uses.
- In the emulator the camera's idle shut-down in service mode comes about 5 min 20 s after the last touch or key, and it is a real save to the chip. Worth knowing before you leave a camera sitting half-way through something.

Where the project is: the whole "own file through the normal updater" chain still only runs in the emulator. I had the one tool that would write to the camera reviewed four times by independent passes before letting it near the body; the first three found real bugs. Nothing has been written to the camera yet. The honest blocker is the same one Andrew named: no known way back from a bad flash, so I am not in a hurry.

Andrew - thanks for the push on the RAM question, it was the right one to ask. If you do open the Magic Lumix source I would love to compare notes on how the GX80 gets its code running.

Link to comment
Share on other sites

14 hours ago, Andrew - EOSHD said:

I really am in a bit of dilemma how to do it. I don't like the freemium and subscription models much, it's the model mobile apps use when they're not good enough to justify a one off tenner. I can't do this project to the standard I want to do it, for free. And at the same time, closed-source and paid doesn't seem like a great fit either. I'll really do have to choose one though don't i? 🙂

It's also the model that BM use with Resolve, and many other highly reputable digital products use.  Even physical products are often a loss-leader to get someone into your ecosystem.

Psychologically it's hard to get someone to part with anything, and the freemium model would essentially allow people to try the product without overcoming that initial hurdle.  Then once they've enjoyed the free features that you're giving away (reduced sharpening and increased bitrate and UI improvements) then if they decide they want the RAW or LOG profiles or whatever then they can pay for them.

It's an interesting space and who knows what will happen.  In the music equipment space several manufacturers have actually released updates or SDKs that allow more hacking rather than less, as they saw that there was demand there.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • EOSHD Pro Color 5 for All Sony cameras
    EOSHD C-LOG and Film Profiles for All Canon DSLRs
    EOSHD Dynamic Range Enhancer for H.264/H.265
×
×
  • Create New...