mikroElektronika | mikroProg Suite for PIC User Manual
Add to my manuals16 Pages
mikroElektronika mikroProg, your recently acquired device, is a user-friendly and feature-rich tool that empowers you to effortlessly program PIC, dsPIC, PIC24, and PIC32 microcontrollers. With its intuitive interface and advanced programming options, mikroProg simplifies the programming process while offering flexibility for experienced users to customize configuration bits. Additionally, it provides valuable information about the selected MCU, monitors voltage levels, and allows for hex code verification.
advertisement
If you are experiencing some problems with any of our products or just need additional information, please place your ticket at www
mikroProg Suite for PIC
™
Manual
Flash program is used to transfer a .hex file from a PC to the microcontroller memory by means of the appropriate hardware. This program includes numerous options used for setting the microcontroller’s configuration bits.
TO OUR VALUED CUSTOMERS
I want to express my thanks to you for being interested in our products and for having confidence in
Mikroelektronika.
The primary aim of our company is to design and produce high quality electronic products and to constantly improve the performance thereof in order to better suit your needs.
Nebojsa Matic
General Manager
The Microchip name and logo, the Microchip logo, Accuron, dsPIC, KeeLoq, microID, MPLAB, PIC, PICmicro, PICSTART, PRO MATE,
PowerSmart, rfPIC and SmartShunt are registered trademarks of Microchip Technology Incorporated in the U.S.A and other countries.
DISCLAIMER
All the products owned by MikroElektronika are protected by copyright law and international copyright treaty.
Therefore, this manual is to be treated as any other copyright material. No part of this manual, including product and software described herein, may be reproduced, stored in a retrieval system, translated or transmitted in any form or by any means, without the prior written permission of MikroElektronika. The manual PDF edition can be printed for private or local use, but not for distribution. Any modification of this manual is prohibited.
MikroElektronika provides this manual ‘as is’ without warranty of any kind, either expressed or implied, including, but not limited to, the implied warranties or conditions of merchantability or fitness for a particular purpose.
MikroElektronika shall assume no responsibility or liability for any errors, omissions and inaccuracies that may appear in this manual. In no event shall MikroElektronika, its directors, officers, employees or distributors be liable for any indirect, specific, incidental or consequential damages (including damages for loss of business profits and business information, business interruption or any other pecuniary loss) arising out of the use of this manual or product, even if MikroElektronika has been advised of the possibility of such damages.
MikroElektronika reserves the right to change information contained in this manual at any time without prior notice, if necessary.
HIGH RISK ACTIVITIES
The products of MikroElektronika are not fault – tolerant nor designed, manufactured or intended for use or resale as on – line control equipment in hazardous environments requiring fail – safe performance, such as in the operation of nuclear facilities, aircraft navigation or communication systems, air traffic control, direct life support machines or weapons systems in which the failure of Software could lead directly to death, personal injury or severe physical or environmental damage (‘High Risk Activities’). MikroElektronika and its suppliers specifically disclaim any expressed or implied warranty of fitness for High Risk Activities.
TRADEMARKS
The Mikroelektronika name and logo, the Mikroelektronika logo, mikroC, mikroC PRO, mikroBasic, mikro-
Basic PRO, mikroPascal, mikroPascal PRO, AVRflash, PICflash, dsPICprog, 18FJprog, PSOCprog, AVRprog, 8051prog, ARMflash, EasyPIC5, EasyPIC6, BigPIC5, BigPIC6, dsPIC PRO4, Easy8051B, EasyARM,
EasyAVR5, EasyAVR6, BigAVR2, EasydsPIC4A, EasyPSoC4, EasyVR Stamp LV18FJ, LV24-33A, LV32MX,
PIC32MX4 MultiMedia Board, PICPLC16, PICPLC8 PICPLC4, SmartGSM/GPRS, UNI-DS are trademarks of Mikroelektronika. All other trademarks mentioned herein are property of their respective companies.
All other product and corporate names appearing in this manual may or may not be registered trademarks or copyrights of their respective companies, and are only used for identification or explanation and to the owners’ benefit, with no intent to infringe.
©Mikroelektronika TM , 2010, All Rights Reserved.
mikroProg Suite for PIC
TABLE OF CONTENTS
Introduction to mikroProg Suite for PIC Program ............................................................................. 4
Installation of Program mikroProg Suite for PIC .............................................................................. 5
1.0. mikroProg Suite for PIC Program’s Main Window ..................................................................... 7
2.0. Loading .hex File into the Program ........................................................................................... 8
3.0. Programming Microcontrollers ................................................................................................... 9
4.0. Program’s Menus ...................................................................................................................... 10
5.0. Advanced Options ...................................................................................................................... 11
6.0. Additional Settings and Information ........................................................................................... 12
7.0. Keyboard Shortcuts and Command Line Parameters ............................................................... 14
3
MikroElektronika
4 mikroProg Suite for PIC
Introduction to mikroProg Suite for PIC Program
Program mikroProg Suite for PIC™ is intended for programming PIC®, dsPIC®, PIC24® and PIC32® microcontrollers from Microchip®.
The graphic interface of this program is clear and easy-to-use, which makes the use of this program faster. The program’s main window includes basic options for programming microcontrollers. In addition, there are also advanced programming options that enable experienced users to set configuration bits on their own. The program also includes views providing basic information about the selected MCU, voltage monitoring, etc.
MikroElektronika
mikroProg Suite for PIC
Installing Program mikroProg Suite for PIC
The installation file of the mikroProg Suite for PIC program is provided on the product CD that comes with development systems or the hardware programmer. This file can also be downloaded from Mikroelektronika’s website www.mikroe.com
5
Step 1:
Start the installation of the mikroProg Suite for PIC program from the product CD by double clicking on the installation file. If you want to install this program from the hard disk, you should just double click on the installation file icon.
The first window to appear is a welcome window providing the basic information on the program installation.
Click on the Next button.
Step 2:
The Licence Agreement window includes the terms on program usage.
Read it carefully and if you accept all the terms stated click the I accept
the terms of the License Agreement option, then Next.
Step 3:
This window contains options that enale you to choose the user of the program. We recommend you to select the Install for All Users option.
Click on the Next button.
NOTE: You can go one step back during the installation process by clicking the Back button.
MikroElektronika
6
Step 4:
Here you will find information on the destination where the program will be installed. In case you want to change this destination and install your program on another one, click the Browse button and select the folder you want from the window to appear.
Click the Install button.
Step 5:
The Progress bar enables you to monitor the programming progress on the screen. For more information click on the Show details button.
mikroProg Suite for PIC
Step 6:
The last window informs you that the mikroProg Suite for PIC program has been succesfully installed. Click the Finish button to close this window.
Connect your development system or hardware programmer to a PC and start up the mikroProg Suite for PIC program after that by double clicking on the mikroProg Suite for PIC program icon or via the Start menu:
Start-Programs-Mikroelektronika-mikroProg Suite for PIC.
NOTE: The shortcut of the program is automatically created on the desktop with the program installation.
MikroElektronika
mikroProg Suite for PIC
1.0. mikroProg Suite for PIC Program’s Main Window
By starting up the mikroProg Suite for PIC program, a window, containing all the programming options, appears. These options are graphically presented in the form of buttons, drop-down lists and check boxes.
7
Drop-down list for MCU family selection
Drop-down list for MCU type selection
MCU programming buttons
Button to show the Configuration
Bits window where you can set MCU configuration bits
Button to show the MCU info window including basic information on selected microcontroller
.hex file options
Button to show hex code to be written to EEPROM memory of the microcontroller
Progress bar to follow the programming progress
Figure 1-1: Main window
Button to show hex code to be written to
FLASH memory of the microcontroller
Button to show options for hex code verification and visual settings
USB option shows whether the hardware programmer/development system is connected to the PC’s USB connector
MikroElektronika
8 mikroProg Suite for PIC
2.0. Loading .hex File into the Program
For programming the microcontroller, it is necessary to write a program in the appropriate compiler first. The program is compiled then and a .hex file used for programming the microcontroller is generated. Prior to loading the .hex file into the program, select family and type of the microcontroller to be programmed. Use the MCU Family option to select the microcontroller family. By clicking on this option, a drop-down list with available microcontroller families will appear. Select the microcontroller type you want from the dropdown list that appears by clicking on the MCU option. Load the .hex file into the mikroProg Suite for PIC program by clicking on the
Load button. The .hex file can also be loaded via the keyboard shortcut Ctrl+O or the Load HEX option from the File menu. By right clicking on any part of the main window, an extra window including different options will appear. One of them is the Load HEX option.
An alternative way of loading a .hex file is by dragging and dropping it on any portion of the program’s main window.
MCU option
MCU Family option
Figure 2-1: MCU family selection
MCU drop-down list contains all microcontrollers belonging to PIC16F family
After connecting the hardware programmer/development system, the program automatically recognizes which microcontroller families are supported by the connected device. When the connection is established, choose the family and type of the microcontroller to be programmed.
By pressing the Ctrl and O keys at the same time, an option for .hex file loading becomes available on the screen.
The mikroProg Suite for PIC program enables you to load the .hex file by simply dragging and dropping it on any portion of the program’s main window (drag and drop).
Figure 2-2: MCU type selection
Figure 2-3: HEX file options
Figure 2-4: Loading .hex file via the File menu by clicking on the Load HEX option
Figure 2-5: By right clicking on any portion of the program’s main window, a menu containing programming options will appear. One of them is the
Load HEX option
MikroElektronika
mikroProg Suite for PIC
By clicking on the Load button, a new window enabling a simple file search will appear. Here you will find a .hex file to program your microcontroller with. Select the file you want and click on the Open button. The selected file will be automatically loaded into the
mikroProg Suite for PIC program, after which you can start programming the microcontroller.
9
Drop-down menu with folders containing .hex file
Double click on the file name to open it
Shortcuts to folders containing .hex file
Open button is used to open the selected file
Figure 2-6: Open window
3.0. Programming Microcontrollers
The process of programming microcontrollers can start as soon as the .hex file is loaded into the mikroProg Suite for PIC program.
Just click on the Write button. The Progress bar enables you to follow the programming progress expressed in percentage.
Read button used to read the hex code from the microcontroller memory
Verify button used to verify the loaded hex code
Erase button used to erase the MCU memory contents
Figure 3-1: MCU programming option
Write button used to load the .hex file into the microcontroller memory
Blank button used to check whether the MCU is empty
Reset button used to reset the microcontroller
Figure 3-2: Progress bar
MikroElektronika
10 mikroProg Suite for PIC
4.0. Program’s Menus
In addition to the button-like basic options, the program’s main window also contains menus, drop-down lists and check boxes. In the upper part of the window, there are File, USB, Info and Minimize menus including options that provide information on connected USB programmers, .hex file, mikroProg Suite for PIC program, as well as options for loading .hex file into the program and writing it into the microcontroller memory.
.hex file loading
.hex file saving
.hex file reloading
Showing information on .hex file
Exiting mikroProg Suite for PIC
Figure 4-1: File menu
Figure 4-2: Reload option
Use the Reload option to load some of the previously loaded .hex files. By clicking the
Clear History option, a list with previously loaded .hex files will be deleted.
Use the Info option to access the window containing information on the loaded .hex file. Here you can find .hex file name, its address in the microcontroller memory, as well as its size and attributes.
Figure 4-3: File Information window
Figure 4-4: USB option with drop-down menu
MikroElektronika
Showing connected hardware programmers/development systems
mikroProg Suite for PIC
Program mikroProg Suite for PIC allows you to connect several hardware programmers/development systems to USB ports on the PC. By clicking on the USB-Show Devices option or on the icon positioned in the lower right corner of the program’s main window, a window containing a list of all connected hardware programmers/development systems will appear. You should select one of the available devices to be programmed as it is not possible to simultaneously program two or more of them. By clicking on the hardware programmer/development system you want, a LED marked PRG/
ICD will be turned on.
In case no hardware programmers/development systems is connected to the
USB port of the PCU, the icon is gray .
11
Minimizing the main window
History of program’s development
Showing data about the program
Figure 4-5: Select USB Programmer Device Window Figure 4-6: Info option with drop-down menu
5.0. Advanced Options
By clicking on the Options button, a window containing advanced options Program/Verify Options, Advanced Options and Visual
Settings will appear. Within the Program/Verify Options section it is possible to disable programming/verification of the microcontroller memory: CODE, Executive, DATA, ID Locations, Configuration Word(s) and BOOT. Verification is performed by clicking on the Verify button, Figure 3-1.
The Advanced Options section includes the following options: Verify Chip Writies, Disable Vpp-First mode entery,
Preserve DATA and Clear Buffers Before Load. The Verify
Chip Writies enables automatic verification of the loaded code.
The Visual Settings option is used to select visual program settings as well as to disable hints.
Figure 5-1: Options window Figure 5-2: Options button
MikroElektronika
12 mikroProg Suite for PIC
6.0. Additional Settings and Information
Along the right side of the main window, there are buttons providing an access to windows containing additional settings and information on the microcontroller, as well as an option for monitoring voltage level changes during programming. All the windows (Configuration
Bits, MCU Info and Voltages) may be active at the same time.
Button to access the Configuration Bits window
Button to show information on selected microcontroller
Figure 6-1: Additional options and settings
By clicking on the Config button, a window Configuration Bits will appear. The window contains options for setting configuration bits of the microcontroller such as hex code protection, selection of the memory location to write the hex code in, etc.
Hex code protection option
Option for disabling data to be loaded into some MCU’s FLASH memory locations
Options for setting microcontroller’s parameters
Callibration word protection
Button to set configuration bits to default values
Figure 6-2: Configuration bits settings
MikroElektronika
mikroProg Suite for PIC
Depending on the type of the selected microcontroller, the Configuration Bits window may contain different options. For example, the
PIC16F887 microcontroller contains the Oscillator option, whereas the PIC10F200 microcontroller doesn’t. Similarly, the Code Protect option is standard for almost all microcontrollers and is used to protect hex code loaded into the microcontroller’s FLASH memory against unauthorized reading. The Clear button used to set configuration bits to default values is also considered as a standard one.
A click on the MCU INFO option opens a window containing basic data about the selected type of the microcontroller as well as voltage monitoring options. Example in figure 6-3 shows data on the PIC16F887 microcontroller such as: microcontroller’s memory size, number of integrated modules and I/O pins, microcontroller’s operating speed, etc. In addition, there are links to web pages where you can find the recommended development system and compiler for the selected microcontroller. There is also a link to the manufacturer’s website where you can find a complete documentation for the selected microcontroller.
13
The Voltage Options section contained in the Voltages window is used to monitor changes of the Vpp programming voltage and Vcc power supply voltage of the microcontroller in use. The programming voltage is provided by the programmer at the beginning of the programming. Depending on the type of the microcontroller, the
Vpp programming voltage can be up to 13V.
When the programming process is finished, the programming voltage value is set back to the power supply voltage value.
Voltage reading is automatically performed by checking the box next to the Enable Monitoring Voltages option or manually by clicking on the Read Voltages button.
Figure 6-3 shows the values of the Vpp and Vcc voltages during programming the PIC16F887 microcontroller.
Figure 6-3: Information on the PIC16F887 microcontroller Figure 6-4: Voltages window used to monitor voltages when the programmer is connected to a PC via USB cable
Button to check voltage level manually
Enable Monitoring Voltages option to check voltage level automatically
MikroElektronika
14 mikroProg Suite for PIC
7.0. Keyboard Shortcuts and Command Line Parameters
Keyboard Shortcuts: Alt+E Erase the contents of the microcontroller’s memory
Alt+B Program memory blank check (whether it is empty)
Alt+W Write a hex code into microcontroller (F11 key may be optionally used)
Alt+V Verify the loaded hex code
Alt+R Read program memory
Alt+D Change microcontroller type
Alt+F Open File menu
Alt+U Open USB menu
Alt+I Open Info menu
Alt+M Minimize man window
Ctrl+S Save hex code
Ctrl+O Open (load) file with hex code
Ctrl+R Reload hex code
Command Line:
Example 1:
The mikroProg Suite for PIC programmer may also be set up from the command line, which enables you to use it from some other software, compiler etc. Here is a list of the command line parameters:
-p
-f
-b
-q
-w
-v
-e
-r
Write to MCU
Verify
Erase program from MCU
Read program from MCU
Microcontroller type
.hex file name (FLASH) “[<name should be enclosed within quotation marks>]”
Memory blank check (whether it is empty)
Close the mikroProg Suite for PIC program after programming mikroProg Suite for PIC.exe -w -pPIC24FJ96GA010 -v -f”C:\somefile.hex”
This command is used for loading C:\somefile.hex into the PIC24FJ96GA010 microcontroller. This file will be verified immediately after being loaded into the microcontroller.
Example 2:
Example 3: mikroProg Suite for PIC.exe -r -pPIC24FJ96GA010
This command is used for reading the contents of the PIC24FJ96GA010 microcontroller’s program memory. mikroProg Suite for PIC.exe -e -pPIC24FJ96GA010
This command is used to erase program from the PIC24FJ96GA010 microcontroller.
MikroElektronika
TO OUR VALUED CUSTOMERS
I want to express my thanks to you for being interested in our products and for having confidence in
Mikroelektronika.
The primary aim of our company is to design and produce high quality electronic products and to constantly improve the performance thereof in order to better suit your needs.
Nebojsa Matic
General Manager
The Microchip name and logo, the Microchip logo, Accuron, dsPIC, KeeLoq, microID, MPLAB, PIC, PICmicro, PICSTART, PRO MATE,
PowerSmart, rfPIC and SmartShunt are registered trademarks of Microchip Technology Incorporated in the U.S.A and other countries.
DISCLAIMER
All the products owned by MikroElektronika are protected by copyright law and international copyright treaty.
Therefore, this manual is to be treated as any other copyright material. No part of this manual, including product and software described herein, may be reproduced, stored in a retrieval system, translated or transmitted in any form or by any means, without the prior written permission of MikroElektronika. The manual PDF edition can be printed for private or local use, but not for distribution. Any modification of this manual is prohibited.
MikroElektronika provides this manual ‘as is’ without warranty of any kind, either expressed or implied, including, but not limited to, the implied warranties or conditions of merchantability or fitness for a particular purpose.
MikroElektronika shall assume no responsibility or liability for any errors, omissions and inaccuracies that may appear in this manual. In no event shall MikroElektronika, its directors, officers, employees or distributors be liable for any indirect, specific, incidental or consequential damages (including damages for loss of business profits and business information, business interruption or any other pecuniary loss) arising out of the use of this manual or product, even if MikroElektronika has been advised of the possibility of such damages.
MikroElektronika reserves the right to change information contained in this manual at any time without prior notice, if necessary.
HIGH RISK ACTIVITIES
The products of MikroElektronika are not fault – tolerant nor designed, manufactured or intended for use or resale as on – line control equipment in hazardous environments requiring fail – safe performance, such as in the operation of nuclear facilities, aircraft navigation or communication systems, air traffic control, direct life support machines or weapons systems in which the failure of Software could lead directly to death, personal injury or severe physical or environmental damage (‘High Risk Activities’). MikroElektronika and its suppliers specifically disclaim any expressed or implied warranty of fitness for High Risk Activities.
TRADEMARKS
The Mikroelektronika name and logo, the Mikroelektronika logo, mikroC, mikroC PRO, mikroBasic, mikro-
Basic PRO, mikroPascal, mikroPascal PRO, AVRflash, PICflash, dsPICprog, 18FJprog, PSOCprog, AVRprog, 8051prog, ARMflash, EasyPIC5, EasyPIC6, BigPIC5, BigPIC6, dsPIC PRO4, Easy8051B, EasyARM,
EasyAVR5, EasyAVR6, BigAVR2, EasydsPIC4A, EasyPSoC4, EasyVR Stamp LV18FJ, LV24-33A, LV32MX,
PIC32MX4 MultiMedia Board, PICPLC16, PICPLC8 PICPLC4, SmartGSM/GPRS, UNI-DS are trademarks of Mikroelektronika. All other trademarks mentioned herein are property of their respective companies.
All other product and corporate names appearing in this manual may or may not be registered trademarks or copyrights of their respective companies, and are only used for identification or explanation and to the owners’ benefit, with no intent to infringe.
©Mikroelektronika TM , 2010, All Rights Reserved.
If you are experiencing some problems with any of our products or just need additional information, please place your ticket at www
mikroProg Suite for PIC
™
Manual
Flash program is used to transfer a .hex file from a PC to the microcontroller memory by means of the appropriate hardware. This program includes numerous options used for setting the microcontroller’s configuration bits.
advertisement
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Related manuals
advertisement
Table of contents
- 4 Introduction to mikroProg Suite for PIC Program
- 5 Installation of Program mikroProg Suite for PIC
- 7 1.0. mikroProg Suite for PIC Program’s Main Window
- 8 2.0. Loading .hex File into the Program
- 9 3.0. Programming Microcontrollers
- 10 4.0. Program’s Menus
- 11 5.0. Advanced Options
- 12 6.0. Additional Settings and Information
- 14 7.0. Keyboard Shortcuts and Command Line Parameters