Monthly Archives: May 2017

Extending IoT with the Raspberry Pi

Recently, the Raspberry Foundation has updated its embedded Compute Module with a faster ARM processor. This will help developers and businesses build new IoT devices. The new Compute Module 3 (CM3) comes with a powerful new option and embedded compute capabilities for device makers interested in the Internet of Things (IoT).

Although not to be confused with the Single Board Computer, the Raspberry Pi (RBPi), with which the CM3 also shared the latest update, is a tiny form-factor ARM-powered SBC originally developed to help both kids and adults learn computer programming.

Launched with the same form factor as that of the RBPi, the CM3 was specifically targeted at business and industrial users. While the RBPi is a completely standalone device, the CM3, on the other hand, is a module intended for plugging into a separate Printed Circuit Board. The primary aim of the Compute Module is to let vendors and developers develop customized products quickly.

The new CM3, like the RBPi3, also uses the same Broadcom system-on-chip (SoC), the ARM BCM2837. The ARM Cortex A53 design forms the base for the SoC BCM2837, which is a 1.2 GHz, quad-core chip running on 64 bits. As a bonus, the standard CM3 has an on-module eMMC flash memory of 4 GB.

Other than the standard CM3, the Raspberry Pi Foundation also has a CM3L or Compute Module 3 Lite version. With the CM3L, users can wire up their choice of an SD card interface or eMMC memory. While the CM3L also comes with the same BCM2837 SoC, the on-board RAM is still restricted to 1 GB only.

Along with the CM3 and the CM3L, the Raspberry Pi Foundation is also releasing the new Compute Module IO Board V3 (CMIO3). This will provide developers with a starter breakout board to which they can connect their Compute Module.

The CMIO3 offers designers a starting template for designing with the Compute Module, providing them with a quick method to experiment with the hardware and to build and test a system. Once the experiment succeeds, they can proceed with the expense of fabricating a custom board. The CMIO3 also provides the necessary USB and HDMI connectors to make up the entire system that boots up and runs the Raspbian OS, or any other OS you select.

Although the Raspberry Pi Foundation has only recently released new Command Modules, next generation large-format displays based on the modules are already available from the consumer electronics vendor NEC, as they had early access to them.

The idea behind the Compute Modules is to provide a cost-effective and easy route to making customized products using the hardware and software platforms of the RBPi. The modules provided the team in the garage the same technology that the big guys already had. The Module takes care of the complexity of routing the core power supply, the high-speed RAM interface, and the processor pins, while allowing a simple carrier board provide the basics in terms of form factor and external interfaces. The form factor of the module follows that of the inexpensive, easily available, standard DDR2 SODIMM.

Powering the Pacemaker from Solar Energy

Those suffering from certain ailments of the heart, have to have a pacemaker installed. Surgeons place this tiny medical device in the chest or abdomen of the patient and it helps to control abnormal heart rhythms. The device generates electrical pulses and prompts the heart to beat at a normal rate. Power comes from implanted Lithium-iodide or Lithium anode cells, with Titanium as the encasing metal. The downside to this arrangement is the cells need replacement once they are discharged, and that means periodic surgeries.

To avoid repeated surgeries, scientists prefer using solar cells placed under the skin for continuously recharging the implanted electronic medical devices. According to Swiss researchers, a 3.6 square centimeter solar cell generates enough power necessary to keep a typical pacemaker running through the year.

Lukas Bereuter of Bern University Hospital and his team from the University of Bern in Switzerland have presented a study that provides real-life data on the potential of using solar cells to power implanted devices such as deep brain stimulators and pacemakers. Lukas is confident it will become commonplace to wear power generating solar cells under the skin. This will save patients the discomfort of undergoing repeated surgeries to change batteries of such life-saving devices. Lukas has reported the findings in Springer’s journal Annals of Biomedical Engineering.

Electronic implants are invariably battery powered, with their size depending on the volume of the battery necessary for an extended lifespan. When the battery exhausts is power, it must either be charged or changed. This necessitates expensive and stressful medical procedures involving implant replacements, along with the risk of medical complications for the patient. The implantable solar cell is attractive as it converts the light from the sun penetrating the skin surface to generate enough energy for recharging the medical devices.

Lukas and his colleagues have developed devices specially designed for solar measurement to investigate the feasibility of rechargeable energy generators in real-life situations. The devices measure the output power generated. According to the team, 3.6 square centimeter cells generated enough power and were small enough for the intended implantation.

The team tested ten cells by covering them with optical filters for simulating the properties of human skin. This influenced the amount of sunlight penetrating the skin. A test group of 32 volunteers wore the cells on their arm for one week during summer, autumn, and winter months.

According to the team, the tiny cells were able to generate power more than the 5-10 microwatts required by a regular cardiac pacemaker, irrespective of the season. The lowest power output the team recorded on average was 12 microwatts. The overall mean power obtained from the cells was enough to power a pacemaker completely, or at least extend the lifespan of an active implant. Furthermore, the use of solar cells or energy-harvesting devices for powering an implant dramatically reduces the size of the device, while at the same time, helps to avoid device replacements.

According to Lukas, the results of the study may be suitably scaled up and applied to other mobile applications, especially solar powered applications on the human body. The only aspect that requires attention is the efficiency and catchment area of the solar cell, and the thickness of the skin covering it.

A Raspberry Pi DAC for the Audiophiles

Raspberry Pi (RBPi) users have several choices for using Digital to Analog Converters (DACs) when listening to music. Two of the latest DACs available in the market are discussed here. One of them is the DragonFly series from AudioQuest and the other is i-Sabre from Audiophonics. Both offer stronger and more meaningful connections between music enthusiasts and the albums, songs, videos, and artists they adore.

DragonFly USB DAC, Preamp, and Headphone Amplifier

The multi-award-winning DragonFly USB DAC, preamp, and headphone amplifier from AudioQuest is a popular product that effectively bridges the gap between extreme audiophiles and mainstream music lovers.

Plugging into the USB port of a computer, including single board computers such as the RBPi, the DragonFly bypasses the compromised audio circuitry of the computer to deliver clearer, cleaner, more natural sounding music and sound to headphones, powered speakers, and complete audio systems.

Two versions of the DragonFly are available—the Black, and a higher-performing Red version. Both versions offer 32-bit digital performance using the Microchip PIC32MX micro-controller, which draws 77% less current from what the previous micro-controllers did that AudioQuest was using. Both versions offer naturally detailed, more authentic sound thanks to the improved ESS Sabre DAC chips working at 32-bits, and using minimum-phase filtering. The DragonFly Red has the latest ESS headphone amplifier and a bit-perfect digital volume control incorporated on the 9016 DAC chip. This ensures maximum fidelity, improved signal-to-noise ratio, and high dynamic contrast.

Both versions of the DragonFly generate enough power to drive all preamplifier input circuits successfully, and they are compatible with a wide range of efficient headphones. While the Black outputs 1.2 Volts, the Red has a 2.1 Volt output and is further compatible with a wider range of power-hungry, low-efficiency models.

The iSabre ES9023

This product from Audiophonics is an I2S DAC, suitable for RBPi model 2, and it has a high precision clock onboard. It produces better quality sound as compared to the DragonFly USB DAC. The clarity is very good and the iSabre gives offers good stereo placement along with detailed high frequency reproduction. This makes the sound very transparent and optimally realistic.

The iSabre ES9023 ideally transforms the RBPi A+, B+, or 2.0 into a high-definition music file player. The converter offers a high value for money and has direct analog outputs on high-quality headers.

The converter has ultra-low noise regulators, OS-CON capacitors, which gives the DAC its musical sound and rich mono details. The HAT format allows direct access to the RBPi GPIO pins, but users have the additional choice to use I2S inputs or the USB interface.

