Mouser Stocking Microchip’s MPLAB Snap Development Tool

Global distributor Mouser Electronics is now stocking the MPLAB Snap in-circuit debugger and programmer from Microchip Technology. The MPLAB Snap provides affordable, fast, and easy debugging and programming of most PIC, AVR and SAM flash microcontrollers and dsPIC digital signal controllers (DSCs), using the powerful graphical user interface of MPLAB X integrated development environment (IDE).
The Microchip MPLAB Snap board, available from Mouser Electronics, features a powerful 32-bit 300 MHz SAM E70 Arm Cortex-M7 based microcontroller for quicker debug iterations. The debugger system executes code, like an actual device, because it uses the target device’s built-in emulation circuitry, instead of a special debugger chip. All available features of the device are accessible interactively and can be set and modified by the MPLAB X IDE interface. Additionally, the board matches the silicon clocking speed of the target device, allowing engineers to run programs at the device’s maximum speed.

The board connects to a computer via high-speed USB 2.0 interface and can be connected to the target device through an 8-pin single in-line (SIL) header. The connector uses two device input/output (I/O) pins and the reset line to implement in-circuit debugging and In-Circuit Serial Programming (ICSP™) capability. Along with its support for a wide target voltage range of 1.20 V to 5.5 V, the MPLAB Snap supports advanced interfaces such as 4-wire JTAG and Serial Wire Debug with streaming data gateway. It is also backward compatible for demo boards, headers and target systems using 2-wire JTAG and ICSP.

Microchip Technology | www.microchip.com

Mouser Electronics | www.mouser.com

MCUs Eye Closed-Loop Control Applications

Microchip Technology has introduced the new PIC18 Q10 and ATtiny1607 families, featuring multiple intelligent Core Independent Peripherals (CIPs) that simplify development and enable quick response time to system events. Advancements in the architecture of PIC and AVR 8-bit microcontrollers (MCUs) have optimized the devices for implementing closed-loop control, enabling systems to offload the Central Processing Unit (CPU) to manage more tasks and save power.

Well suited for applications that use closed-loop control, a key advantage of using the PIC18 Q10 and ATtiny1607 MCUs are the CIPs that independently manage tasks and reduce the amount of processing required from the CPU. System designers can also save time and simplify design efforts with the hardware-based CIPs, which significantly reduce the amount of software required to write and validate. Both families have features for functional safety and operate up to 5 V, increasing noise immunity and providing compatibility with the majority of analog output and digital sensors.

Offered in a compact 3 mm x 3 mm 20-pin QFN package, the new ATtiny1607 family is optimized for space-constrained closed-loop control systems such as handheld power tools and remote controls. In addition to the integrated high-speed Analog-to-Digital Converter (ADC) that provides faster conversion of analog signals resulting in deterministic system response, the devices provide improved oscillator accuracy, allowing designers to reduce external components and save costs.

Among CIPs in the PIC18 Q10 family are the Complementary Waveform Generator (CWG) peripheral, which simplifies complex switching designs, and an integrated Analog-to-Digital Converter with Computation (ADC2) that performs advanced calculations and filtering of data in hardware without any intervention from the core. CIPs such as these allow the CPU to execute more complex tasks, such as Human Machine Interface (HMI) controls, and remain in a low-power mode to conserve power until processing is required.

All PIC18 Q10 products are supported by MPLAB Code Configurator (MCC), a free software plug-in that provides a graphical interface to easily configure peripherals and functions. MCC is incorporated into Microchip’s downloadable MPLAB X Integrated Development Environment (IDE) and the cloud-based MPLAB Xpress IDE, eliminating the need to download software. The Curiosity High Pin Count (HPC) development board (DM164136), a fully-integrated, feature-rich rapid prototyping board, can also be used to start development with these MCUs.

Rapid prototyping with the ATtiny1607 family is supported by ATmega4809 Xplained Pro (ATmega4809-XPRO) evaluation kit. The USB-powered kit features touch buttons, LEDs and extension headers for quick setup as well as an on-board programmer/debugger that seamlessly integrates with the Atmel Studio 7 Integrated Development Environment (IDE) and Atmel START, a free online tool to configure peripherals and software that accelerates development.

The PIC18 Q10 and ATtiny1607 are available today for sampling and in volume production. Pricing for the PIC18 Q10 family starts at $0.77 each in 10,000-unit quantities, and pricing for the ATtiny1607 family starts at $0.56 each in 10,000-unit quantities.

Microchip Technology | www.microchip.com

DIY Arduino-Based ECG System

Cornell University students Sean Hubber and Crystal Lu built an Arduino-based electrocardiography (ECG) system that enables them to view a heart’s waveform on a mini TV. The basic idea is straightforward: an Arduino Due converts a heartbeat waveform to an NTSC signal.

Here you can see the system in action. The top line (green) has a 1-s time base. The bottom line (yellow) has a 5-s time base. (Source: Hubber & Lu)

Here you can see the system in action. The top line (green) has a 1-s time base. The bottom line (yellow) has a 5-s
time base. (Source: Hubber & Lu)

In their article, “Hands-On Electrocardiography,” Hubber and Lu write:

We used the Arduino Due to convert the heartbeat waveform to an NTSC signal that could be used by a mini-TV. The Arduino Due continuously sampled the input provided by the voltage limiter at 240 sps. Similar to MATLAB, the vectorized signal was shifted left to make room at the end for the most recent sample. This provided a continuous real-time display of the incoming signal. Each frame outputted to the mini-TV contains two waveforms. One has a 1-s screen width and the other has a 5-s screen width. This enables the user to see a standard version (5 s) and a more zoomed in version (1 s). Each frame also contains an integer representing the program’s elapsed time. This code was produced by Cornell University professor Bruce Land.

As you can see in the nearby block diagram, Hubber and Lu’s ECG system comprises a circuit, an Arduino board, a TV display, MATLAB programming language, and a voltage limiter.

The system's block diagram (Circuit Cellar 289, 2014)

The system’s block diagram (Circuit Cellar 289, 2014)

The system’s main circuit is “separated into several stages to ensure that retrieving the signal would be user-safe and that sufficient amplification could be made to produce a readable ECG signal,” Hubber and Lu noted.

The first stage is the conditioning stage, which ensures user safety through DC isolation by initially connecting the dry electrode signals directly to capacitors and resistors. The capacitors help with DC isolation and provide a DC offset correction while the resistors limit the current passing through. This input-conditioning stage is followed by amplification and filtering that yields an output with a high signal-to-noise ratio (SNR). After the circuit block, the signal is used by MATLAB and voltage limiter blocks. Directly after DC isolation, the signal is sent into a Texas Instruments INA116 differential amplifier and, with a 1-kΩ RG value, an initial gain of 51 is obtained. The INA116 has a low bias current, which permits the high-impedance signal source. The differential amplifier also utilizes a feedback loop, which prevents it from saturating.

Following the differentiation stage, the signal is passed through multiple filters and receives additional amplification. The first is a low-pass filter with an approximately 16-Hz cutoff frequency. This filter is primarily used to eliminate 60-Hz noise. The second filter is a high-pass filter with an approximately 0.5-Hz cutoff frequency. This filter is mostly used to eliminate DC offset. The total amplification at this stage is 10. Since the noise was significantly reduced and the SNR was large, this amplification produced a very strong and clear signal. With these stages done, the signal was then strong enough to be digitally analyzed. The signal could then travel to both the MATLAB and voltage limiter blocks.

Hubber and Lu’s article was published in Circuit Cellar 289, 2014. Get it now!