How to access PH2

Hi guys,

I've designed a PCB for a project using an Atmega 2560 -16AU and for some reason I've connected one of my digital inputs to processor pin 14 (PH2). I now realise that on a standard Mega 2560 board that pin is not used, so I have no idea how to address it using the standard Arduino IDE.

Is it possible to use PH2 as a digital input or should I modify the PCB to use a different pin? I do have some spare pins available (which are used on a standard Mega) but none of them are in a particularly convenient location for my layout. I need to make a decision fairly quickly as the board has already been uploaded for manufacture.

Thanks in advance for any advice.

Gareth

Use Megacore;

PH2 will be pin 73.

Often a good idea to breadboard designs before building PCBs .....

Thank you !

Yes I agree about breadboarding but this is quite a complex board (it has USB, Bluetooth, Canbus, L298 using both channels, LCD output, Current Sensor, supply voltage sensing, 4 relays etc etc) in a 100 x 75 footprint so it would have been a hell of a messy breadboard !

I have tested each individual part, but the last bit I added which I hadn't sanity checked was the HC-05 bluetooth, which for layout convenience I ran the status pin to PH2 without even thinking about whether I could access that pin from the IDE. Thanks to your answer I now know I can so should all be good :smiley:

Thanks again !

Regards,

Gareth

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.