All Projects → Coldcard → Firmware

Coldcard / Firmware

Licence: other
❄️ Firmware and simulator for Coldcard Hardware Wallet

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Firmware

Lightning Onion
Onion Routed Micropayments for the Lightning Network
Stars: ✭ 297 (+50%)
Mutual labels:  bitcoin, cryptocurrency, cryptography
Lnd
Lightning Network Daemon ⚡️
Stars: ✭ 5,623 (+2739.9%)
Mutual labels:  bitcoin, cryptocurrency, cryptography
Bitcoin
Bitcoin Core integration/staging tree
Stars: ✭ 60,211 (+30309.6%)
Mutual labels:  bitcoin, cryptocurrency, cryptography
Golden Wallet React Native
Golden - Best Wallet Ever
Stars: ✭ 201 (+1.52%)
Mutual labels:  bitcoin, cryptocurrency, bitcoin-wallet
Qtum
Qtum Core Wallet
Stars: ✭ 1,080 (+445.45%)
Mutual labels:  bitcoin, cryptocurrency, cryptography
Aeternity
æternity: solving scalability problems by making sense of state-channels
Stars: ✭ 923 (+366.16%)
Mutual labels:  bitcoin, cryptocurrency, cryptography
Lopp.net
Personal web site of Jameson Lopp
Stars: ✭ 174 (-12.12%)
Mutual labels:  bitcoin, cryptocurrency, cryptography
Bitcoin Cryptography Library
Nayuki's implementation of cryptographic primitives used in Bitcoin.
Stars: ✭ 81 (-59.09%)
Mutual labels:  bitcoin, cryptocurrency, cryptography
Blockchain Papers
区块链相关的有价值的文献
Stars: ✭ 20 (-89.9%)
Mutual labels:  bitcoin, cryptocurrency, cryptography
Ipchain
IPChain Core Wallet
Stars: ✭ 26 (-86.87%)
Mutual labels:  bitcoin, cryptocurrency, cryptography
Lightning Rfc
Lightning Network Specifications
Stars: ✭ 1,224 (+518.18%)
Mutual labels:  bitcoin, cryptocurrency, cryptography
Bot18
Bot18 is a high-frequency cryptocurrency trading bot developed by Zenbot creator @carlos8f
Stars: ✭ 157 (-20.71%)
Mutual labels:  bitcoin, cryptocurrency, cryptography
Bismuth
[Migrated] The first Python blockchain protocol and platform
Stars: ✭ 186 (-6.06%)
Mutual labels:  bitcoin, cryptocurrency
Unstoppable Wallet Android
A secure and decentralized Bitcoin and other cryptocurrency wallet for Android phones. Supports Bitcoin, Ethereum, EOS, Binance Chain, Bitcoin Cash, DASH, ...
Stars: ✭ 165 (-16.67%)
Mutual labels:  bitcoin, cryptocurrency
Zips
Zcash Improvement Proposals
Stars: ✭ 188 (-5.05%)
Mutual labels:  cryptocurrency, cryptography
Bitcoinecdsa.php
PHP library to generate BTC addresses and signatures from private keys.
Stars: ✭ 169 (-14.65%)
Mutual labels:  bitcoin, cryptography
Blockchain Tutorial
🌾 A step-by-step blockchain tutorial in simplified Chinese
Stars: ✭ 2,081 (+951.01%)
Mutual labels:  bitcoin, cryptocurrency
Bdk
A modern, lightweight, descriptor-based wallet library written in Rust!
Stars: ✭ 168 (-15.15%)
Mutual labels:  bitcoin, bitcoin-wallet
Cbpro Trader
Automated cryptocurrency trading on Coinbase Pro (formerly gdax-trader)
Stars: ✭ 171 (-13.64%)
Mutual labels:  bitcoin, cryptocurrency
Zeus
A mobile Bitcoin/Lightning app for lnd, c-lightning, and Eclair node operators ⚡️
Stars: ✭ 175 (-11.62%)
Mutual labels:  bitcoin, cryptocurrency

Coldcard Wallet

Coldcard is a Cheap, Ultra-secure & Opensource Hardware Wallet for Bitcoin. Get yours at ColdcardWallet.com

Follow @COLDCARDwallet on Twitter to keep up with the latest updates and security alerts.

coldcard logo

coldcard picture front coldcard picture back

Reproducible Builds

To have confidence this source code tree is the same as the binary on your device, you can rebuild it from source and get exactly the same bytes. This process has been automated using Docker. Steps are as follows:

  1. Install Docker and start it.

  2. Install make (GNUMake) if you don't already have it.

  3. Checkout the code, and start the process.

    git clone https://github.com/Coldcard/firmware.git cd firmware/stm32 make repro

  4. At the end of the process a clear confirmation message is shown, or the differences.

  5. Build products can be found firmware/stm32/built.

Check-out and Setup

Do a checkout, recursively to get all the submodules:

git clone --recursive https://github.com/Coldcard/firmware.git

Then:

  • cd firmware
  • git submodule update --init (if needed?)
  • brew install autogen
  • virtualenv -p python3 ENV (Python > 3.5 is required)
  • source ENV/bin/activate (or source ENV/bin/activate.csh based on shell preference)
  • pip install -r requirements.txt

Setup and Run the Desktop-based Coldcard simulator:

  • cd unix; make setup && make; ./simulator.py

Building the firmware:

  • cd ../cli; pip install --editable .
  • cd ../stm32; make setup && make; make firmware-signed.dfu
  • The resulting file, firmware-signed.dfu can be loaded directly onto a Coldcard, using this command (already installed based on above)
  • ckcc upgrade firmware-signed.dfu

Which looks like this:

[ENV] [firmware/stm32 42] ckcc upgrade firmware-signed.dfu
675328 bytes (start @ 293) to send from 'firmware-signed.dfu'
Uploading  [##########--------------------------]   29%  0d 00:01:04

MacOS

You'll probably need to install at least these packages:

brew install --cask xquartz
brew install sdl2 xterm
brew install --cask gcc-arm-embedded

Used to be these were needed as well:

brew tap PX4/px4
brew search px4
brew install px4/px4/gcc-arm-none-eabi-80 (latest gcc-arm-none-eabi-XX, currently 80)

You may need to reboot to avoid a DISPLAY is not set error.

Linux

You'll probably need to install these (Ubuntu 16):

apt install libudev-dev python-sdl2 gcc-arm-none-eabi

If you get stuck on the "Skip PIN" screen after the startup, edit the pyb.py file located under /unix/frozen-modules/ and follow the instructions from line 27 to line 31:

# If on linux, try commenting the following line
addr = bytes([len(fn)+2, socket.AF_UNIX] + list(fn))
# If on linux, try uncommenting the following two lines
#import struct
#addr = struct.pack('H108s', socket.AF_UNIX, fn)

Code Organization

Top-level dirs:

shared

  • shared code between desktop test version and real-deal
  • expected to be largely in python, and higher-level

unix

  • unix (MacOS) version for testing/rapid dev
  • this is a simulator for the product

testing

  • test cases and associated data

stm32

  • embedded micro version, for actual product
  • final target is a binary file for loading onto hardware

external

  • code from other projects, ie. the dreaded submodules

stm32/bootloader

  • 32k of factory-set code that you cannot change
  • however, you can inspect what code is on your coldcard and compare to this.

hardware

  • schematic and bill of materials for the Coldcard

unix/work/MicroSD

  • files on "simulated" microSD card

Support

Found a bug? Email: [email protected]

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].