From 273621e6c457b11d63ae7fac11dae1549cfc12ff Mon Sep 17 00:00:00 2001 From: Nic Aitch Date: Sat, 10 Jun 2017 18:31:43 -0500 Subject: [PATCH 1/2] Add more flashing details --- flashing.md | 79 ++++++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 72 insertions(+), 7 deletions(-) diff --git a/flashing.md b/flashing.md index 1051a4a..1706640 100644 --- a/flashing.md +++ b/flashing.md @@ -18,17 +18,82 @@ +This guide covers flashing with OSX and Linux. If you're using Windows head over to [/u/CampAsAChamp's Windows Guide](https://github.com/CampAsAChamp/LetsSplitWindowsGuide) for this part. + +## Prerequisites + +Install avrdude + +### OSX + +``` +$ brew install avrdude +``` + +### Ubuntu + +``` +sudo add-apt-repository ppa:pmjdebruijn/avrdude-release +sudo apt-get update +sudo apt-get install avrdude +``` + +### Raspberry Pi + +``` +echo "deb http://apt.adafruit.com/raspbian/ jessie main" | sudo tee --append /etc/apt/sources.list +wget -O - -q https://apt.adafruit.com/apt.adafruit.com.gpg.key | sudo apt-key add - +sudo apt-get update +sudo apt-get install avrdude dfu-programmer gcc-avr avr-libc +``` + +### Other Linux flavors + +Probably google it, but feel free to open a PR if you'd like to expand this section. + ## Which side do I flash? -See the QMK firmware section on [Flashing](https://github.com/qmk/qmk_firmware/tree/master/keyboards/lets_split#flashing) for an up to date explanation. +Both sides must be flashed. They may optionally be connected when flashing, but you'll still need to plug the USB into each side and flash it. + +## Choose which side you want to plug the USB cable into (choose a master side) -## Windows +### Left side as master -See [/u/CampAsAChamp's Windows Guide](https://github.com/CampAsAChamp/LetsSplitWindowsGuide) +This is the default. No extra configuration is needed. + +### Right side as master + +Add a `config.h` file to your keymap directory if it doesn't exist then add this flag to it: + +```c +#define MASTER_RIGHT +``` + +### Either side as master + +Add a `config.h` file to your keymap directory if it doesn't exist then add this flag to it: + +```c +#define EE_HANDS +``` + +Now flash the eeprom on each side: + +Left side: + +``` +avrdude -p atmega32u4 -P $(COM_PORT) -c avr109 -U eeprom:w:eeprom-lefthand.eep +``` + +Right side: + +``` +avrdude -p atmega32u4 -P $(COM_PORT) -c avr109 -U eeprom:w:eeprom-righthand.eep +``` -## OSX, Linux +NOTE: replace `$(COM_PORT)` with the port of your device (e.g. `/dev/ttyACM0`) -### Build Keymap (QMK) +## Build Keymap (QMK) From the lets_split directory: @@ -40,7 +105,7 @@ Don't forget to replace `YOUR_KEYMAP_NAME` with the actual name of your keymap. You'll now have a .hex file that we can use to flash. -### Bootloader +## Bootloader Connect RST and GND to enter bootloader. If you're using an official Sparkfun Pro Micro (the red one) you need to short this twice quickly. @@ -48,7 +113,7 @@ You will have 8 seconds to flash before it continues on to the sketch. > Tip: If this is the first time the Pro Micro has been flashed it should go directly to the bootloader on start. -### Flash +## Flash QMK now includes a very easy way to automatically find the serial port and flash without having to race the bootloader. From the keymap directory type (`$` indicates the prompt. Don't type that): From 858f53183cd6be4a2926ee929d278220488a6c41 Mon Sep 17 00:00:00 2001 From: Nic Aitch Date: Sat, 10 Jun 2017 18:32:23 -0500 Subject: [PATCH 2/2] Update toc --- flashing.md | 17 ++++++++++++----- getting-pcbs.md | 12 ++++++++++++ 2 files changed, 24 insertions(+), 5 deletions(-) diff --git a/flashing.md b/flashing.md index 1706640..9e2b04e 100644 --- a/flashing.md +++ b/flashing.md @@ -4,12 +4,19 @@ -- [Windows](#windows) +- [Prerequisites](#prerequisites) + - [OSX](#osx) + - [Ubuntu](#ubuntu) + - [Raspberry Pi](#raspberry-pi) + - [Other Linux flavors](#other-linux-flavors) - [Which side do I flash?](#which-side-do-i-flash) -- [OSX, Linux](#osx-linux) - - [Build Keymap (QMK)](#build-keymap-qmk) - - [Bootloader](#bootloader) - - [Flash](#flash) +- [Choose which side you want to plug the USB cable into (choose a master side)](#choose-which-side-you-want-to-plug-the-usb-cable-into-choose-a-master-side) + - [Left side as master](#left-side-as-master) + - [Right side as master](#right-side-as-master) + - [Either side as master](#either-side-as-master) +- [Build Keymap (QMK)](#build-keymap-qmk) +- [Bootloader](#bootloader) +- [Flash](#flash) - [Troubleshooting](#troubleshooting) - [Programmer not responding](#programmer-not-responding) - [Can't open device](#cant-open-device) diff --git a/getting-pcbs.md b/getting-pcbs.md index 8db2968..443723a 100644 --- a/getting-pcbs.md +++ b/getting-pcbs.md @@ -1,3 +1,15 @@ + + +**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)* + +- [Getting the PCBs](#getting-the-pcbs) + - [Buying today](#buying-today) + - [Ordering PCBs using Gerber files](#ordering-pcbs-using-gerber-files) + - [History](#history) + - [Helpful references](#helpful-references) + + + # Getting the PCBs ## Buying today