Monday, June 15, 2015

The Default Files Folder Pattern

Software installation best practices

When you've got critical settings files that absolutely should never be overwritten or cleared back to defaults, this pattern has always worked well for me. It can apply to both Windows, Linux and Mac based software.

The installation method can either be a simple file copy utility/archive or something more complex like a Windows installer.

An example target structure might look something like this:

/MyApplication
    /bin           => Application binaries.
    /defaults      => A default version of all
settings files.
    /docs          => Documents or manuals.
    /settings      => Critical settings files.

             
The settings folder contains the critical settings files and is not part of the installer. The installer includes only the bin, defaults and docs folders. So installing the software only overwrites bin, defaults and docs, but never the settings. This applies equally to Windows installer packages - for this case, just don't include the settings folder in the Windows installer package. The defaults folder contains the default version of all of the the files expected in the settings folder.

Whenever the software accesses a particular file in settings the following lazy initialisation logic is used ...

- Does the settings folder exist?
    - Yes: Continue
    - No:  Create the folder and continue
   
- Does the file exist?
    - Yes: Open it
    - No:  Copy the file from the
defaults folder into the
           settings folder, then open it

By following the above logic, you ensure that an existing critical settings file is never overwritten.

From reading the latest report on the deadly Airbus A400M crash, its claimed that the cause was that their software installation procedure did the equivalent of overwriting a settings file or clearing it back to defaults. In this case, the settings file contained calibration parameters that were critical to the operation of 3 out of the 4 propeller engines.

Follow @dodgy_coder

Subscribe to posts via RSS

Saturday, May 2, 2015

Taking control of a 36 year old NASA spacecraft using GNU radio

In 2014, Dennis Wingo and Keith Cowing formed the ISEE-3 Reboot Project, a crowdfunded effort to attempt to gain control of the decommissioned spacecraft for the benefit of citizen science. The team raised almost $160,000 in funding and assembled top space experts for the cause. In May, 2014, they began communicating with the spacecraft in advance of its August 10th 2014 lunar fly by.

Here's an excerpt of a brilliant podcast interview between software defined radio (SDR) specialist, Balint Seeber, and Infosec journalist, Patrick Gray, as recorded on April 24, 2015. Its the best anecdote about technology and hacking I've heard recently.

Below transcript starts at the [47m:43s] mark of the Risky Business podcast #363
.

Balint: It was also to set a precedent for citizen scientists from the public to essentially take over missions that ... all the missions that NASA may not want to spend its resources, its precious, you know resources and budget on. So this was supposed to be a good first example of how they could do that hand-off to a public group, and there were initial negotiations there and a Space Act agreement was signed so it was all above board and legitimate.

We realised the reason they got in touch with Ettus Research and then with me and my former colleague, John Malsbury, who funnily enough now works at SpaceX, so he's still in the space game, but he and I met with the guys and they basically told us the reason why we need your expertise is because NASA has thrown out all of the old equipment they used to speak to the space probe. So they put the space probe in this graveyard orbit, because the mission had finished and they ran out of funding, but there was no way for the NASA deep space network to actually send it commands to wake it back up again.

And so, having done their techno-archeology, as they like to put it, retrieving all these old NASA documents, we could see the various protocols that would be necessary to re-implement, using software defined radio, in this case GNU radio, to achieve this, you know, recreate the modems to talk to it. And so we did that and we were fortunate enough to be able to go to the Arecibo radio telescope in Puerto Rico, hook our software defined radios up to their big, big telescope, and then send these commands out to the probe, which at the time I think was 15.5 million kilometres away, travelling towards the earth at about four kilometres a second ...

Patrick: That's a long distance call...

Balint: Its a very long distance, and I call it "not your average radio link budget". But we managed after some initial attempts to have some success there and send the commands out to turn the telemetry on. We could then assess the health of the space probe and ...

Patrick: And you did your happy dance of course when the response came back?

Balint: That's true, yeah, we had our unmodulated carrier suddenly become modulated telemetry and it was the first real major milestone of the project. All that preparation that we'd done, all the interpretation of the documents and taking into account the various permutations of parameters and ...

Patrick: And the plan of course was to fire the thrusters in a way to get it into a stable orbit and they you guys could use the various sensors and things on it to quote "Do Science", uh, but it didn't quite work out did it?

