silly me i had the dir var as byte, it now works with this added change

' Encoder.0 = Ch_A
' Encoder.1 = Ch_B
encoder =(porta&48)>>4

reading the pins individually wont work for me @32mhz