Hi Joep, On 02/19/12 10:49 am, Joep Suijs wrote: > 2012/2/19 Wouter van Ooijen: >> This seems not a compiler issue to me, more a library issue. Think: the >> TRIS instruction is not something a compiler will generate to implement >> a specific HLL construct. > > A quick scan of the jallib sources did not reveal any use of tris > opcode, I'm not so surprised that you didn't find any 'TRIS' occurence because=20 in Jallib sources, because we use 'PORTx_direction' and=20 'pin_xy_direction' in stead of using TRISx directly. Note: There are a few PICs which don't have a TRISx register, but do=20 have a TRIS instruction (12-bits core). In the Jallib libraries (device=20 files) we hide this for the user (library) with pseudo variables. These=20 'put procedures have to use the TRIS instruction in stead of using the=20 TRISx register, of course. > so I'd like know what triggered this code. The original poster detected the TRIS instruction in the hex file of a=20 program for the 16F628. I agree with Wouter that this must come from=20 user code or a library (probably old). Regards, Rob. --=20 R. Hamerling, Netherlands --- http://www.robh.nl --=20 http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist .