Monthly Archives: June 2015

An Explorer HAT Pro for the Raspberry Pi

If you are looking for a HAT or Hardware Attatched on Top for your Raspberry Pi (RBPi) that has motor and touchscreen drivers, integrated sensors and interfaces with 5V devices, the Explorer HAT is for you. Standard add-on board HATs allow the Linux-ready SBC, the RBPi, to configure its GPIO signals and drivers to control and use external devices.

Pimoroni has two models of HATs for the RBPi – the Explorer HAT and the Explorer HAT Pro. They support the HAT standard set by the Raspberry Pi Foundation, matching requirements for the RBPi 2 Model B, including the first-generation Model B+ and Model A+ boards as well.

To integrate inputs from 5V Trinkets or Arduino boards, the Explorer HAT offers four buffered 5V inputs. In addition, four powered 5V outputs on the board can supply 500mA to drive stepper motors, relays and or solenoids. The Explorer HAT also has a mini-breadboard, four capacitive touchpads, four LEDs and four capacitive alligator clips.

In addition to all the above features of the Explorer HAT, the Explorer HAT Pro has analog inputs and two motor drivers in H-bridge configuration to drive micro-metal geared motors and similar. The Explorer HAT Pro also comes with plenty of 3v3 features from the GPIO. However, these are unprotected.

According to the specifications defined for the Explorer HAT, each board has four inputs each 5V tolerant including 5-channel buffers with 2-5V support. There are four 5V powered Darlington-array outputs capable of 500mA per channel, limited to 1A total. The front edge of the board has four capacitive touch pads along with four LEDs, controlled independently. Including the mini-breadboard, the dimensions of the Explorer HAT are 65x56x13mm.

The Explorer HAT Pro version adds four analog inputs including two bi-directional motor drive outputs of the H-bridge type capable of handling 200mA per channel. It supports soft-PWM for full speed control. Additionally, there are the unprotected 3V3 GPIO features.

Compared to the Pibrella, another board made by Pimoroni, both the Explorer HAT and the Explorer HAT Pro share many similarities, but also add a lot more besides. For example, the analog and digital inputs are a great help, especially since you can connect inexpensive and simple sensors such as the TMP36, while taking advantage of the built-in ADC.

The capacitive touch buttons of the Explorer HAT not only allow interfacing with connected components, but also allow independent working. For example, you can send a tweet, an email or a text message by simply tapping one of the buttons. There are many other possibilities with these capacitive touch buttons. You can connect crocodile clips and brass contacts for using fruits as buttons. Of course, the software will have to be tweaked somewhat to get the proper sensitivity.

Plugging HATs on the RBPi invariably causes loss of access to some GPIO pins. The Explorer HAT breaks out the most useful pins from the GPIO, making them easily accessible. Pimoroni provides intuitive Python libraries and a built-in tutorial for all to use.
Overall, both the Explorer HAT boards are a great value for money not only for kids playing and learning to interface with the RBPi, but also for grown-ups.

All about electrical wires

Recent advancements in wireless technology may have led many people to believe that soon, we would be able to do away with these squiggly, snaking, long implements we call wires. However hard we may try to hide them by burying them within walls and under the ground, the time is not yet ripe for a life entirely without wires. While we have to put up with wires all around us, it would be interesting to know something more about them.

Use of wires can be broadly categorized into two main classes of requirements – mechanical and electrical. While the mechanical requirements deal mainly with load carrying strength/capacity of the wire under use, the electrical requirements can be further subdivided into power and signal carrying capabilities. In this article, we will be talk about wires and their electrical requirements only. The materials with which wires are made, their dimensions and the nature of protection used depends to a large extent on whether the wire is required to carry power or signal.

Most wires within our houses and those carrying power are made of copper. Conductivity, malleability and cost are the main considerations that govern the choice. Copper is a good conductor of electricity, meaning it presents a low resistance to the flow of electricity through it. The metal is easy to bend and mold in the form of wires of different diameters. Since copper is abundantly available, the price is reasonable for residential use. Some wires are made of aluminum, which is cheaper than copper. However, its conductivity is lower than that of copper. For carrying the same amount of electricity, you need an aluminum wire with a larger diameter compared to that of a copper wire.

The nature of protection used on wires carrying electrical power depends on the voltage it is carrying and the environment in which the wire is used. For example, special cladding and fire-retardant protection is required for wires carrying high voltage electricity passing through an area with plenty of oil.