To use the DAC, you may need to install the Hifiberry or the Hifiberry+ driver on the RBPi. The appropriate I2S card will show up on the list of audio devices in the Playback menu.

The cornerstone of a top-quality audio system depends on the accurate conversion of music and sound from the digital to the analog world. The two DACs described above do this conversion admirably. An oversampling process eliminates all the clocking inconsistencies or jitter commonly found in typical digital-to-analog conversions.

The Law, Big Data, and Artificial Intelligence

We use a lot of electronic gadgets in our lives, revel in Artificial Intelligence, and welcome the presence of robots. This trend is likely to increase in the future, as we continue to allow them to make many decisions about our lives.

For long, it has been a common practice using computer algorithms for assessing insurance and credit scoring among other things. Often people using these algorithms do not understand the principles involved, and depend on the computer’s decision with no questions asked.

With increasing use of machine learning and predictive modeling becoming more sophisticated in the near future, complex algorithm based decision-making is likely to intrude into every field. As such, expectedly, individuals in the future will have further reduced understanding of the complex web of decision-making they are likely to be subjected to when applying for employment, healthcare, or finance. However, there is also a resistance building up against the above, mainly in the EU, as two Oxford researchers are finding out from their understanding of a law expected to come into force in 2018.

With increasing number of corporations misusing data, the government is mulling the General Data Protection Regulation (GDPR), for imposing severe fines on these corporations. GDPR also contains a clause entitling citizens to have any machine-driven decision processes explained to them.

GDPR also codifies the ‘right to be forgotten’ while regulating the overseas transfer of private data of an EU citizen. Although this has been much talked about, not many are aware of two other clauses within GDPR.

The researchers feel the two clauses may heavily affect rollout of AI and machine learning technology. According to a report by Seth Flaxman of the Department of Statistics at the University of Oxford and Bryce Goodman of the Oxford Internet Institute, the two clauses may even potentially illegalize most of what is already happening involving personal data.

For instance, Article 22 allows individuals to retain the right not to be subject to a decision based solely on automatic processing, as these may produce legal complications concerning them or affect them significantly.

Organizations carrying out this type of activity use several escape clauses. For instance, one clause advocates use of automatic profiling—in theory covering any type of algorithmic or AI-driven profiling—provided they have the explicit consent of the individual. However, this brings up questions whether insurance companies, banks, and other financial institutions will restrict the individual’s application for credit or insurance, simply because they have consented. This can clearly have significant effect on an individual, if the institutes turn him or her down.

According to article 13, the individual has the right to a meaningful explanation of the logic involved. However, organizations often treat the inner working of their AI systems and machine learning a closely guarded secret—even when they are specifically designed to work with the private data of an individual. After January 2018, this may change for organizations intending to apply the algorithms to the data of EU citizens.

This means proponents of the machine learning and AI revolution will need to address certain issues in the near future.

Wordery Uses the Raspberry Pi for Book-Wrangling

Among the mass of technologically advanced stuff done with the popular single board computers, the Raspberry Pi (RBPi) has also been helping booksellers. At Wordery, an online bookshop, Jeff Podolski, an IT and network technician, is using the RBPi at their warehouse.

Wordery has over 10 million book titles in their list, including several on RBPi. Over the last few years, they have been working on improving their productivity and customer service drive. For their sorting and distribution operation, they have taken up a greater automation. This is allowing them to track packed items and offer interactive feedback to their staff. For this, they needed PCs on the desks they use for packing and mailing. However, a PC with a screen and barcode scanner would take up considerable space on the desk and consume a lot of power. Therefore, their IT team had the brainwave of using RBPis instead.

Jeff and his team conducted initial tests using an RBPi and a standard PC. They settled on using a setup with the 7-inch official LCD screen and case for the RBPi, and used a USB barcode scanner. This setup saved more than four-fifths of the space a PC would have used up on the desk, while using substantially less power.

