diff --git a/CHANGELOG.md b/CHANGELOG.md index 2b3784c..5c0b2ac 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Release History +## Version 1.0.1 + +- Switched from WinAVR to MHV AVR Tools to add support for ATmega32U2 controllers in AVRDude +- Added more console output to enhance usability + ## Version 1.0.0 - Initial release diff --git a/README.md b/README.md index 31f7ddd..3d4f66f 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ A typical series of steps would be to first 1. scan for serial ports, `petrockutil scan serial`, then 2. read the firmware version, `petrockutil gamepadblock readversion `, and then 3. if you do not have AVRDude installed, install it, `petrockutil gamepadblock prepare`, -3. update the firmware, `petrockutil gamepadblock update `, +3. update the firmware, `petrockutil gamepadblock update `. # Download diff --git a/commands/gamepadblock.go b/commands/gamepadblock.go index 2ff1314..b8718ba 100644 --- a/commands/gamepadblock.go +++ b/commands/gamepadblock.go @@ -40,7 +40,8 @@ func GamepadBlock() cli.Command { fmt.Println(" # Reads the version number of the current firmware on the GamepadBlock at given port") fmt.Println() fmt.Println(" petrockutil gamepadblock prepare") - fmt.Println(" # Installs avrdude to allow uploading of firmware .hex files to GamepadBlock") + fmt.Println(" # Installs avrdude to allow uploading of firmware .hex files to GamepadBlock.") + fmt.Println(" # Console needs to be run as administrator.") fmt.Println() fmt.Println(" petrockutil gamepadblock update ") fmt.Println(" # Updates firmware of GamepadBlock at provided port to most recent version") @@ -111,6 +112,7 @@ func GamepadBlock() cli.Command { cmd.Stdout = os.Stdout cmd.Stderr = os.Stderr if err := cmd.Run(); err != nil { + fmt.Println("Something went wrong. Is brew (https://brew.sh) installed?") log.Fatal(err) } @@ -121,10 +123,10 @@ func GamepadBlock() cli.Command { os.Exit(1) } - fmt.Println("Installing winavr...") + fmt.Println("Installing AVR Tools ...") fmt.Printf("Initial value for $PATH: %s\n", os.Getenv("PATH")) dirName, _ := createPetrockblockDirectory() - exeFile := "https://downloads.petrockblock.com/petrockutil/WinAVR-20100110-install.exe" + exeFile := "https://downloads.petrockblock.com/petrockutil/MHV_AVR_Tools_20131101.exe" fileName := downloadFromUrl(dirName, exeFile) cmd := exec.Command(petrockblockDirName() + "\\" + fileName) cmd.Stdout = os.Stdout @@ -132,12 +134,13 @@ func GamepadBlock() cli.Command { if err := cmd.Run(); err != nil { log.Fatal(err) } + fmt.Println("Installation successful. Please restart the console.") default: fmt.Println("OS not yet supported.") } case "update": - if len(c.Args()) < 1 { + if len(c.Args()) < 2 { fmt.Println("Invalid number of arguments.") usage() return @@ -150,6 +153,7 @@ func GamepadBlock() cli.Command { fmt.Println("Downloading the latest firmware") filename := downloadLatestFirmware() + defer os.Remove(filename) fmt.Println("Downloaded firmware file", filename) fmt.Println("Press the RESET button on the GameapadBlock to activate its update mode.") @@ -165,6 +169,7 @@ func GamepadBlock() cli.Command { log.Fatal(err) fmt.Println("An error occurred during the firmware update process") } + fmt.Println("Finished firmware update on port", port) default: diff --git a/petrockutil.sublime-workspace b/petrockutil.sublime-workspace index f760663..4862806 100644 --- a/petrockutil.sublime-workspace +++ b/petrockutil.sublime-workspace @@ -123,14 +123,6 @@ }, "buffers": [ - { - "file": "petrockutil.go", - "settings": - { - "buffer_size": 324, - "line_ending": "Unix" - } - } ], "build_system": "", "build_system_choices": @@ -235,10 +227,14 @@ "build_varint": "", "command_palette": { - "height": 89.0, - "last_filter": "9o", + "height": 389.0, + "last_filter": "link", "selected_items": [ + [ + "link", + "MarkdownEditing: New Inline Link" + ], [ "9o", "GoSublime: Activate 9o" @@ -504,7 +500,7 @@ "Package Control: Remove Package" ] ], - "width": 428.0 + "width": 508.0 }, "console": { @@ -525,8 +521,17 @@ "side_bar_visible": false, "status_bar_visible": false }, + "expanded_folders": + [ + "/Users/florian/Programming/go/src/github.com/petrockblog/petrockutil" + ], "file_history": [ + "/Users/florian/Programming/go/src/github.com/petrockblog/petrockutil/CHANGELOG.md", + "/Users/florian/Programming/go/src/github.com/petrockblog/petrockutil/README.md", + "/Users/florian/Programming/go/src/github.com/petrockblog/petrockutil/Makefile", + "/Users/florian/Programming/go/src/github.com/petrockblog/petrockutil/petrockutil.go", + "/Users/florian/Programming/go/src/github.com/petrockblog/petrockutil/deployArchives.sh", "/Users/florian/Programming/go/petrockutil/src/commands/util.go", "/Users/florian/.zshrc", "/Users/florian/Programming/go/petrockutil/src/petrockutil.sublime-project", @@ -649,16 +654,11 @@ "/Users/florian/Downloads/N64_Arduino/N64_Arduino.pde", "/Users/florian/Programming/Github/GamepadBlock/downloadFirmware", "/Users/florian/Programming/Github/GamepadBlock/downloadFirmwareViaBTL.sh", - "/Users/florian/Programming/Github/GamepadBlock/VirtualSerial/VirtualSerial.h", - "/Users/florian/Programming/Github/GamepadBlock/VirtualSerial/makefile", - "/Users/florian/Programming/Github/GamepadBlock/VirtualSerial/VirtualSerial.c", - "/Users/florian/Programming/Github/GamepadBlock/src/makefile", - "/Users/florian/Programming/Github/GamepadBlock/makefile", - "/Users/florian/Programming/Github/GamepadBlock/VirtualSerial/Config/LUFAConfig.h" + "/Users/florian/Programming/Github/GamepadBlock/VirtualSerial/VirtualSerial.h" ], "find": { - "height": 39.0 + "height": 23.0 }, "find_in_files": { @@ -672,6 +672,13 @@ "case_sensitive": false, "find_history": [ + "VERSION", + "version", + "VERSION", + "GOARCH_2", + "darwin", + "linux", + "GOARCH" ], "highlight": true, "in_selection": false, @@ -689,43 +696,8 @@ "groups": [ { - "selected": 0, "sheets": [ - { - "buffer": 0, - "file": "petrockutil.go", - "semi_transient": false, - "settings": - { - "buffer_size": 324, - "regions": - { - }, - "selection": - [ - [ - 0, - 0 - ] - ], - "settings": - { - "encoding_helper_encoding": "UTF-8", - "encoding_thread_running": true, - "incomplete_sync": null, - "remote_loading": false, - "synced": false, - "syntax": "Packages/GoSublime/syntax/GoSublime-Go.sublime-syntax", - "translate_tabs_to_spaces": false - }, - "translation.x": 0.0, - "translation.y": 0.0, - "zoom_level": 1.0 - }, - "stack_index": 0, - "type": "text" - } ] } ], @@ -897,7 +869,7 @@ "show_minimap": true, "show_open_files": true, "show_tabs": true, - "side_bar_visible": true, + "side_bar_visible": false, "side_bar_width": 256.0, "status_bar_visible": true, "template_settings": diff --git a/version.go b/version.go index f6739c8..64db728 100644 --- a/version.go +++ b/version.go @@ -1,4 +1,4 @@ package main // VERSION of the software -const VERSION = "1.0.0" +const VERSION = "1.0.1"