Balint: No, unfortunately the grand idealist game was to reactivate all of the operational science instruments on board and actually bring it back and do proper, public science with it, and, you know, have it available for STEM and so on, but unfortunately when we tried to fire the thrusters, in all the different configurations, because there were lots of redundancies in the propulsion system, we never observed any impulse being registered on the accelerometer and the accelerometers data was being transmitted back on the telemetry and it would always sort of flat line. And this was a big disappointment for us, no matter what we tried we just couldn't get the thing to move, and one of the running theories is that the (fuel) tanks were actually pressurised with nitrogen so that it would force the fuel out, back into the rest of the propulsion system, as in the valves and the thrusters, and you could imagine that over the three decades there might have been a very, very slow leak and that nitrogen pressure, it might have just leaked out over time and unfortunately now its left us with an inoperable propulsion system.

Patrick: What, no backup fuel pump? (sarcastic)

Balint: Can you believe it?

Patrick: Bloody American engineering.

Balint: What were those NASA boffins thinking? (laughing)

Patrick: But you were able to actually fire up the sensors and do some science with it. What was the total budget of this project, that was crowdfunded in the end?

Balint: They used Rockethub and I think it was on the order of $150,000, so it was quite a nice little collection there, and yeah, some of the science instruments were reactivated and we actually for a short period got some good science data out of it, which was great, and it was quite funny, when I was at DEFCON last time, I got the call that one of the science instruments needed to be rebooted and I had been waiting for quite a long time in line to get a good seat and there were a number of back to back presentations that I was ...

Patrick: Excuse me I'll be back I've just got to go give the three finger salute to a satellite

Balint: Well that's the thing though, I didn't want to leave and so, unfortunately I didn't have any cell reception so I couldn't tether to my phone, you don't get on the WiFi at DEFCON obviously because then you open yourself up to being hacked. So there's a guy next to me that I started to talk to and we're talking about software defined radio and I sort of sized him up, he was from Norway and he seemed like a good bloke and I asked whether I could tether to his phone. He said yes because he had a prepaid account with some Internet credit on there. And so I ended up tethering to his phone, SSH-ing from the third row of DEFCON into the laptop at Arecibo to send commands to the space probe that was about to fly past the moon, to reboot the science instrument on board, and then I could continue watching the presentation, so it was quite fun.

Patrick: Its a pretty amazing time isn't it...

Balint: Well it just goes to show you how interconnected the entire world is, I mean you've got the WiFi from my laptop to the phone, LTE from the phone to the cellular network, and then the data connection obviously across that and then down to Arecibo and then our custom link to the space probe. So it was a good testament both to SDR and commercially deployed wireless standards.


Futher information ...
Communicating with a space probe using Software Defined Radio

... a video of a presentation Balint gave to the Manly Warringah Radio Society ...


Follow @dodgy_coder

Subscribe to posts via RSS

Saturday, February 28, 2015

Setting up a Bonjour (Zeroconf) service name for your Raspberry Pi and accessing it from an Android App

I have written an Android app that communicates to my Raspberry Pi over SSH (using JSch) but the issue is that in the App the IP address of my Raspberry Pi has been hardcoded at 192.168.1.109 - ideally it would be good to be able to give it a local name, something like garagedoor.local - something that won't change when the DHCP assigns a different IP address.

It turns out that the way to do this isn't difficult on the Raspberry Pi and most of work is in changes to the Android App needed to make it happen. I've numbered the steps 1-4.

1. Configuration of your Raspberry Pi.

# Get superuser privileges
sudo su

# Change the host name of your Raspberry Pi from "raspberrypi" to "garagedoor"
# Reference: http://www.howtogeek.com/167195/how-to-change-your-raspberry-pi-or-other-linux-devices-hostname/

sudo nano /etc/hosts            # <== Replace raspberrypi with garagedoor
sudo nano /etc/hostname         # <== Replace raspberrypi with garagedoor

sudo /etc/init.d/hostname.sh    # Commit the changes.
sudo reboot                     # Reboot

# Install the mDNS implementation - avahi
# Reference: http://www.howtogeek.com/167190/how-and-why-to-assign-the-.local-domain-to-your-raspberry-pi/
# Get superuser privileges
sudo su

# Update the package sources
apt-get update

# Ugrade the packages
apt-get upgrade