However, an RBPi with screen and scanner, left unsecured on the desk, was likely to be knocked and bumped by items being packed and possibly smashed on the warehouse floor. This led Jeff to use a tablet-mounting arm, originally designed for wheelchairs. He clamped the arm to a table, and attached a backboard to the bracket meant to hold the tablet.

Making use of the rear mounting screw holes, Jeff was able to attach the RBPi and screen to the bracket. By routing and tidying the cable layout, Jeff and his team had a low power, small, easily movable interactive terminal, which all the staff in the warehouse could use.

The success of the project led to an installation of over 40 of these terminals in the warehouse, with benefits clearly visible. The warehouse has since processed record volumes using the terminals. They have improved on the previous year’s performance by 11%. Since they set up the RBPi terminals, the warehouse has been handling additional volumes, and packing productivity has increased by 30%. According to Jeff, the resounding success of the RBPi terminals has encouraged their use elsewhere in the building also, further reducing their equipment costs and power consumption.

With the RBPi community and the team at ModMyPi helping with the sourcing of the kit and cables in large volumes, Jeff’s team did a great job of modifying the tablet arm to make it fit another purpose. The RBPi Thin Client Project made the simple configurable thin client for project, while Martin Kirst helped to make the terminal emulator screens more readable and added new functionality to the units. By making the interaction wireless, the terminals can be moved to places where they are currently needed.

This project proves the RBPi can be used for making automation cheaper, more accessible, and much more flexible in an industrial setting.

What is a Programmable Logic Controller?

Programmable Logic Controllers (PLCs) are miniature industrial computers. The hardware and software in a PLC are meant to perform control functions. Specifically, a PLC helps in the automation of industrial electromechanical processes. This includes controlling machinery on assembly lines in a factory, rides in an amusement park, or instruments in a food processing industrial establishment.

Most PLCs are designed to facilitate multiple arrangements of analog and digital inputs and outputs. They typically operate with extended temperature range, resistance to impact or vibration, and immunity to electrical noise and disturbances. The basic sections of a PLC usually consist of two sections—the first, the central processing unit (CPU), and the second, an Input/Output (I/0) interface system.

The CPU uses its processor and memory systems to control all system activity. Within the CPU is the micro-controller, memory chips, and other integrated circuits for controlling logic, monitoring, and communications. The CPU may operate in different modes—programmable or run. The programming mode allows the CPU to accept changes to the logic received from another computer. In the run mode, the CPU will execute the program to operate the process.

In the run mode, the CPU will accept input data from connected field devices such as switches, sensors, and more. After processing the data, it will execute or perform the control program stored in its memory system. As the PLC is a dedicated controller, the single program in its memory is processed and executed repeatedly. The scan time, the time taken for one cycle through the program, is typically of the order of one-thousandth of a second. The memory within the system stores the program, while at the same time holding the status of the I/O and provides a means to store values.

Typically, industrial users can fit a wide range of I/O modules to a PLC to accommodate various sensors and output devices. For instance, there are discrete input modules for detecting the presence of objects or events using photoelectric or proximity sensors, limit switches, and pushbuttons. Similarly, with discrete output modules it is possible to control loads such as motors, lights, solenoid valves, mainly to turn them On or Off.

The PLC can be fitted with analog input modules to accept signals generated by process instrumentation such as temperature, pressure, flow, and level transmitters. The modules interpret the signal from their sensors, and present a value within the range determined by the electrical specification of the device.

In the same way, the PLC can use analog outputs to command loads requiring a varying control signal, such as analog flow valves, variable frequency drives, or panel meters. PLCs can also use specialized modules such as serial or Ethernet communications, and high-speed I/O or motion control.

The greatest benefits of a PLC are its ability to change and replicate or repeat the operation of a process while simultaneously collecting and communicating critical information. In the industry, all aspects of a PLC—cost, power consumption, and communication capabilities—are subject to consideration when selecting the right one for the job. Industry automation owes a lot to the PLC or Programmable Logic Controller.