Tag Archives: PIC

Beacon Keyer

Lukas Fässler from Soldernerd published a project showing how he built a PIC-based beacon keyer:

This is likely the first ham radio related project that I document here on this blog
But my very first PIC project was a beacon keyer that I made for my father, HB9BBD. That was in 2013. A beacon keyer is a great project to get started with microcontrollers since it’s not much more than a fancy way of blinking an LED.

Beacon Keyer – [Link]

ICP12 USBSTICK, A New Tool for Signals Control & Monitoring

iCircuit Technologies had produced the iCP12 usbStick, a mini size 28 pin USB PIC IO development board and a good tool for signal monitoring (as oscilloscope), data acquisition and circuit troubleshooting at 1mSec/Samples period.

The iCP12 usbStick is a PIC18F2550 based USB development board that comes preloaded with Microchip’s USB HID bootloader which allows users to upload an application firmware directly through a PC’s USB port without any external programmer. It provides access to its I/O pins through 0.1″ pitch headers. A slide switch is also provided on board to select the operation of the board in Bootloader or Normal mode.

The features of iCP12 are listed as following:

  • Mini size, easy interfacing, high performance and user friendly device
  • Used with PIC18F2553 28-Pin Flash USB PIC MCU
  • Excellent flexibility that allows user to expand the board with plug and play modules
  • Peripheral Features:
    • 13x IO Port (6x 12bit ADC pins, 2x 10 bit PWM/Freq/DAC pins)
    • Serial port emulation (UART Baud Rates: 300 bps to 115.2 kbps)
    • Supported operating systems (32bit/64bit): Windows XP ,Windows Vista, Windows 7, Windows 8, Windows 10, Linux, Mac OS X and Raspberry Pi
    • Maximum Voltage: 5Vdc
    • 100mA current output at VDD pin with over-current protection
    • 20MHz oscillator
    • Green LED – power on indicator
    • 2x LEDs (Green, Red) – status indicator
    • ICSP Connector – on-board PIC programming
    • Switch Mode Selection – Boot or Normal mode

The iCP12 usbStick board is shipped with a preloaded data acquisition firmware that emulates as a virtual COM port to PC. Thereafter, the communication between the PC and usbStick is serial. The firmware also supports basic I/O control and data logging feature. They provide a PC application named SmartDAQ that is specially developed to communicate with the usbStick and control its I/O pins, PWM outputs, and record ADC inputs.

SmartDAQ has a very friendly GUI with real-time waveform displays for 6 analog input channels. The time and voltage axes scales are adjustable. SmartDAQ can log the ADC data in both text and graphic form concurrently. One can utilize this feature to construct a low-cost data acquisition system for monitoring multiple analog sensor outputs such as temperature, accelerometer, gyroscope, magnetic field sensor, etc.

SmartDAQ v1.3 Features:

  • Sampling channel: 6x Analogs (12bits ADC/1mV Resolution) + 7x Digitals (Input/Output)
  • Maximum Sampling rate: 1KHz or 1mSec/Samples
  • Sampling voltage: 0V – 5V (scalable graph) at 5mV Resolution
  • Sampling period:
  • mSec: 1, 2, 5, 10, 20, 50, 100, 200, 500
  • Sec: 1, 2, 5, 10, 20, 30
  • Min: 1, 2, 5, 10, 20, 30, 60
  • Trigger Mode: Larger [>], Smaller [<], Positive edge [↑], Negative edge [↓]
  • Sampling Mode: Continuous, Single
  • Logging Function:
  • Save Format: Text, Graphic, Both
  • Start Time: Normal, Once Trigger, 24-Hour Clock (Auto Run)
  • End Time: Unlimited, Data Size, 24-Hour Clock (Auto Stop)
  • Recorded Data format: Graphic | text | excel

iCP12 is available with the PIC18F2550 for $15, and with the PIC18F2553 for $24.5. You can order it through the official page where you can also get more details about iCP12 and its source files.

You can also see this product preview to know more about its functionality.

PIC16F15386, A New PIC Family Announced By Microchip

Microchip, the well-known manufacturer of microcontrollers and semiconductors, announced this week a new family of 8-bit PIC microcontrollers, the ‘PIC16F15386’.

The new PIC16F15386 family features a 8 MIPS CPU speed, with 2KB RAM and up to 28KB flash memory offered in 8 to 48-pin packages. It also has a dual UART, dual SPI and dual I²C interfaces, one 8-bit timer and two 16-bit timers.

