learning mplab ide

Discussion about projects that used PIC Microcontroller, Hardware Interface, Programming Algorithm and etc......

Re: learning mplab ide

Postby sxmplab » Thu Jul 19, 2012 10:41 pm

robosang WROTE:I think you are using Assembly code, right?



i use notepad to open the ASM file, then copy the code inside and paste to the MPLAB, then try to create HEX file
it can't be do like that? :roll:
sxmplab
Newbie
 
Posts: 12
Joined: Wed Jul 18, 2012 1:31 pm

Re: learning mplab ide

Postby robosang » Thu Jul 19, 2012 10:58 pm

Where did you get the assembly code? Didn't they show the method?

Open the asm file in MPLAB IDE, goto project, Quick Build.
robosang
Expert
 
Posts: 1239
Joined: Wed Jun 10, 2009 5:37 pm

Re: learning mplab ide

Postby sxmplab » Fri Jul 20, 2012 6:54 pm

robosang WROTE:Where did you get the assembly code? Didn't they show the method?

Open the asm file in MPLAB IDE, goto project, Quick Build.




i want to learn how to create HEX file from programming code... :roll:
sxmplab
Newbie
 
Posts: 12
Joined: Wed Jul 18, 2012 1:31 pm

Re: learning mplab ide

Postby ober » Sat Jul 21, 2012 8:31 am

There are many different method to generate hex code from a source code. As robosang highlighted, if you are using assembly code, example from DIY project 1, the LED blinking for PIC16F84A. You can actually refer to the Details Description and follow the step at the back. And that is just one of the methods to generate hex code from assembly code.

If you are using C code, again, there are many methods. We are using MPLAB IDE + Hi-TECH C compiler for PIC16F and MCC18 for PIC18F. The youtube link that I show is the method to compile (in other words, to generate hex code) the C code and further get the hex code.
Ober Choo
Cytron Technologies Sdn Bhd
www.cytron.com.my
User avatar
ober
Moderator
 
Posts: 1486
Joined: Wed Apr 15, 2009 1:03 pm

Re: learning mplab ide

Postby sxmplab » Sat Jul 21, 2012 2:57 pm

ober WROTE:There are many different method to generate hex code from a source code. As robosang highlighted, if you are using assembly code, example from DIY project 1, the LED blinking for PIC16F84A. You can actually refer to the Details Description and follow the step at the back. And that is just one of the methods to generate hex code from assembly code.

If you are using C code, again, there are many methods. We are using MPLAB IDE + Hi-TECH C compiler for PIC16F and MCC18 for PIC18F. The youtube link that I show is the method to compile (in other words, to generate hex code) the C code and further get the hex code.



i try to get HEX file from this but fail :( , could u teach me how to get it?
http://www.micro-examples.com/public/mi ... clock.html

i no build it just want learn to get HEX file from very beginning source code by using MPLAB only :mrgreen:
sxmplab
Newbie
 
Posts: 12
Joined: Wed Jul 18, 2012 1:31 pm

Re: learning mplab ide

Postby zhenning » Sat Jul 21, 2012 7:10 pm

sxmplab WROTE:
ober WROTE:There are many different method to generate hex code from a source code. As robosang highlighted, if you are using assembly code, example from DIY project 1, the LED blinking for PIC16F84A. You can actually refer to the Details Description and follow the step at the back. And that is just one of the methods to generate hex code from assembly code.

If you are using C code, again, there are many methods. We are using MPLAB IDE + Hi-TECH C compiler for PIC16F and MCC18 for PIC18F. The youtube link that I show is the method to compile (in other words, to generate hex code) the C code and further get the hex code.



i try to get HEX file from this but fail :( , could u teach me how to get it?
http://www.micro-examples.com/public/mi ... clock.html

i no build it just want learn to get HEX file from very beginning source code by using MPLAB only :mrgreen:


No wonder you are getting error. It is BASIC source code. You need a BASIC compiler.This is one of the compiler:

http://www.sfcompiler.co.uk/swordfish/
zhenning
Enthusiast
 
Posts: 351
Joined: Thu Dec 30, 2010 12:32 am

Re: learning mplab ide

Postby sxmplab » Sun Jul 22, 2012 12:41 pm

zhenning WROTE:
sxmplab WROTE:
ober WROTE:There are many different method to generate hex code from a source code. As robosang highlighted, if you are using assembly code, example from DIY project 1, the LED blinking for PIC16F84A. You can actually refer to the Details Description and follow the step at the back. And that is just one of the methods to generate hex code from assembly code.

If you are using C code, again, there are many methods. We are using MPLAB IDE + Hi-TECH C compiler for PIC16F and MCC18 for PIC18F. The youtube link that I show is the method to compile (in other words, to generate hex code) the C code and further get the hex code.



i try to get HEX file from this but fail :( , could u teach me how to get it?
http://www.micro-examples.com/public/mi ... clock.html

i no build it just want learn to get HEX file from very beginning source code by using MPLAB only :mrgreen:


No wonder you are getting error. It is BASIC source code. You need a BASIC compiler.This is one of the compiler:

http://www.sfcompiler.co.uk/swordfish/



is it only for 18F4520? i don't know how to use it..
sxmplab
Newbie
 
Posts: 12
Joined: Wed Jul 18, 2012 1:31 pm

Re: learning mplab ide

Postby zhenning » Sun Jul 22, 2012 12:51 pm

You can try proton basic. It should have support for pic16
zhenning
Enthusiast
 
Posts: 351
Joined: Thu Dec 30, 2010 12:32 am

Re: learning mplab ide

Postby zhenning » Sun Jul 22, 2012 12:56 pm

It is written there its written using mikroBASIC. You will need that. I guess it would be a better option compared to proton basic
zhenning
Enthusiast
 
Posts: 351
Joined: Thu Dec 30, 2010 12:32 am

Re: learning mplab ide

Postby sxmplab » Sun Jul 22, 2012 1:56 pm

zhenning WROTE:It is written there its written using mikroBASIC. You will need that. I guess it would be a better option compared to proton basic



is it mean MPLAB was unable to write the programming code inside it and then create HEX file?
only could use MPLAD create HEX file from .asm & .c that's already exist?
sxmplab
Newbie
 
Posts: 12
Joined: Wed Jul 18, 2012 1:31 pm

PreviousNext

Return to PIC Microcontroller

Who is online

Users browsing this forum: No registered users and 11 guests