# Install the mDNS implementation - avahi
sudo apt-get install avahi-daemon



That's the end of the changes needed on your Raspberry Pi.

2. Test on either Windows, Linux or Mac OSX that the Raspberry Pi is visible on the network with its new name of "garagedoor.local".

On Windows, you will need to have Bonjour Networking Services installed, which comes bundled with iTunes.
Run a cmd.exe prompt and type the command ping garagedoor.local -- you should get a response from your Raspberry Pi.

On Mac OSX, Bonjour Networking Services are installed by default.
In a bash terminal window, type the command ping garagedoor.local -- you should get a response from your Raspberry Pi.

On Linux, first ensure you have installed the avahi-daemon package.
In a bash terminal window, type the command ping garagedoor.local -- you should get a response from your Raspberry Pi.

3. Using NSD (Network Service Discovery) on Android to resolve the Raspberry Pi's service name.

Browsers and terminal programs on Android won't be able to resolve the garagedoor.local since to do this requires use of either the official Network Service Discovery library (supported by API Level 16 up) or the open source Java Zeroconf library named jMDNS.

In my case, I am using a custom app I wrote to communicate to the Raspberry Pi, so I have decided just to use the Network Service Discovery library.

4. Source code changes needed in the Android App to support NSD (Network Service Discovery)

Notes:
 (1) Below is just how I decided to implement it, you may want to separate the NSD related code out of the Activity into its own class, but for me that wasn't a problem.
 (2) I probably need to do something related to NSD in the Application lifecycle events of onPause(), onResume(), onDestroy() and onTeardown(). I haven't done that here yet.


4.A. Add some members to the Activity

I added this to my MainActivity but my app is small and so that's all I needed to do.

// Network Service Discovery related members
// This allows the app to discover the garagedoor.local
// "service" on the local network.
// Reference: http://developer.android.com/training/connect-devices-wirelessly/nsd.html
private NsdManager mNsdManager;
private NsdManager.DiscoveryListener mDiscoveryListener;
private NsdManager.ResolveListener mResolveListener;
private NsdServiceInfo mServiceInfo;
public String mRPiAddress;

// The NSD service type that the RPi exposes.
private static final String SERVICE_TYPE = "_workstation._tcp.";

   
4.B. Add some init code to the bottom of the Activity's onCreate() method.

mRPiAddress = "";
mNsdManager = (NsdManager)(getApplicationContext().getSystemService(Context.NSD_SERVICE));

initializeResolveListener();
initializeDiscoveryListener();
mNsdManager.discoverServices(SERVICE_TYPE, NsdManager.PROTOCOL_DNS_SD, mDiscoveryListener);

   
4.C. Add the following two new methods to your Activity.

 private void initializeDiscoveryListener() {

     // Instantiate a new DiscoveryListener
     mDiscoveryListener = new NsdManager.DiscoveryListener() {

         //  Called as soon as service discovery begins.
         @Override
         public void onDiscoveryStarted(String regType) {
         }

         @Override
         public void onServiceFound(NsdServiceInfo service) {
             // A service was found!  Do something with it.
             String name = service.getServiceName();
             String type = service.getServiceType();
             Log.d("NSD", "Service Name=" + name);
             Log.d("NSD", "Service Type=" + type);
             if (type.equals(SERVICE_TYPE) && name.contains("garagedoor")) {
                 Log.d("NSD", "Service Found @ '" + name + "'");
                 mNsdManager.resolveService(service, mResolveListener);
             }
         }

         @Override
         public void onServiceLost(NsdServiceInfo service) {
             // When the network service is no longer available.
             // Internal bookkeeping code goes here.
         }

         @Override
         public void onDiscoveryStopped(String serviceType) {
         }

         @Override
         public void onStartDiscoveryFailed(String serviceType, int errorCode) {
             mNsdManager.stopServiceDiscovery(this);
         }

         @Override
         public void onStopDiscoveryFailed(String serviceType, int errorCode) {
             mNsdManager.stopServiceDiscovery(this);
         }
     };
 }

 private void initializeResolveListener() {
     mResolveListener = new NsdManager.ResolveListener() {

         @Override
         public void onResolveFailed(NsdServiceInfo serviceInfo, int errorCode) {
             // Called when the resolve fails.  Use the error code to debug.
             Log.e("NSD", "Resolve failed" + errorCode);
         }

         @Override
         public void onServiceResolved(NsdServiceInfo serviceInfo) {
             mServiceInfo = serviceInfo;

             // Port is being returned as 9. Not needed.
             //int port = mServiceInfo.getPort();

             InetAddress host = mServiceInfo.getHost();
             String address = host.getHostAddress();
             Log.d("NSD", "Resolved address = " + address);
             mRPiAddress = address;
         }
     };
 }


