By all means, use a label! The assembler will let you know (give you an error message) if you branch too far... Reminds me of back when I first started programming the old MC6800. I didn't have an assembler, so I coded it by hand in hex. I got real good at counting forwards and backwards in hex... I'd just start with 0 at the beginning of the next instruction, then count FF, FE, FD, FC, etc. back through the code until I got to where I wanted to branch to... Harold On Tue, 22 Jan 2002 22:59:58 -0500 James Williams writes: > Hello, > > I have been looking at the BRA branch instructions on the 18c > devices and > was wondering if there is a easy way to manage the n variable in the > ASM > editor. I mean, unless you are branching just a few lines of code > below or > above the instruction, it is hard to keep track of how many bytes to > a > routine that is within the ranch of the branch you are tring to get > to. > > Is it possible to use labels for the BRA instruction, so as to hide > the > details of where the branch routine lies? > > For example > > ORG 0x000ff > ... do some test, > BRA SomeRoutine > ..... > > ;This routine is somewhere within the range of the 1024 branch > limit. > SomeRoutine > ....do some work. > > Thanks, > > James > > -- > http://www.piclist.com hint: PICList Posts must start with ONE > topic: > [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: > ->Ads > > FCC Rules Online at http://hallikainen.com/FccRules Lighting control for theatre and television at http://www.dovesystems.com ________________________________________________________________ GET INTERNET ACCESS FROM JUNO! Juno offers FREE or PREMIUM Internet access for less! Join Juno today! For your FREE software, visit: http://dl.www.juno.com/get/web/. -- http://www.piclist.com hint: The list server can filter out subtopics (like ads or off topics) for you. See http://www.piclist.com/#topics