Compared to power handling wires, signal-carrying wires are of more varied types, depending on the application. For example, there can be connecting wires, RF coaxial feeders, screened cables, ribbon cables, data cables and many more. For most of these applications, the governing factor is the frequency of the signal rather than the voltage and current carrying capacity. Waveform distortion, crosstalk, noise and signal loss are more important rather than the amount of power transferred.

As long as the signal frequency is low, say below 1000 Hz or so, the material or construction of the wire does not matter greatly. However, as the frequency of the signal increases, the wire starts to behave like a non-linear entity and its inherent inductance and capacitance start to cloud its performance. With still higher frequencies, the signal is unable to retain its original waveform. To retain the high-frequency performance, people need to use special types of RF coaxial feeders, ribbon cables, screened cables, etc.

For example, to prevent loss of signal in screened cables, a low-loss insulator often surrounds the wire conductor. A braided sheath on the outside of the insulator acts as a shield and a PVC jacket protects the entire package.

A drone camera to follow you around

Unlike Mary, most of us are fortunate or unfortunate enough not to have a little lamb following us around. However, that does not mean we cannot have a camera drone following us wherever we go. A California-based startup firm has pioneered an easy-to-use, self-flying drone as the world’s unique throw-and-shoot camera that flies itself.

To use the device, you simply throw it into air. Lily, the drone camera, immediately deploys its four propellers to provide thrust and directional vectoring. No controller is required as Lily automatically follows its owner. You are free to continue to focus on your activity as Lily captures your adventures, flying itself while grabbing high definition images and video. It is impossible for you to outrun Lily, because it can fly at speeds of up to 25 mph. Therefore, you can employ Lily to film you while snowboarding, kayaking or cycling.

The camera inside Lily is specially engineered to withstand robust handling in tough aerial as well as water environments. Anyone who wants to share their everyday activities can use Lily as a simple, fun way to record their outdoor action sports. Lily can track its owner intelligently, following his or her every move by using GPS and advanced computing algorithms. Lily can provide additional creative shooting opportunities for those wanting to move beyond the single point-of-view of handheld and action cameras.

What makes Lily follow you around and not wander off with some stranger? Well, Lily comes with a tracking device that the owner has to wear on his or her wrist. In reality, Lily is wirelessly tethered to this tracking device, while recognizing the owner using computer vision to follow your features optically. Over time, the tracking accuracy improves as Lily learns on-the-job. With Lily, you can get exciting close-range photos as well as wide, cinematic shots just as professional filmmakers can.

Lily captures still shots at 12MP resolution, slow motion at 720p at 120fps and HD video at 1080p at 60fps. The tracking device uses a built-in microphone for recording high-quality sound, which Lily automatically synchronizes with the video being recorded. Lily has a companion app to which it streams low-resolution live video. This helps the user to frame the shots.

Lily works best in outdoor conditions at a height of 10-30ft. A proprietary computer vision algorithm drives the core technology of Lily’s camera. Although Lily works comfortably in winds exceeding 20mph, the manufacturer advices its use in winds below 15mph, to be safe.

Lily complies with FAA guidelines, while communicating with the tracking device worn by its owner. It relays speed, distance and position back to the built-in camera. The user can direct Lily via either the tracking device or the mobile app. According to the program used, Lily can follow, hover, loop, zoom and do more at an average flying speed of 15 mph. Depending on the way Lily’s owner uses it, a full charge allows Lily to operate between 18 and 22 minutes.

It takes two full hours to charge up fully. As the battery runs low, the tracking device warns you with vibrations. You can summon Lily to make it land on your palm gracefully.

What are Counterfeit SD Cards?

Many of us use SD or Secure Digital memory cards, but seldom do we check if the total capacity actually matches that specified on the card. According to the Counterfeit Report, several dishonest sellers on Alibaba, Amazon, eBay and other reputed sites offer deep discounts for high capacity cards. They use common serial numbers with cards and packaging nearly identical to the authentic products from all major SD card brands.

According to tests conducted by the Counterfeit Report, although the cards work, buyers usually purchase a card based on the specifications printed on it. What they think and buy as a 32GB SD card, may turn out to be a counterfeit with a capacity of only 7GB. Counterfeiters usually overwrite the real memory capacity, imprinting a false capacity figure to match any model and capacity they prefer. Usually, the actual memory capacity cannot be determined by simply plugging the card into a computer, phone or camera. Only when the phony card reaches its limit, it starts to overwrite files, leading to lost data.