PIC16F15386 Features

  • Enhanced Mid-range Core with 49 Instruction, 16 Stack Levels
  • Flash Program Memory with self read/write capability
  • eXtreme Low Power (XLP)
  • IDLE and DOZE low power modes
  • Peripheral Module Disable (PMD)
  • Peripheral Pin Select (PPS)
  • 4x 10-bit PWMs
  • 2x Capture, Compare, PWM (CCP)
  • Complementary Waveform Generator (CWG)
  • Numerically Controlled Oscillator (NCO)
  • 4x Configurable Logic Controller (CLC)
  • 43 Channels 10-bit ADC with Voltage Reference
  • 5-bit Digital to Analog Converter (DAC)
  • 2x Comparators
  • 1x 8-bit Timers (TMR0/TMR2)
  • 2x 16-bit Timer (TMR1)
  • Window Watchdog Timer (WWDT)
  • Enhanced Power-On/Off-Reset
  • Low-Power Brown-Out Reset (LPBOR)
  • Programmable Brown-Out Reset (BOR)
  • In Circuit Serial Programming (ICSP)
  • PIC16LF15386 (1.8V – 3.6V)
  • PIC16F15386 (2.3V – 5.5V)

PIC16F15386 family comes with essential peripherals like Intelligent Analog, Core Independent Peripherals (CIPs) and communication combined with eXtreme Low-Power (XLP) for a wide range of low-power applications. The family features PWMs, multiple communication, temperature sensor and memory features like Memory Access Partition (MAP) and Device Information Area (DIA).

We’ve always offered a diverse portfolio of products with large market appeal,” said Steve Drehobl, vice president of Microchip’s 8-bit MCU division. “With the combination of the most requested features and peripherals by our large base of PIC MCU users, the flexibility in memory size and package options and the availability of MPLAB Xpress with MCC, we expect the PIC16F15386 family to be popular with experienced and first-time PIC MCU designers.

The PIC16F15386 is also compatible with the MPLAB Xpress IDE and the MPLAB Code Configurator, a graphical programming environment. The family includes 13 unique products that are offered in various package options including PDIP, SOIC, DFN, UDFN, UQFN and SSOP.

All products are available now for sampling and in volume production. Volume pricing starts at $0.33 for the product family.

LED Based Strobe For Entertainment, Events & Warning Signals

Strobe provides regular flashes of light. Usually Strobes are designed using Xenon Tubes. Here is LED based simple solution that can be used as strobe for entertainment and events and also as warning signals. Project is based on PIC16F1825 micro-controller with two digit frequency display.

Project provides TTL output signal, frequency 1Hz-25Hz, Tact switches provided to set the frequency.

This project works along with DC Output Solid State Relay


  • Supply 4.5 to 5V DC
  • Frequency 1Hz To 25Hz
  • Easy Interface with Relay Board
  • Easy Interface with Solid State Relay
  • On Board Power LED
  • On Board Output LED
  • Onboard Switch to set the frequency
  • 2X7 Segment 0.5 Inch Display

LED Based Strobe For Entertainment, Events & Warning Signals – [Link]


Based on my first GPS data logger  I made a new version which is even smaller than the initial design and should be able to fit in any rocket, RC model etc. The new GPS data logger uses micro-SD card and 3.7v LIPO battery as power source. The board was also optimized and the new size is 20mm x 27mm – less than a standard SD card as you can see on the picture to the right.



Some time ago I decoded to make a simple general purpose Data Logger with the following parameters for the project.

  • it should have very simple design that should be doable by most amateurs
  • the Data Logger should write the data in a SD memory card in simple text files
  • minimum 2 ADC channels
  • simple to use and simple settings
  • energy efficient
  • low cost


8 PIN PIC Development Board – PIC12F683


8 PIN SMD PIC development board is a full-featured development board and platform for 8-bit PIC® microcontrollers. This project is a versatile development solution, featuring several options for external sensors, off-board communication and human interface. Additionally, it offers ample room for expansion, making it an excellent solution for developers and engineers looking for a PIC development board. The 8 Pin SO8-SMD PIC Development / Evaluations Board demonstrates the capabilities of Microchip’s 8-bit microcontrollers, specifically, It can be used as a standalone demonstration board with a programmed part. With this board you can develop and prototype with all Microchip’s 8 PIN PIC microcontrollers which doesn’t required crystals (External Oscillator). On board connector for ICSP allows an easy programming. The board has configurable pull ups on all pins can be soldered or abandon as per requirement, All pins has solder Jumpers for pull down.  Onboard 5V regulator, two tact switch, one output connector to interface with 12V Relay board or solid state AC or DC Relay. Board has small prototype area. We have considered PIC12F683 IC for this Board.

