From bcf847e58a10b66cff3161dd3503bc839c9745f0 Mon Sep 17 00:00:00 2001 From: Lucas Hecht Date: Sat, 27 Feb 2016 01:26:54 +0100 Subject: added "Troubleshooting" section to PCB guide --- keyboard/planck/PCB_GUIDE.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'keyboard/planck/PCB_GUIDE.md') diff --git a/keyboard/planck/PCB_GUIDE.md b/keyboard/planck/PCB_GUIDE.md index 3daf0e009..e676c4428 100644 --- a/keyboard/planck/PCB_GUIDE.md +++ b/keyboard/planck/PCB_GUIDE.md @@ -8,6 +8,7 @@ 2. Install [DFU-Programmer][dfu-prog] (the -win one). 3. Start DFU bootloader on the chip first time you will see 'Found New Hardware Wizard' to install driver. If you install device driver properly you can find chip name like 'ATmega32U4' under 'LibUSB-Win32 Devices' tree on 'Device Manager'. If not you will need to update its driver on 'Device Manager' to the `dfu-programmer` driver. + ### Mac If you're using homebrew, you can use the following commands: @@ -52,6 +53,27 @@ Generally, the instructions to flash the PCB are as follows: 4. Press the reset button on the PCB/press the key with the `RESET` keycode 5. `make dfu` - use the necessary `KEYMAP=` and/or `COMMON=true` arguments here. +### Troubleshooting +If you see something like this + + 0 [main] sh 13384 sync_with_child: child 9716(0x178) died before initialization with status code 0xC0000142 + 440 [main] sh 13384 sync_with_child: *** child state waiting for longjmp + /usr/bin/sh: fork: Resource temporarily unavailable + +after running 'make' on Windows than you are encountering a very popular issue with WinAVR on Windows 8.1 and 10. +You can easily fix this problem by replacing msys-1.0.dll in WinAVR/utils/bin with [this one](http://www.madwizard.org/download/electronics/msys-1.0-vista64.zip). +Restart your system and everything should work fine! + +If you see this + + dfu-programmer atmega32u4 erase + process_begin: CreateProcess(NULL, dfu-programmer atmega32u4 erase, ...) failed. + make (e=2): The system cannot find the file specified. + make: *** [dfu] Error 2 + +when trying to 'make dfu' on Windows you need to copy the dfu-programmer.exe to qmk_firmware/keyboard/planck. + + ## Quantum MK Firmware ### Keymap -- cgit v1.2.3 From 52b3ddb521ebe510a0674a69ce4f5ef208ea871f Mon Sep 17 00:00:00 2001 From: Lucas Hecht Date: Sat, 27 Feb 2016 02:56:05 +0100 Subject: Update PCB_GUIDE.md --- keyboard/planck/PCB_GUIDE.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'keyboard/planck/PCB_GUIDE.md') diff --git a/keyboard/planck/PCB_GUIDE.md b/keyboard/planck/PCB_GUIDE.md index e676c4428..28e8a4b08 100644 --- a/keyboard/planck/PCB_GUIDE.md +++ b/keyboard/planck/PCB_GUIDE.md @@ -53,7 +53,7 @@ Generally, the instructions to flash the PCB are as follows: 4. Press the reset button on the PCB/press the key with the `RESET` keycode 5. `make dfu` - use the necessary `KEYMAP=` and/or `COMMON=true` arguments here. -### Troubleshooting +## Troubleshooting If you see something like this 0 [main] sh 13384 sync_with_child: child 9716(0x178) died before initialization with status code 0xC0000142 @@ -64,6 +64,7 @@ after running 'make' on Windows than you are encountering a very popular issue w You can easily fix this problem by replacing msys-1.0.dll in WinAVR/utils/bin with [this one](http://www.madwizard.org/download/electronics/msys-1.0-vista64.zip). Restart your system and everything should work fine! + If you see this dfu-programmer atmega32u4 erase -- cgit v1.2.3 From 06de9628be3ba17e1d6753b9af21c7072d4badd9 Mon Sep 17 00:00:00 2001 From: Noah Andrews Date: Wed, 2 Mar 2016 12:25:21 -0500 Subject: Removed unneeded lines from setup script --- keyboard/planck/PCB_GUIDE.md | 17 +++++++++++++++-- setup-environment-win.bat | 5 +---- 2 files changed, 16 insertions(+), 6 deletions(-) (limited to 'keyboard/planck/PCB_GUIDE.md') diff --git a/keyboard/planck/PCB_GUIDE.md b/keyboard/planck/PCB_GUIDE.md index 3daf0e009..d2ff70335 100644 --- a/keyboard/planck/PCB_GUIDE.md +++ b/keyboard/planck/PCB_GUIDE.md @@ -4,8 +4,21 @@ ### Windows -1. Install [WinAVR Tools](http://sourceforge.net/projects/winavr/) for AVR GCC compiler. -2. Install [DFU-Programmer][dfu-prog] (the -win one). +Options +1. Vagrant (overkill, lack of trust, no driver concerns) +2. Chocolatey / dfu-programmer (more dev work required) +3. Chocolatey / flip +4. Write a batch script that installs dfu-programmer on the path, installs make with MinGW, and uses pnputil to install the proper driver https://technet.microsoft.com/en-us/library/cc732377%28v=ws.10%29.aspx?f=255&MSPPError=-2147217396#BKMK_Anchor2 +4. Look up altenatives ( + +* Install [MHV AVR Tools](https://github.com/jackhumbert/qmk_firmware). Disable smatch, but be sure to leave the option to add the tools to the PATH checked. +* Install the latest version of [the Atmel AVR **8-bit** toolchain](http://www.atmel.com/tools/atmelavrtoolchainforwindows.aspx) +* Install [MinGW](https://sourceforge.net/projects/mingw/files/Installer/mingw-get-setup.exe/download). During installation, uncheck the option to install a graphical user interface. **DO NOT change the default installation folder.** The script depends on the default location. +* Right-click on the setup-path-win batch script at the root of the project and select "Run as administrator". Press the spacebar to dismiss the success message. +* + +1. Install [Chocolatey](https://chocolatey.org/). It's a package manager for Windows that will make it easy to set up the complete build environment. To install Chocolatey, run the following command in a command line window with administrator privileges (search for command prompt, right-click on it, and select "Run as administrator"). `@powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1'))" && SET PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin` +2. Install DFU-Programmer by running (the -win one). 3. Start DFU bootloader on the chip first time you will see 'Found New Hardware Wizard' to install driver. If you install device driver properly you can find chip name like 'ATmega32U4' under 'LibUSB-Win32 Devices' tree on 'Device Manager'. If not you will need to update its driver on 'Device Manager' to the `dfu-programmer` driver. ### Mac diff --git a/setup-environment-win.bat b/setup-environment-win.bat index ae803da6f..1fbd35a69 100644 --- a/setup-environment-win.bat +++ b/setup-environment-win.bat @@ -6,12 +6,9 @@ if NOT ["%errorlevel%"]==["0"] ( exit ) -mingw-get install mingw32-make-bin mingw32-gcc-bin msys-wget-bin msys-unzip-bin +mingw-get install msys-wget-bin msys-unzip-bin cd \MinGW\bin -REM It would be somewhat better to use symlinks, but then it wouldn't work in XP or Vista. -copy mingw32-make.exe make.exe - mkdir temp cd temp wget http://iweb.dl.sourceforge.net/project/dfu-programmer/dfu-programmer/0.7.2/dfu-programmer-win-0.7.2.zip -- cgit v1.2.3 From 45933e84f178ae92506f4c1bfdc5a8dc30e587d2 Mon Sep 17 00:00:00 2001 From: Noah Andrews Date: Wed, 2 Mar 2016 13:02:13 -0500 Subject: Added documentation for new Windows scripts --- keyboard/planck/PCB_GUIDE.md | 22 +++++----------------- 1 file changed, 5 insertions(+), 17 deletions(-) (limited to 'keyboard/planck/PCB_GUIDE.md') diff --git a/keyboard/planck/PCB_GUIDE.md b/keyboard/planck/PCB_GUIDE.md index d2ff70335..e396747df 100644 --- a/keyboard/planck/PCB_GUIDE.md +++ b/keyboard/planck/PCB_GUIDE.md @@ -3,23 +3,11 @@ ## Setting up the environment ### Windows - -Options -1. Vagrant (overkill, lack of trust, no driver concerns) -2. Chocolatey / dfu-programmer (more dev work required) -3. Chocolatey / flip -4. Write a batch script that installs dfu-programmer on the path, installs make with MinGW, and uses pnputil to install the proper driver https://technet.microsoft.com/en-us/library/cc732377%28v=ws.10%29.aspx?f=255&MSPPError=-2147217396#BKMK_Anchor2 -4. Look up altenatives ( - -* Install [MHV AVR Tools](https://github.com/jackhumbert/qmk_firmware). Disable smatch, but be sure to leave the option to add the tools to the PATH checked. -* Install the latest version of [the Atmel AVR **8-bit** toolchain](http://www.atmel.com/tools/atmelavrtoolchainforwindows.aspx) -* Install [MinGW](https://sourceforge.net/projects/mingw/files/Installer/mingw-get-setup.exe/download). During installation, uncheck the option to install a graphical user interface. **DO NOT change the default installation folder.** The script depends on the default location. -* Right-click on the setup-path-win batch script at the root of the project and select "Run as administrator". Press the spacebar to dismiss the success message. -* - -1. Install [Chocolatey](https://chocolatey.org/). It's a package manager for Windows that will make it easy to set up the complete build environment. To install Chocolatey, run the following command in a command line window with administrator privileges (search for command prompt, right-click on it, and select "Run as administrator"). `@powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1'))" && SET PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin` -2. Install DFU-Programmer by running (the -win one). -3. Start DFU bootloader on the chip first time you will see 'Found New Hardware Wizard' to install driver. If you install device driver properly you can find chip name like 'ATmega32U4' under 'LibUSB-Win32 Devices' tree on 'Device Manager'. If not you will need to update its driver on 'Device Manager' to the `dfu-programmer` driver. +1. Install [MHV AVR Tools](https://github.com/jackhumbert/qmk_firmware). Disable smatch, but **be sure to leave the option to add the tools to the PATH checked**. +2. Install [MinGW](https://sourceforge.net/projects/mingw/files/Installer/mingw-get-setup.exe/download). During installation, uncheck the option to install a graphical user interface. **DO NOT change the default installation folder.** The scripts depend on the default location. +3. Clone this repository. [This link will download it as a zip file, which you'll need to extract.](https://github.com/jackhumbert/qmk_firmware/archive/master.zip) Open the extracted folder in Windows Explorer. +4. Right-click on the 1-setup-path-win batch script, select "Run as administrator", and accept the User Account Control prompt. Press the spacebar to dismiss the success message in the command prompt that pops up. +5. Right-click on the 2-setup-environment-win batch script, select "Run as administrator", and accept the User Account Control prompt. This part may take a couple of minutes, and you'll need to approve a driver installation, but once it finishes, your environment is complete! ### Mac -- cgit v1.2.3 From 140a311e652829cb8c774d3d3bb4acdb7c9f9954 Mon Sep 17 00:00:00 2001 From: Noah Andrews Date: Wed, 2 Mar 2016 13:06:33 -0500 Subject: Fix link to MHV AVR Tools --- keyboard/planck/PCB_GUIDE.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'keyboard/planck/PCB_GUIDE.md') diff --git a/keyboard/planck/PCB_GUIDE.md b/keyboard/planck/PCB_GUIDE.md index e396747df..797cee2e1 100644 --- a/keyboard/planck/PCB_GUIDE.md +++ b/keyboard/planck/PCB_GUIDE.md @@ -3,7 +3,7 @@ ## Setting up the environment ### Windows -1. Install [MHV AVR Tools](https://github.com/jackhumbert/qmk_firmware). Disable smatch, but **be sure to leave the option to add the tools to the PATH checked**. +1. Install [MHV AVR Tools](https://infernoembedded.com/sites/default/files/project/MHV_AVR_Tools_20131101.exe). Disable smatch, but **be sure to leave the option to add the tools to the PATH checked**. 2. Install [MinGW](https://sourceforge.net/projects/mingw/files/Installer/mingw-get-setup.exe/download). During installation, uncheck the option to install a graphical user interface. **DO NOT change the default installation folder.** The scripts depend on the default location. 3. Clone this repository. [This link will download it as a zip file, which you'll need to extract.](https://github.com/jackhumbert/qmk_firmware/archive/master.zip) Open the extracted folder in Windows Explorer. 4. Right-click on the 1-setup-path-win batch script, select "Run as administrator", and accept the User Account Control prompt. Press the spacebar to dismiss the success message in the command prompt that pops up. -- cgit v1.2.3