12.07.2015 Views

PICAXE Manual Section 1 - TechnoPujades - Free

PICAXE Manual Section 1 - TechnoPujades - Free

PICAXE Manual Section 1 - TechnoPujades - Free

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

www.picaxe.co.uk<strong>Section</strong> 1 86GETTING STARTEDAppendix F – Configuring <strong>PICAXE</strong>-40X / 40X1 Input-Output PinsTo provide greater flexibility, the input/output pinconfiguration of the <strong>PICAXE</strong>-40X can be varied bythe user.PORTA (legs 2 to 5) provide 4 analogue inputs(default) or up to 4 digital inputs.PORTB (leg 33 to 40) provide 8 fixed outputs.PORTC (leg 15-18. 23-26) provide 8 digitalinputs (default) or up to 8 outputs.PORTD (leg 19-22, 27-30) provide 8 digitalinputsPORTE (leg 8 to 10) provide 3 analogue inputsThis gives a maximum of 20 digital inputs,16 outputs, 7 analogue inputsPORTA FunctionsLeg Default Function Second Function2 analogue 0 porta input 03 analogue 1 porta input 14 analogue 2 porta input 25 analogue porta input 3ResetADC 0 / In a0ADC 1 / In a1ADC 2 / In a2ADC 3 / In a3Serial InSerial OutADC 5ADC 6ADC 7+V0VResonatorResonatorIn c0 / Out c0In c1 / Out c1 / pwm 1In c2 / Out c2 / pwm 2In c3 / Out c3 / i2c sclInput 0 / InfrainInput 1<strong>PICAXE</strong>-40X12345678910111213141516171819204039383736353433323130292827262524232221Output 7Output 6Output 5Output 4Output 3Output 2Output 1Output 0+V0VInput 7 / keyboard dataInput 6 / keyboard clockInput 5Input 4In c7 / Out c7In c6 / Out c6In c5 / Out c5In c4 / Out c4 / i2c sdaInput 3Input 2PORTB / PORTE FunctionsPORTB pins are fixed as outputs and cannot be altered.PORTE pins are fixed as analogue inputs and cannot be altered.PORTC FunctionsLeg Default Second Function Special Function15 input portc 0 output portc 016 input portc 1 output portc 1pwm 1 (output)17 input portc 2 output portc 2pwm 2 (output)18 input portc 3 output portc 3i2c scl clock (input)23 input portc 4 output portc 4i2c sda data (input)24 input portc 5 output portc 525 input portc 6 output portc 626 input portc 7 output portc 7The portC pins can be used as the default inputs, changed to outputs, or usedwith their special function via use of the i2cslave or pwmout commandPORTD FunctionsLeg Default Function Special Function19 input 0 infrared (input)20 input 121 input 222 input 327 input 428 input 529 input 6 keyboard clock (input)30 input 7 keyboard data (input)revolution(c) Revolution Education Ltd. Email: info@rev-ed.co.uk Web: www.rev-ed.co.ukVersion 6.9 07/2009All rights reserved.86

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

Saved successfully!

Ooh no, something went wrong!