On 9/15/05, Jinx wrote: >=20 > > Doesn't the latter cater for complete portability? It probably > > caters for twice as much overhead; or does the assembler take > > care of that all upon code assembly ? >=20 > It's a bit swings and roundabouts. I think without exception > registers like PORTA/GPIO on 12/16 PICs are always in > bank0, TRIS/TRISIO are in bank1. 18s are not banked so > BANKSEL is unnecessary. If 12/16 code might one day be > ported to an 18 or whatever comes in the future then it would > be best to use a universally compatible style. I suggested > grouping registers with a common bank together to cut down > on clutter - I have a slight leaning towards that, but not at the > cost of code screwing up. I did say that you might rationalise > when you get to know the PIC better, but you should take > note of Olin's comments >=20 >=20 Once I have soaked up all of this new programming 'style' that I have=20 adapted in the past day or two, I shall ask Olin to teach me his advanced= =20 bank selection techniques. He told me that he would do so, once I am=20 comfortable with what I now know. I also still have to look into using the= =20 linker so I don't use have to use "absolute-mode" any more... I can't decid= e=20 what is more important! Anyhow, time for bed! I am sure that I will be found tinkering around with= =20 my source at school tomorrow. Till then I will probably be visualizing what= =20 I have learnt on the back of my eyelids. Sean. -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist