GithubHelp home page GithubHelp logo

nmbvr / uv_k5_playground Goto Github PK

View Code? Open in Web Editor NEW

This project forked from piotr022/uv_k5_playground

0.0 0.0 0.0 25.34 MB

Shell 0.01% C++ 2.16% Python 0.12% C 21.32% Assembly 0.07% CMake 0.76% LLVM 75.57%

uv_k5_playground's Introduction

UV_K5_playground

src/spectrum auto release build

rssi printer
update
Spectrum scanner. It prints a spectrum graph. Zoom in well as resolution can be controled via keyboard.

  • download mod uv_k5_01_26_spectrum_2MHz_encoded.bin
  • to enable spectum view press flash light button
  • hold up or down key to change center frequency
  • press 8 / 2 for zoom in / zoom out
  • press 1 / 7 to increase / decrease resolution (smaller resolution == faster update rate)
  • press PTT or EXIT to disable spectrum view

Please, consider paying tribute to the two fallen Quashengs that were bricked during the development process. Their sacrifice played a crucial role in shaping this project. To show your appreciation and support for our ongoing work, you can make a donation.

src/rssi_sbar auto release build

rssi printer
sbar with calibrated S steps

src/rssi_printer auto release build

rssi printer
mod for printing rx signal level (RSSI) in numerical format, also includes small signal level chart.

uploading to radio

src/pong auto release build

rssi printer
this is useless

flash masking and memory layout

Chinese mcu DP32G030 has feature called flash masking, here is how it works: original_memory layout

libs/k5_uv_system (par_runner)

The idea is to run this firmware 'parallel' with the original Quencheng firmware. This can be achieved by relocating the original vector table to the end of the original firmware, and placing a new vector table at the beginning, with entities pointing to the par_runner functions that wrap the original firmware handlers.
Every interrupt is first processed by the par_runner handlers, which can perform tasks like responding to a button press(todo), before invoking the original firmware handler

flash memory layout

When building the "par_runner" target automaticly "bootloader" target will be build memory layout building par_runner target will result in following outputs:

  • par_runner.bin / .hex - right part of image, can be used to generate encrypted firmware compatible with orginal Quescheng update tool
  • bootloader.bin - stripped bootloader from orginal firmware
  • par_runner_with_bootloader.bin - complete firmware image

To change the original firmware that will be wrapped and placed into the original firmware section, replace ./original_fw/original_fw.bin or set the variable CMakeLists.txt set(ORGINAL_FW_BIN orginal_fw.bin) in ./orginal_fw/CMakeLists.txt and rebuild par_runner

build system installation

currently tested on windows, requred:

  • arm-none-eabi-gcc
  • python (i have newest version)
  • cmake
  • ninja
  • open-ocd

All folders with executables of the above programs should be added to the PATH environment variable.

for debugging:

  • vs code
    • Cortex-Debug plugin
    • CMake plugin

building

via terminal

$ mkdir build $ cd build $ cmake ../ -G Ninja $ ninja par_runner outputs ./build/src/par_runner/par_runner.bin / hex / elf

uploading

$ ninja par_runner_flash

via VS Code

Select the par_runner build target in the bottom bar and press build.

uploading

Enter the 'Run & Debug' tab, select 'kwaczek DBG', and press run.

useful links

  • currently firmare that is wrapped by par_runner comes from Tunas1337 mod k5_26_encrypted_18to1300MHz.bin UV-K5-Modded-Firmwares
  • crypting/encrypting/modding py tools amnemonic repo

Warning

I'm not responsible for radios bricked by this trojan xD

uv_k5_playground's People

Contributors

piotr022 avatar

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.