Code Monkey home page Code Monkey logo

binary-diff-mbedos5's Introduction

Binary diff application demo - SD card

Using JANPatch. Does binary patching of firmware using FATFileSystem on Mbed OS 5.

There is also a demo which uses BlockDevice instead.

Takes:

  • Source binary.
  • Diff file.

Produces:

  • A new binary.

This application does not use dynamically allocated memory. See macro in main.cpp.

Usage

  1. Put demo/blinky-k64f-old.bin and demo/blinky.patch on an SD card.

  2. Put SD card in FRDM-K64F development board.

  3. Build this application:

    $ mbed compile -m K64F -t GCC_ARM
    
  4. Run the application and inspect serial output (on baud rate 9,600).

  5. When the application is done, inspect the SD card. blinky-k64f-new.bin should have appeared, and it should match the file in the demo directory:

    $ diff /Volumes/SD/blinky-k64f-new.bin demo/blinky-k64f-new.bin
    
    # should not return anything
    

How to create diffs

See the documentation for JANPatch.

binary-diff-mbedos5's People

Contributors

janjongboom avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

binary-diff-mbedos5's Issues

Question: How to apply binary diff, when you don't have an external flash and you need to do it on internal flash.

Hi Jan,

I am not sure if you are monitoring this repository any longer. Anyway I thought just incase I will ask my question :). We are planning on transmitting firmware updates over LORAWAN. We currently have a custom board, which has an mDot and BLE Module. So we want to transmit firmware updates to both the mDot and BLE Module. I came across this repository which demonstrates the example for using an external SD card or flash to eventually merge the diff file with the original file. How would I go about doing it on the internal flash using the FlashIAP API in mbed os 5. We eventually plan on adding an external flash to the BLE Module, but until then I was wondering if you have any suggestions, how I could extend your BDFile to support internal flash too?

Thanks,
Yogesh

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.