Author Options:

hex file? Answered

i want the hex of this asm code but when u= i compile it in mplab ide it gives error 113 so how can i fix this or plz give me the hex file

the asm code
;* Name of Project: Flash A LED on RB0 *;

list P = 16f84 ;microcontroller identity
; e.g: 0x033 = hex value

__Config 0x3FF5

org 0x00 ;start of program
bsf status,rp0 ; select bank 1
movlw b'00001110' ;
movwf option_reg
bcf trisB,0 ; make bit,0 of Port B output
bcf status,rp0 ;select programming area - bank0
movlw b'00000001' ;
xorwf portB,f ;

a simple program i wrote to blink an led 


4 Replies

verence (author)2011-07-16

- check the mplab documentation for the meaning of error 113,
- find the place where the error occurs,
- remove the problem
- compile

Select as Best AnswerUndo Best Answer

Grengate (author)verence2011-07-16

robots don't ..... they just do.
Hey robot, even if it compiles it wont flash !
It will only blink...... once

Select as Best AnswerUndo Best Answer

verence (author)Grengate2011-07-16

He, he, true - my PIC got a little bit rusty (I'm more of an Atmel guy).

But to be honest, I didn't read the code at all. If I/you/he/she start/s a compiler and it spits out an error code, the first thing to do is to get the meaning of the error code. Hey, the programmer spent a valuable part of his life to program it in, so spend some to to check it! (btw: after a 5sec Google session: "Symbol not previously defined Error[113]") The compiler (assembler) will most (absolutely) probably spit out an error position (line/column) - so without even knowing nuthing (typo intended) about mplab nor about the problem domain nor about the error location, I would guess that an include is missing, as 'status', 'option_reg', 'trisB', 'portB' are defined nowhere (if mplab is kind of a better project tool, there might be a missing 'reference', 'link', external file' or something similar).

Anyway, find out what an error code means and act accordingly.
Those codes are not random numbers.

And btw.: If you want something blinking, program some kind of loop. (Or use a NE555)

Select as Best AnswerUndo Best Answer

iceng (author)2011-07-15

Its been too long
what is error 113 ??

Select as Best AnswerUndo Best Answer