4.D. Make use of the mRPiAddress member where previously you used a hardcoded IP address.

Check that its not empty before using it. If its empty, it means the RPi's name couldn't be resolved.


Follow @dodgy_coder

Subscribe to posts via RSS




Saturday, February 21, 2015

Anders Hejlsberg: C# stands for C++++

Just came across this today. Previously had heard the association with the musical sharp symbol (#) to mean a pitch higher in tone, but this was the first time I'd heard that the # symbol can also be seen as a matrix of four small + symbols, hence C# stands for C++++, i.e. an increment to C++.

Source: http://www.computerworld.com.au/article/261958/a-z_programming_languages_c_/?pp=2

Follow @dodgy_coder

Subscribe to posts via RSS

Saturday, November 22, 2014

Android development is the new .NET

Back in 2001 Microsoft Windows had 90% of the worldwide OS market for PCs. But desktop windows software development was dire.

Developers were using tools like ...
  • Visual Basic 6 - very productive, with the downside of ugly, primitive syntax, lacking modern features such as interfaces and classes.
  • Visual C++/MFC - serious windows developers were using this, but it was less productive and extremely verbose, with lots of boilerplate.
  • Delphi -  the successor of Turbo Pascal and possibly the best of all frameworks on Windows at the time, but it never really took off.
  • Borland C++/OWL - the Open Windows Library from Borland tracked pretty closely with Visual C++/MFC, verbose + boilerplate.
  • Java - this had a reputation on Windows at the time for slow performance, bad visuals and bad tools.
At this point, Microsoft came out with Visual Studio.NET, the .NET framework and a new language named C#, with the help of former Delphi & Turbo Pascal language designer Anders Hejlsberg. Most Windows developers got on board - compared to what came before it was a breath of fresh air. Since that time, .NET has remained a large player, especially in the corporate and business market.

Fast forward to 2014, Android now has an 80% worldwide market share of approx. 1.75 billion smart phones.

Google has their own IDE, Android Studio and the open source Android SDK, which you can program using Java or any other JVM language. In the same way that .NET lets you use different .NET compatible languages such as C++/CLI and F#, Android supports other JVM languages like Scala, Clojure and Groovy, all of which let you cut down on the verbosity and boilerplate of Java.

Google is attempting to bring as many developers over to Android as possible. Their Head of Scalable Developer Relations, Reto Meier, aims to bring 50 million developers to Android.

Based on Android's market share and future employment prospects, Android is a decent choice for developers to try out. Compared to iOS, Android isn't as performant or profitable, but now it has a decent IDE, the weight of numbers, and the capability to use many Java FOSS libraries.

Follow @dodgy_coder

Subscribe to posts via RSS

Saturday, August 30, 2014

Essential free windows software

Here's a quick checklist of the free software I usually install on new Windows machines ...

Browser: Firefox - still the best browser in my opinion, with a wealth of developer tools. Chrome is also good but I found it to be prone to crashing, so gave up on it. After installing Firefox, I remove the Internet Explorer link on the task bar.

Email: Thunderbird - runs a bit slow sometimes, but the Thunderbird portable version is great to carry around on a USB thumbdrive. Check out these tips on how to speed up Thunderbird on Windows 7.

Anti-virus software: Microsoft Security Essentials. Nothing fancy but gets the job done.

DVCS (Distributed Version Control System): Git for Windows. Includes a command line shell which features decent help for all the git commands. You can use this to pull from and push to remote repositories hosted on services such as GitHub and BitBucket.

SVN client: Tortoise SVN client which integrates with Windows Explorer right click menus.

Flash: Adobe Flash Player. Be sure to uncheck the McAfee Anti-virus installer option. I really hate installing Adobe software onto a new PC. My only reason for doing it is for the many websites that still rely on flash.

File archive/compression tool: 7-Zip supports many formats, such as zip, rar, gz and tar, is fast, and open source.

Media player: VLC Media Player. This is a great music and video player which also can be used to rip DVDs and CDs. After installing it, I remove the Windows Media player link on the task bar.

Text editor: Notepad++. An excellent replacement for Notepad which supports syntax highliting for probably every known programming language, including Golang, via a simple language syntax file.

PDF creation: PDF Creator installs itself as a printer on your system, so when you print to it, it prompts you for the PDF filename to create.

PDF viewer: Sumatra PDF. This is an extremely fast PDF viewer, written in C++. It has a simple, uncluttered user interface. It also supports other formats such as XPS. Makes a nice change from the bloated incumbents, Adobe Reader and Foxit Reader. Refreshingly there's no adware or spyware in the installer and they also offer a portable version (no install required).

Office software (spreadsheet, word processor, slideshow): Libre Office and Open Office are free alternatives to the more widely used Microsoft Office, which still claims top spot in the number of businesses using it. Try and get the discounted MS Office Student Edition, or a discounted MS TechNet license to save money on the standard price. This site offers digital downloads of the various MS Office installers, however you will still need a valid license key to install it.

CD/DVD burner & ripper: ImgBurn

Bitmap graphics editor: either Paint.NET or GIMP. Both are excellent alternatives to the long established Adobe Photoshop.

Vector graphics editor: Inkscape is a fully featured alternative to Adobe Illustrator.

Diagram editor
: Dia is useful for creating things like flowcharts, network topology maps and block diagrams ... its an excellent free alternative to Visio.

Graphic file viewer: IrfanView is a compact and fast picture viewer for Windows. Its claim to fame is that it has been around forever (well at least since 1996) and is maintained by a humble dude from Bosnia called Irfan Skiljan (pronounced "Earfan") hence the name of the software. It has built in support for many file formats such as PCX, TIFF, RAW and other arcane formats such as those used on Amiga, Atari and Silicon Graphics machines. You can also use it to do batch format conversions.

Digital darkroom software: LightZone is a great free alternative to Adobe Lightroom. You'll just need to sign up for an account on their website before getting a download link.

3D graphics and animation: Blender is a free and open source 3D animation suite. It supports the entirety of the 3D pipeline - modeling, rigging, animation, simulation, rendering, compositing and motion tracking, even video editing and game creation.

3D modeling: SketchUp is an easy to use 3D modeling program. It has uses primarily in the fields of architecture, interior design, mechanical engineering and industrial design. Its free for personal and educational use. Their website has a large repository of 3D models that you can download.

Video editing: Blender mentioned above (under 3D graphics) can also do video editing, but for a standalone video editing program for Windows, one of the best available is Lightworks. The standard version is free, but they offer also paid pro version which has more advanced features. A decent alternative to Adobe Premiere. For only basic video editing, then the free Windows Movie Maker from Microsoft is a good option.

Password safe: KeePass. Comprehensive list of features, is open source, and is under active development.

File synchronisation: Dir Sync Pro. Useful for keeping local offline backups of entire directory structures or hard disks.

Binary hex editor & viewer: FRHED (FRee Hex EDitor) is a great little program. What's more there's no installer, just a simple .exe file you can put anywhere you want. Great for viewing, editing and searching through binary files.

Task manager: Process Explorer by Windows guru Mark Russinovich is like the Windows Task Manager on steroids. You can find out which files and DLLs a particular process is using.

C# REPL: CShell is an interactive C# interpreter, also known as a REPL (Read-Evaluate-Print-Loop). Such tools are par for the course for scripting languages like Ruby (irb). CShell lets you try snippets of C# code or call a DLL in a couple of lines, without having to fire up a heavyweight tool like Visual Studio.

Follow @dodgy_coder

Subscribe to posts via RSS


Friday, August 22, 2014

How to setup the Gigabyte Brix (GB-BXBT-2807) Ultra Compact PC

A step by step guide, including:
  • Gigabyte Brix hardware setup.
  • Preparing the Windows 7 installer USB boot drive.
  • Installing Windows 7 (64 bit).
  • Installing the Gigabyte Brix drivers.


BRIX PRODUCT DETAILS


GB-BXBT-2807 (rev. 1.0)
Intel® Celeron Processor N2807 (2 core) running at up to 2.17 GHz
http://www.gigabyte.com/products/product-page.aspx?pid=5038#ov


Officially supported operating systems:
  • Windows 7 (64 bit)
  • Windows 8 (32/64 bit)
  • Windows 8.1 (32/64 bit)

PARTS LIST

  • 1 x Gigabyte Brix - GB-BXBT-2807, AUD $165. Purchased here.
  • 1 x 2.5" SSD Intel 520 series, 120GB, AUD $79. Purchased here.
  • 1 x 4GB memory - SO-DIMM DDR3 1.35V 1600MHz (GEIL) green series, AUD $59. Purchased here.
  • 1 x Windows 7 (64 bit) DVD (or ISO file).
Total price of hardware: AUD $303

Purchased from : PLE Computers, Bentley, WA, Australia.


EQUIPMENT REQUIRED TO SETUP

  • 1 x USB hard drive with at least 4GB free (I used an old USB 2.0, powered, 250GB 3.5" Western Digital hard drive), but you can just as easily use a small USB flash drive or a portable 2.5" USB drive.
  • 1 x small Philips head screwdriver.
  • 1 x desktop PC or laptop running Windows; for setting up the Windows 7 USB boot drive and copying some Brix driver files.
  • 1 x monitor, either HDMI or VGA.
  • 1 x wired USB Keyboard.
  • 1 x wired USB Mouse.

STEP (1) BRIX HARDWARE SETUP


  1. Take off the bottom panel by unscrewing the 4 black screws.
  2. Inside the unit, remove the tape holding down the SATA cable.
  3. Install the low power (1.3V) RAM into the single slot - need to insert it at an angle fist, then push it downwards until it clicks into place.
  4. From the bottom panel, remove the 2.5" HD cage (mine had two screws, but its meant to have 4) and install the 2.5" SSD into the cage. Connect the SATA cable to the hard disk. There's only one way it can be inserted, so you can't make a mistake. Screw the cage back onto the bottom panel. Replace the bottom panel onto the Brix.
  5. Connect the power supply to the DC-in port.
  6. Connect a monitor to either the HDMI or VGA port.
  7. Connect a wired USB keyboard to the USB 2.0 port.
  8. Turn on the Brix via the power button on the top.
  9. Keep pressing the Delete (DEL) key on the keyboard about twice per second until the BIOS screen appears. Use Left/Right arrows to navigate between tabs.
  10. Confirm that the RAM and SSD have been detected by the BIOS.
  11. Change the operating system option to Windows 7. Note that the Brix requires the Windows 7 64-bit installer.
  12. Save and exit the BIOS.
  13. Switch off the Brix via the power button on the top.

STEP (2) PREPARING THE USB BOOT DRIVE FOR THE WINDOWS 7 INSTALLER


The following steps to be performed on a windows PC or Laptop...
  1. Ensure you have a Windows 7 (64 bit) install disk ISO file. If you have only the DVD, as I did, you will need to rip it to an ISO file at this point, using the ImgBurn software for example. Leave the ISO filename the same as the disk label (default behaviour). N.B. ImgBurn has a notoriously sneaky installer that will install "conduit" search malware and other crapware if you don't read the installer options properly, and deselect all options apart from the first one, which is ImgBurn itself.
  2. Download and run Rufus - a utility to help you create a USB boot drive from an ISO. Rufus is a standalone .exe file, no install is needed, which is awesome.
  3. Connect to the laptop a USB drive with at least 4GB free space that will be formatted (erased).
  4. If no drives appear at this point, its because Rufus defaults to only displaying USB flash drives. Press Alt-F to have it display all fixed USB drives.
  5. In Rufus, select the target USB drive and also the source Windows 7 ISO file.
  6. Select the option "create MBR for BIOS and UEFI computers" and also the NTFS file system. These should be the defaults after selecting the Windows 7 ISO.
  7. Create the USB boot disk in Rufus. Leave the disk label the same as the original ISO (or DVD).
  8. After Rufus has finished, disconnect the USB boot drive.

STEP (3) INSTALLING WINDOWS 7 FROM THE USB BOOT DRIVE

  1. Connect the USB boot drive to a USB 2.0 port on the brix.
  2. Turn on the Brix via the power button on the top.
  3. Keep pressing the DEL key on the keyboard about twice a second until the BIOS screen appears.
  4. In the BIOS boot menu, confirm the USB boot drive is detected. If it is not detected, you may need to boot one more time by powering the brix off then on. I think this is something to do with the USB boot drive not being ready for the BIOS, which boots very quickly. In the BIOS boot menu, press the '+' key to move the USB boot drive to the top position.
  5. Save and exit the BIOS.
  6. Go through the Windows 7 setup. You can do this just fine with only a keyboard and no mouse, using TAB, SHIFT-TAB, UP, DOWN, LEFT, RIGHT and ENTER to make selections as required.
  7. After the Windows 7 installer has finished copying files and is starting the installation it will prompt you to restart the Brix. At this point, you should go into the BIOS and restore the boot setting to boot from the SSD first (not the USB boot drive). Alternatively, you can just turn off the USB boot drive at this point, before the restart occurs.
  8. Connect a wired USB mouse to the USB 2.0 port vacated by the USB boot drive.
IMPORTANT NOTE FOR INSTALLING WINDOWS 8

Some commenters below have reported getting an error when trying to install Windows 8 at this point. The message from Windows is something like "windows could not update the computer's boot configuration". As suggested by commenter Tim Bailey, the solution is to update the BIOS to the latest version. You can download the BIOS update tool from the Gigabyte website.

Here is the BIOS download page for the Gigabyte Brix GB-BXBT-2807 model:
http://www.gigabyte.com/products/product-page.aspx?pid=5038&dl=1&RWD=0#bios

From the page above, instructions for updating the BIOS:
   For DOS, please type flash.bat in the dos mode.
   For Windows, please select folder and type f.bat in the windows command prompt (cmd.exe).

STEP (4) INSTALLING THE BRIX DRIVERS IN WINDOWS 7


After Windows has been installed and booted ok on the Brix, install the following drivers from the driver CD by copying everything on it to a USB thumbdrive on your laptop and then inserting into the blue USB 3.0 port on the side of the Brix.

On the Brix, in Windows:
  • WiFi+BT driver - just double click setup.exe to install. This gets WiFi and Bluetooth up and running - you can then connect to the Internet. Requires a reboot after install.
  • Graphics - just double click setup.exe to install. Requires a reboot after install.
  • USB3 - just double click setup.exe to install. Requires a reboot after install.
  • Audio - just double click setup.exe to install. Requires a reboot after install.
  • Chipset -  just double click setup.exe to install. Requires a reboot after install. A comment by a reader in the comments section below (Warren Rushby, December 10, 2014) indicates that this step was vital for his i3 model, so installing this driver is recommended.
I personally didn't bother installing the other drivers as they either weren't required by me (e.g. LAN) or they seemed to be only for Windows 8 anyway. To be on the safe side, especially if you are having issues, its recommended installing all the drivers.

My boot time is 17 seconds from power on to the Windows 7 login screen. Not too bad, helped no doubt primarily by the SSD.


STEP (5) (OPTIONAL) CONNECT A WIRELESS KEYBOARD & MOUSE

  • In Windows, replace the wired USB mouse with a wireless USB mouse and wait for Windows to install the driver (takes a minute or two).
  • Replace the wired USB keyboard with a wireless USB keyboard and wait for Windows to install the driver (takes a minute or two).
  • I noticed a couple of times that the wireless mouse wasn't working. I had to unplug and replug its USB dongle, and that fixed it.

STEP (6) (OPTIONAL) INSTALL SOME WINDOWS SOFTWARE


At this point I installed this software, which I personally find are essential in Windows, although you might have differing opinions on each category. All are free.
  • Browser: Run Internet Explorer to download and install Firefox. Then I remove the Internet Explorer links on the task bar and desktop.
  • Anti-virus: Microsoft Security Essentials. Nothing fancy but gets the job done.
  • Flash: Adobe Flash Player. Be sure to deselect the McAfee A/V installer option. I really hate installing Adobe software onto a new PC. My only reason for doing it is for the many websites that still rely on flash.
  • Media player: VLC Media Player. Then I remove the Windows Media player link on the task bar.
  • Editor: Notepad++. An excellent replacement for Notepad which supports probably every known programming language, including Golang.

Small snippet of trivia to finish with ... the Gigabyte Brix was named after Colin Brix, who is a marketing director at Gigabyte's Motherboard Business Unit.



Follow @dodgy_coder

Subscribe to posts via RSS