Tag archives for MPLAB Code Configurator

Interfacing ENC28J60 Ethernet Controller with PIC Microcontroller – XC8

Ethernet is the leading wired standard for networking as it enables to connect a very large number of computers, microcontrollers and other computer-based equipment to one another. With just a network switch, many different devices can easily communicate with one another with Ethernet, allowing different devices and equipment to be accessed remotely and this also provides a cost-effective and reliable means of remote control and monitoring. For microcontrollers which don't have an integrated Ethernet peripheral, Microchip offers a serial Ethernet chip that can easily be used by any microcontroller with an SPI interface to provide Ethernet capability to the application. The ENC28J60 is a popular 28-pin serial Ethernet chip, 10BASE-T stand alone Ethernet Controller with SPI interface, on board MAC & PHY, 8 Kbytes of Buffer RAM and an SPI serial interface. In this article we will learn how to use the ENC28J60 Ethernet controller with Microchip TCP/IP Lite Stack and MPLAB Code Configurator.

MPLAB® Code Configurator

The MPLAB® Code Configurator (MCC) is a user friendly Graphical User Interface (GUI) plug-in tool for MPLAB® X IDE which generates easy to understand C code that is inserted into an MPLAB® X project, based on the settings peripherals configurations and selections made in the Graphical User Interface (GUI). The generated code can be used in any application program. When starting out with a new project using Microchip 8-bit microcontrollers, setup of the configuration and all the peripherals can be time consuming, especially for new projects. The MPLAB® Code Configurator simplifies this down to a series of simple graphical selections from the menus within the MCC.

Interfacing SD Card With PIC Microcontroller – XC8

A memory card (also called a flash memory card) is a solid-state electronic data storage device used for storing digital information. They are commonly used in many electronic devices, including digital cameras, mobile phones, laptop computers, MP3 players and also in many applications where a large amount of data has to be stored either once or continuously like in data loggers. Memory cards are small, re-writable and are able to retain data without power. In this article we will learn how to interface an SD Card with a PIC Microcontroller with SPI bus to write and read to/from an SD card with MPLAB XC8 and MPLAB Code Configurator.

DC Motor Speed Control using PWM of PIC Microcontroller – XC8

DC motors are used in many industrial, commercial, and domestic applications. We have DC motors in toys, irrigation pumps, robotics, Drills and in many applications. In real life applications turning a motor ON in clockwise or anticlockwise directions or turning it OFF is not always all that is required. The speed of rotation has to be controlled as well. In this article, we are going to learn how to control the speed of a DC motor using the Pulse Width Modulation of a PIC Microcontroller with MPLAB Code Configurator

Interfacing DC Motor with PIC Microcontroller – XC8

DC motors are used in many industrial, commercial, and domestic applications. We have DC motors in toys, irrigation pumps, robotics, Drills and in many applications. In this article, we are going to learn how to interface a DC motor with a PIC Microcontroller, rotating it in either the clockwise or anticlockwise direction using MPLAB XC8 Compiler.

PIC Microcontroller Interrupts – XC8

Interrupts are one of the most powerful features of PIC Microcontrollers, interrupts make it possible to create applications that can respond to external stimulus in real time. An interrupt is basically an event that requires the microcontroller to stop normal program execution and then to jump to execute a program code related to the event causing the interrupt. An interrupt requires immediate attention, only once the microcontroller will finish executing the interrupt code, then it can go back to continue with the main program. The interrupt code is called Interrupt Service Routine (ISR) or Interrupt Handler. In this article we're gonna learn how to implement Interrupts using Interrupt registers and with MPLAB Code Configurator.

Interfacing The DS1307 Real Time Clock With PIC Microcontroller – XC8

The DS1307 is a low power serial real time clock/calender with full binary coded decimal (BCD) clock/calendar plus 56 bytes of Non Volatile Static RAM. The RTC provides year, month, date, hour, minute and second information. The end date of months is automatically adjusted for months fewer than 31 days including leap year compensation up to year 2100. It can operate either in 24-hour format or 12-hour format with AM/PM indicator. Data and Address are transferred serially through a bidirectional I2C bus. DS1307 comes with built-in power sensing circuit which senses power failures and automatically switches to back up supply. Timekeeping operation continues while the part operates from the backup supply. The DS1307 RTC uses an external 32.768kHz Crystal Oscillator and it does not requires any external resistors or capacitors to operate.

Pulse Width Modulation (PWM) with PIC Microcontroller – XC8

Pulse width modulation (PWM) is a technique of controlling the amount of power delivered to an electronic load by switching ON and OFF a digital signal. This is the simplest technique that can be used to produce analog voltages from a digital one. The fraction of the period for which the signal is ON to the total period is known as the duty cycle. The average DC value of the signal can be varied by varying the duty cycle. The duty cycle can be anywhere between 0 (signal is always off) to 1 (signal is constantly on). Suppose, if the signal has +5 V while it is ON and 0 V during OFF condition, then by changing the duty cycle of the signal, the amount of energy transferred to device can be varied. This method is commonly used for controlling speeds of DC motors, brightness of lamps, Sine wave inverters, Digital to Analog Converter (DAC) etc.

PIC Microcontroller Communication with SPI Bus – XC8

The SPI or Serial Peripheral Interface is a synchronous serial communication and allows multiple devices to communicate with a micocontroller(s). There are many devices that support the SPI protocol and can easily communicate with a microcontroller via SPI: A/D converters, D/A converters, SD Cards, DS1306 Real Time Clocks, MAX7219 serial display drivers, 25LC256 Serial EEPROM, etc. The devices don't have to be identical as long as they support SPI protocol. In this article we are going to configure the SPI Peripheral with MPLAB Code Configurator and PIC18F Peripheral Library.