Software apps and online services
Diagnosing and fixing build problems is a regular task in software development. Team Foundation Build provides tools to help debug and resolve software problems such as failed or partially successful builds, exceptions, errors, or warning and unexpected events or results.
In a typical software development team there is more than one developer working on the same software project. The team can use Team Build to automate the compilation, deployment, and testing of its software products. Small and big software teams use the popular software practice ´Continuous integration´.
Continuous integration is the process of generating a build whenever a developer checks code into the source control server. One drawback of this build type is that corrupting source code can pass into version control and subsequently failing to compile the current version.
If we have any broken builds, we need to get the details for the build as soon as possible so that we can inform the developer who may have broken the build. Why is this important? In big software teams every developer is checking in code. So the developer might be the person who broke the build or it may not, since more than one person may have checked in code.
I am a C# software developer and a TFS build master. So I like to write software and also define the build process and branching strategies, coordinate build schedules, creating internal release builds for DEV and QA, creating external release builds for customers. In my spare time I like to experiment with new technology like IoT, opensource hardware like Arduino, Netduino, Genduino.
To increase the fun factor in the software development team I came up with the idea to build a team foundation build LED. The team foundation build LED will flash when a broken build is detected on the source control server. The communication with the LED is done with a serial bluetooth receiver, because it is wireless the team foundation build LED can be placed anywhere in the department. It will also be an eye catcher for visiting customers.
As an extra the LED build strobe also measure the temperature and humidity in the working area. This data is send to the client computer which is running a winforms application to display the data on the computer.
- Laptop with access to a Team Foundation Server and serial bluetooth modem.
- Arduino Uno R3 - Board
- SparkFun Bluetooth Modem BlueSMiRF Silver
- DHT11 or equal
- 12V 240 LED Beacon Flashing Emergency Warning Strobe
- Plastic Waterproof Enclosure Case
- Car Wire Cord Clip Cable Holder Tie Clips
- AC 100-240V To DC 12V 1/2/3A Power Supply Adapter
- Dupont Wire Jumpercables 30cm
- 10x M3 x 12mm Brass Hex Standoff with nut AK
- 10 pcs M3 x 10mm Brass Hex Standoff Pillar Male
- Female with nut AK 10 pcs M3 x 12mm Brass Hex Standoff Pillar Female
- M16 16mm 5 Pin Screw Type Electrical Aviation Plug Socket Connector
- M12 12mm 2 Pin Screw Type Electrical Aviation Plug Socket Connector
- M16 16mm 3 Pin Screw Type Electrical Aviation Plug Socket Connector
- 10M New 24AWG 1007 GAUGE Black&Red Wire Cable
- 4 Channel 5V Relay Module With optocoupler
- 1PCS Whip Automotive Fuse Holder
- 1PCS 15A Fuse
- 12V to 5V 3A 15W DC/DC Converter Circuit Regulator
- 1 pcs x In-Line Fuse Holder For 3AG 5x20mm Fuses NEW
- M3 x 12mm Metal Stainless Steel Head Screws 63/37 0.8mm
- Tin Lead Rosin Core Solder Flux Soldering Welding Iron Wire Reel
- Heat Shrink Tubing Wrap Sleeve Kit.
WarningAlways power the Arduino board with the external power adapter before connecting the usb cable to the computer for uploading the Arduino sketch. If the external power adapter is not connected the power regulator on your arduino board will be very hot and can damage your Arduino board. The 12V to 5V power regulator is drawing too much current from the USB when the power regulator is not connected to the external power source.
Extra relays output
We are using a 4 channel relays. In the example we only need two channels. One for the power, Second for changing the LED blinking mode. The other two channel are optional. In my example i don´t use the two channels but i have connected it to the 5 pin screw type electrical aviation plug socket.
- Visual Studio Express (Free) / Visual Studio Enterprise / Visual Studio Professional / Visual Studio Online
- Team Foundation Server - This server is running on a server in a protected /private company domain.
- ARDUINO 1.x.x - The open-source Arduino Software (IDE).
- DHT11 Arduino library
BlueSMiRF - Bluetooth configuration
The software is build up into two parts.
Client Windows MachineFirst we have to develop a winforms application which can be executed on a windows machine. I want the intelligent part of the entire build status processing burden to be rested on the client windows machine. In most cases connecting to the team foundation server is only possible when the windows machine is added in a corporate or private domain of the company. So running the winforms applications on your windows machine solves most security issues because communication with the arduino hardware is done with the bluetooth module. The winforms application has a timer to check the Team Foundation Server every minute. The application then sends the status wireless to the Arduino. The Arduino will process the data and determine the LED mode.
Arduino Second the Arduino needs a sketch which drives the LED strobe for different blinking modes. In total I have built two blinking modes. First mode “build in progress” will turn the LED strobe on for 10 seconds. Second mode “build failed” will shift the led strobe mode to a flashing / blinking mode. The arduino also sends temperature and humidity data to the client machine and drives the hardware like reset button, bluetooth module, and relays.
LED Beacon Flashing Emergency Strobe ModesThe LED strobe unit has seven strobe modes. The LED mode can be changed by grounding the white wire to GND. There is no two way communication between the Arduino and the LED. I needed two modes to represent two build status. One for build succeeded. The second one for build failed. I coded a simple algorithm to count the modes and shift between the two different modes. So when a build failed the Arduino shifts 4 times the relays for the new LED blinking mode. When a build is succeeded or a build is in progress the Arduino shifts the relays 4 times again to go back to the original blinking mode.
Example beta softwareThe software i have written works ok, but there are some minor bugs. The main purpose of the written software is to check the build status on the server and control the LED strobe unit. The software is written in my spare time any developer who has written a better example please inform me i´m glad to analyse and publish it.
The BlueSMiRF Silver is the Bluetooth wireless serial cable replacement from SparkFun Electronics! The data from the client computer to the arduino is send with this bluetooth module.
Tutorial using the BlueSMiRF bluetooth
Setup up the bluetooth module please go the the following link: using-the-bluesmirf
The DHT11 is a basic, ultra low-cost digital temperature and humidity sensor. It uses a capacitive humidity sensor and a thermistor to measure the surrounding air, and spits out a digital signal on the data pin (no analog input pins needed). The data is read by the Arduino and send to the client computer.
More information on: http://playground.arduino.cc/main/DHT11Lib
- Winforms application (Arduino code included in seperate folder)