8 PIN PIC Development Board – PIC12F683 – [Link]

Atmel ATtiny417/814/816/817 Include Core Independent Peripherals (CIPs)

Atmel tinyAVR microcontrollers are optimized for applications that require performance, power efficiency and ease of use in a small package. All tinyAVR devices are based on the same architecture with other AVR devices. The integrated ADC, DAC, EEPROM memory and brown-out detector let you build applications without adding external components. The tinyAVR also offers Flash Memory for fast, secure and cost-effective in-circuit upgrades that significantly cuts your time to market.

The latest tinyAVR devices (ATtiny417/814/816/817) by Atmel combine AVR core with CIPs (Core Independent Peripherals). PIC microcontrollers with Core Independent Peripherals (CIPs) already raised the performance of 8-Bit-MCUs to a new level. Since the acquisition of Atmel by Microchip, this is the first time the company leverages features from both MCU families.

So, now the question is:

What Is CIP?

In fact, the term CIP or Core Independent Peripherals is pretty much self-explanatory. Microchip’s description of CIP is:

CIPs allow the peripherals to operate independently of the core, including serial communication and analog peripherals. Together with the Event System, that allows peripherals to communicate without using the CPU, applications can be optimized at a system level. This lowers power consumption and increases throughput and system reliability.

Core Independent Peripherals or CIPs are designed to handle their tasks with no code or supervision from the CPU to maintain their operations. As a result, they simplify the implementation of complex logic control systems and give designers the flexibility to innovate.

ATtiny417/814/816/817 with Core Independent Peripherals block diagram
ATtiny417/814/816/817 with Core Independent Peripherals block diagram

ATtiny Models With CIPs:

  • 8-bit Atmel AVR microcontroller with 4KB Flash, 256 bytes SRAM, 128 bytes EEPROM, 20MHz/20 MIPS, two 16-bit timer/counters, one 12-bit timer/counter, RTC, USART, SPI, Two-wire Interface (I2C), 10-bit ADC, 8-bit DAC, analog comparator, accurate internal oscillators and multiple calibrated voltage references, Custom Logic, 10-bytes unique ID, and 24 pins.
  • ATtiny814 :
  • 8-bit Atmel AVR microcontroller with 8KB Flash, 512 bytes SRAM, 128 bytes EEPROM, 20MHz/20 MIPS, two 16-bit timer/counters, one 12-bit timer/counter, RTC, USART, SPI, Two-wire Interface (I2C), 10-bit ADC, 8-bit DAC, analog comparator, accurate internal oscillators and multiple calibrated voltage references, Peripheral Touch Controller (PTC), Custom Logic, 10-bytes unique ID, and 14 pins.
  • ATtiny816 :
  • 8-bit Atmel AVR microcontroller with 8KB Flash, 512 bytes SRAM, 128 bytes EEPROM, 20MHz/20 MIPS, two 16-bit timer/counters, one 12-bit timer/counter, RTC, USART, SPI, Two-wire Interface (I2C), 10-bit ADC, 8-bit DAC, analog comparator, accurate internal oscillators and multiple calibrated voltage references, Peripheral Touch Controller (PTC), Custom Logic, 10-bytes unique ID, and 20 pins.
  • ATtiny817 :
  • 8-bit Atmel AVR microcontroller with 8KB Flash, 512 bytes SRAM, 128 bytes EEPROM, 20MHz/20 MIPS, two 16-bit timer/counters, one 12-bit timer/counter, RTC, USART, SPI, Two-wire Interface (I2C), 10-bit ADC, 8-bit DAC, analog comparator, accurate internal oscillators and multiple calibrated voltage references, Peripheral Touch Controller (PTC), Custom Logic, 10-bytes unique ID, and 24 pins.
ATtiny417/814/816/817 With Core Independent Peripheral flash size and Pin count
ATtiny417/814/816/817 With Core Independent Peripheral flash size and Pin count

