Giter Site home page Giter Site logo

lostsnail42 / buspirate5-firmware Goto Github PK

View Code? Open in Web Editor NEW

This project forked from dangerousprototypes/buspirate5-firmware

0.0 0.0 0.0 3 MB

Bus Pirate v5 Firmware

License: MIT License

Python 0.23% C 99.08% Makefile 0.22% HTML 0.14% CMake 0.30% MAXScript 0.01% Dockerfile 0.02% Shell 0.01%

buspirate5-firmware's Introduction

Bus Pirate 5

Bus Pirate 5 is the latest edition of the universal serial interface trusted by hackers since 2008.

Can't get a chip to work? Is it the circuit, code, bad part or a burned out pin? The Bus Pirate sends commands over common serial protocols (1-Wire, I2C, SPI, UART, MIDI, serial LEDs, etc) so you can get to know a chip before prototyping. Updated with tons of new features, talking to chips and probing interfaces is more fun than ever!

Resources

VT100 terminal interface

VT100 terminal emulation supports color and a live statusbar view of the voltage and functions on each pin. Type simple commands into the terminal, the Bus Pirate translates them into popular serial protocols and displays the response. Learn how a chip works without touching a line of code.

Specifications

  • Raspberry Pi RP2040 with 128Mbit program flash
  • 8 powerful IO pins - Support multiple protocols from 1.2-5volts. Analog voltage measurement and optional 10K pull-ups on all pins
  • 1-5volt output power supply - 0-500mA current limit, current sense, resettable fuse and protection circuit
  • 1Gbit NAND flash - Store settings and files. Appears as a USB drive.
  • LCD - A beautiful 240x320 pixel color IPS (all angle viewing) LCD acts as a pin label, while also showing the voltage on each pin and the current consumption of the programmable power supply unit
  • 18 RGB LEDs - It's customary to have an indicator LED, so to check that box we added 16 SK6812 RGB LEDs.
  • Just one button - 18 party LEDs but just one button!
  • 1-Wire, I2C, SPI, UART, MIDI, serial LEDs supported, more to come!

Bus Pirate 5 is the universal serial interface tool designed by hackers, for hackers. It's crammed full of hardware and firmware features to make probing chips pleasant and easy.

Build

This project uses cmake as the build system, so building the project only takes 2 steps:

  1. project configuration (needs to be ran once, or when you want to change configuration).
    cmake -S . -B build -DPICO_SDK_FETCH_FROM_GIT=TRUE
    you may want to add the flags -DPICO_SDK_PATH=/path/to/pico-sdk -DPICO_SDK_FETCH_FROM_GIT=FALSE if you want to use pico-sdk that is in your local path.

    NOTE: WINDOWS users: for some reason the automatic fetch fails because of git submodule, so you will need to clone pico-sdk your self, and then apply the following commands inside the pico-sdk repo:

    git submodule init
    git submodule update
  2. project build
    cmake --build ./build --target bus_pirate5_rev10
    you may set bus_pirate5_rev10 to bus_pirate5_rev8 if the have the development version.

build using docker

Instructions on the forum provide additional details; however, this repo provides a docker compose image for you to just get running quickly in the event you want to try patching/hacking. To run a build, perform the following actions on linux:

# clone the repo
git clone [email protected]:DangerousPrototypes/BusPirate5-firmware.git
cd BusPirate5-firmware

# build the environment
docker compose bui

# run a build
UID=$(id -u) GID=$(id -g) docker compose run dev build-clean
# build stuff happens ...
# [100%] Linking CXX executable bus_pirate5_rev10.elf
# Memory region         Used Size  Region Size  %age Used
#            FLASH:      460068 B         2 MB     21.94%
#              RAM:      256168 B       256 KB     97.72%
#        SCRATCH_X:          4 KB         4 KB    100.00%
#        SCRATCH_Y:          0 GB         4 KB      0.00%
# [100%] Built target bus_pirate5_rev10
# your build will be placed in ./build/

# Or drop into the container and run builds manually
UID=$(id -u) GID=$(id -g) docker compose run dev

patching pico SDK

By default, pico-sdk assumes that we have 2MB of flash available, and there is no way to configure different flash size.
In reality, buspirate5 has 16MB of flash, if we want to fully utilize the available flash, we need to do the following modifications (currently it is not needed because buspirate5 firmware size is less than 2MB).

  1. open file src/rp2_common/pico_standard_link/memmap_default.ld
  2. change the line:
    FLASH(rx) : ORIGIN = 0x10000000, LENGTH = 2048k
    to: FLASH(rx) : ORIGIN = 0x10000000, LENGTH = 16384k
  3. save the file and locally commit the change.

Building without LGPL3 protected component

NOTE by doing the following you may not need to distribute the binaries under LGPL3 license terms.

To compile the firmware without LGPL3 components, simply add the following flags to the configuration step above:
-DUSE_LGPL3=NO -DLEGACY_ANSI_COLOURS_ENABLED=NO

Other open source licenses

This project uses code from the following licenses:

  • LGPL3
  • BSD 3 clause

More information on the licenses and components being used can be found here.

Contributing

Please see contributing.md

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.