11.07.2015 Views

Atmel QTouch Library User Guide

Atmel QTouch Library User Guide

Atmel QTouch Library User Guide

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

1. The channel numbers are allocated based on enabled SNS pins starting from LSBit ofport 1(SNS1) and ending with MSBit of port 2(SNS2).2. The number of SNS pins in a port pair should be equal to the SNSK pins in the same portpair so it can form a pair.3. The first SNS port pin should always be mapped to the first SNSK port pin in any portpair. Similarly the second SNS port pin should always be mapped to second SNSK pinand so on.4. Even sensors with in a port pair should be placed in one mask and odd sensors with-in aport pair should be placed in the second mask. In case of interport, first channel shouldalways start with odd masks and then even masks is filled .5. All the three channels for ROTORS and SLIDERS should be placed within the samemask. And should be in the same port pair.6. Keys on adjacent channels should be placed on different masks.7. For 8 channel case when 2 ports are enabled, the pins for the 8 channels can be spreadon the 2 ports. The pin configuration is done based on the rules mentioned above.8. For 16 channel case when 2 ports are enabled, all the pins for the 16 channels areallocated among the pins of the 2 ports.Example for 8 channel interport mask Calculation with one port pairSNS1=PORTAX X XCh2 Ch1 Ch0X X XSNSK1=PORTBThis example is for interport 8 channel library with only one port pair used.Channel0 is A0B2,Channel1 is A3B5 and Channel2 is A7B7 are enabled for the 8channel library.The SNS_array and SNSK_array masks are calculated by the Qtouch Studio with rulesmentioned above.In this case, the SNS_array and SNSK_array values will be as mentioned below:SNS_array[0][0]=0x41; (SNS even mask for port pair 1)SNS_array[0][1]=0x08; (SNS odd mask for port pair 1)SNS_array[1][0]=0x00; (SNS even mask for port pair 2)SNS_array[1][1]=0x00; (SNS odd mask for port pair 2)SNSK_array[0][0]=0x84; (SNSK even mask for port pair 1)SNSK_array[0][1]=0x20; (SNSK odd mask for port pair 1)908207K-AT42-09/11

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!