The new 8-bit tinyAVR MCUs are available in QFN and SOIC packages with pricing starting at $0.43 for 10K units. Visit Atmel tinyAVR product page for full technical details about the new MCUs.

Build Your Own Cheap Antenna Analyser

Ham radio is the use of radio frequency spectrum for purposes of non-commercial exchange of messages, wireless experimentation, self-training, etc. Developing a ham radio project may requires using an antenna analyser, a device that is used for measuring input frequency and impedance.

There are many types of antenna analysers such as Anritsu VNA Master, RigExpert, MiniVNA, and others. But these analysers are very expensive to buy. They starts from $500 up to thousands of dollars and they are also hard to hack. This guide shows how to construct and use a DIY HF antenna analyzer using Arduino for less than $50.

The project consists of three parts; a Microcontroller, AD9850 DDS module, and a VSWR Bridge.

Block Diagram
Block Diagram

The AD9850 is a CMOS highly integrated device that uses advanced Direct Digital Synthesis (DDS) technology coupled with an internal high speed, high performance, D/A converter and comparator, to form a complete digitally programmable frequency synthesizer and clock generator function.

dds_moduleAD9850 module is a $9 stable, low drift VFO (Variable Frequency Oscillator) fed by a 125 MHz crystal clock. The module covers from 0 to 40 MHz, which are all the HAM HF(High Frequency) frequencies. There are 4 output pins on the device, 2 for Sine Waves (only one Frequency at a time) and two Square wave outputs. The blue pot on the board adjusts the duty cycle of the Square Wave Outputs but has no effect on the Sine Wave Outputs.

AD9850 features:

  • Signal Frequency output range: 0-40MHz
  • 4 Signal outputs; 2 sine wave outputs and 2 square wave outputs
  • DAC SFDR > 50 dB @ 40 MHz AOUT
  • 32-Bit Frequency Tuning Word
  • Simplified Control Interface: Parallel Byte or Serial Loading Format
  • Phase Modulation Capability
  • +3.3 V or +5 V Single Supply Operation
  • Low Power: 380 mW @ 125 MHz (+5 V)
  • Low Power: 155 mW @ 110 MHz (+3.3 V)
  • Power-Down Function
AD9850 Pin Definition
AD9850 Pin Definition

The VSWR (voltage standing wave ratio) bridge is an impedance bridge circuit, which is used to measure the ratio of maximum voltage (Vf+Vr ) to the minimum voltage (Vf-Vr) on a transmission line. The bridge will balanced (0 volts across the detector) only when the test impedance exactly matches the reference impedance. This bridge is easy and cheap to implement and works with up to few GHz frequencies.

VSWR Bridge Diagram
VSWR Bridge Diagram

The microcontroller works as an interface between the DDS and the PC, it receives the sweep parameters from PC, and then it reads the collected voltage and frequency to the PC for each sweep. There are multiple choices about the microcontroller type, you can use either Arduino Micro or PIC. If you choose Arduino, the cost of the project will be around $50, while the cost will be reduced to $20 when using PIC.

Arduino Solution
Arduino Solution
PIC Solution

To display the results which are collected from the device, you need to develop a simple software and run it on the connected PC. The software GUI contains configuration buttons on the right side and 2-axis plane, which will hold the signal shape, on the left side.

If you want to make the project portable, you can replace the PC with a LCD display to show the collected data.

This project is open source, you can find and download schematics and code from here. You also can apply your ideas to enhance the project, such as amplifying power for accurate VSWR, adding bluetooth connection to use with tablet, increasing supported frequencies range, and more.

40 Pin & 28 Pin dsPIC Development Board


The dsPIC Development board has been designed mainly for Motor dsPIC30F4011 Digital Signal Controller in the 40-pin motor control socket and dsPIC30F4012 28 Pin digital signal controller, the board can also be used with other dsPIC ICs. Board provided with 3.3V and 5V regulator, crystal oscillators and a programming connector. In addition, the board is populated with dual header connector for all I/O, reverse supply protection diode, onboard 3.3V & 5V LED, Screw terminal for supply input, push button switch for reset, 6 pin header connector for programming, serial communication  header connector, jumpers for multi serial communication option , electrolytic capacitor for filters. Optional provision for LM317T TO220 Regulator for 3.3V and 5V and Jumper for 3.3V or 5V power supply selection to power up the dsPIC.

40 Pin & 28 Pin dsPIC Development Board – [Link]