According the Craig Crosby, publisher of the Counterfeit Report, such fake cards also come in capacities that do not exist in any product line and counterfeiters target mostly cards above 32GB. They make a great profit on selling fake cards, with practically no consequence.

Usually, people cannot make out counterfeit cards from real ones, until these stop working. Usually, the blame falls on the manufacturer for making faulty products. This may happen even if you buy from a major retailer, as counterfeiters buy genuine items, only to exchange them unopened with their fakes.

Although software packages are available to test whether the card capacity matches the specifications on its packaging, organizations find it time-consuming, especially if they have bought cards in bulk. Additionally, the problem is not with SD cards alone, counterfeiters make fake portable flash drives including USB sticks as well.

Although the SD Association does make standards and specifications for SD cards to promote their adoption, advancement and use, they do not monitor the trade of products such as SD memory cards. The responsibility of counterfeit SD cards falls in the realm of law enforcement.

Manufacturers of SD memory card products can contract with several SD standards-related organizations for different intellectual property related to SD standards. Additionally, SDA member companies can resort to compliance and testing tools for confirming their products meet the standards and specifications, providing assurance to users about interoperability with other products of similar nature.

Consumers, especially bulk purchasers, should be careful to buy from authorized resellers, distributors and sellers. The best resource for any enquiry is the manufacturer of the SD memory card product.

This malaise is not restricted to counterfeit SD cards alone. It is a part of a larger problem. According to the Counterfeit Report, several other items face the same situation. Phony items exist for iPhones, other smartphones, airbags and many other peripherals such as chargers. It is very difficult for consumers to make out the counterfeits and many are even unaware of the existence of such phony high-end items.

Energy Monitoring with the Raspberry Pi

If you are looking for an all-in-one device for monitoring your home energy needs, a low-cost single board computer such as the RBPi or Raspberry Pi along with an add-on shield is all you need. The emonPi board is a low-cost shield that is bereft of any enclosure, HDD and LCD.

However, when connected with an LCD for status display, hard-drive for local logging and backup and a web-connected RBPi, the emonPi makes a high-quality and robust unit. Enclose it in a suitable enclosure and you have a stand-alone energy monitoring station.

The design of the emonPi allows it to be a perfect fit for those who install heat-pump monitoring systems. Usually, these systems require several temperature sensors that must also be wired up along with power monitoring. Accompanying modules offer a myriad of options.

For example, the emonPi can also act as an emonBase, as it has options for radio (RFM12B/RFM69CW) to receive data from other wireless nodes. These nodes include emonTH, for measuring room temperature and humidity. Another energy-monitoring node, the emonTX V3 can send the current time to the LCD, emonGLCD.

The status LCD makes it easy to install, setup and debug the emonPi system as an energy monitor sensing mode and an all-in-one remote posting base station. This makes the emonPi a great tool for remote administration, since, with a proper networking configuration the RBPi can be accessed remotely. Thus, you may check its log files and even upload firmware onto the ATmega328 of the emonPi.

The emonPi monitors energy through a two-channel CT or current transformer along with an AC sample input. It can power up the RBPi and an external hard disk drive without using an external USB hub. Additionally, the emonPi can function even without a hard disk drive being connected to it.

The RJ45 breakout board makes it very easy to attach several temperature sensors to the RJ45 on-wire temperature bus provided by a DS18B20. This is eminently suitable for multi-sensor setups such as in heat pump monitoring applications. The RJ45 also has IRW and PWM I/Os.

The emonPi is compatible to all models of the RBPi and its options for RFM21B and RFM69CW along with an SMA antenna makes it capable of receiving or transmitting data from other sensor nodes. One can control remote plugs with the OOK or On-Off keying transmitter.

All hardware, firmware and software are open-source and the ATmega328 on the emonPi can remotely upload sketches via the serial port of the RBPi. However, compared to the emonTX V3, emonPi has some disadvantages.

The emonPi module is not capable of making measurements on three-phase systems as there is only one CT monitoring two channels. As the RBPi has high power requirements, it is not possible to power the emonPi from batteries. You cannot also use an AC-AC adapter, because, for measuring real power, you must use both a 5VDC and a 9VAC adapter. Remote location of the utility meter requires Ethernet connection or Wi-Fi connectivity. Additionally, the emonPi requires a larger enclosure as compared to what an emonTX V3 uses.