Menu

downloadable Arduino mega 2560 pin map

Rikki
2018-02-28
2019-12-27
  • Rikki

    Rikki - 2018-02-28

    After much searching online, I have yet to discover a GCBASIC "port-to-pin" map for the Arduino mega 2560.
    So I made one that can be used as an include file.

    It simply maps the correct port to the digital or analogue pins as numbered on an arduino PCB.

    Enjoy

     

    Last edit: Rikki 2018-02-28
    • Anobium

      Anobium - 2018-02-28

      Nice piece of work.

      @Rikki. If it acceptable by you I would like to include in the next release. Can you repost with the header below? Then, I can use as the license is then correct.

      '    Library to allow the Arduino mega2560 to work with GCBASIC
      '    Copyright (C) 2018 R. White
      
      '    This library is free software; you can redistribute it and/or
      '    modify it under the terms of the GNU Lesser General Public
      '    License as published by the Free Software Foundation; either
      '    version 2.1 of the License, or (at your option) any later version.
      
      '    This library is distributed in the hope that it will be useful,
      '    but WITHOUT ANY WARRANTY; without even the implied warranty of
      '    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
      '    Lesser General Public License for more details.
      
      '    You should have received a copy of the GNU Lesser General Public
      '    License along with this library; if not, write to the Free Software
      '    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
      
      '    28/02/2018     Created by R. White based on the works of Hugh Considine.  The original works was the the UNO_328p.h pin map
      
      '    Used to connect the correct GCBASIC port to the relevant pin as labelled on an Arduino mega 2560    
      '    i.e GCBasic PORTE.0 corresponds to the pin marked DIGITAL_0 on an Arduino mega 2560 PCB
      
      '    usage example #define BUZZER DIGITAL_12
      '    usage example     set BUZZER out         
      

      Nice. Anobium

       
      • Rikki

        Rikki - 2018-02-28

        @anobium Thanks ! I'm more than happy for this to be included in any releases. Hopefully it will help coders to use the mega 2560 more easily. That preamble you sent is now added to the top of the attached file.

         
        • Anobium

          Anobium - 2018-03-01

          File has been moved to the release Gold build. Item 499 in the release notes.

          Thank you.

           
  • stan cartwright

    stan cartwright - 2018-02-28

    Here's an unofficial diagram of the board as well.

     
    • Rikki

      Rikki - 2018-03-06

      That is the exact diagram I was working from. Didn't think to upload it. The analogue ports can also become digital ports, though before this diagram was published I hadn't realized that. They are not marked on the dozen or so arduino mega 2560 pcbs I own

       
  • Anobium

    Anobium - 2018-03-01

    test

     
  • stan cartwright

    stan cartwright - 2018-03-07

    @Rikki, Anobium sent me the unofficial uno diagram. I found it handy.
    This link is handy info for arduino boards https://www.robot-italy.com/en/blog/progetti/450
    ps I guess you like mega 2560.

     

    Last edit: stan cartwright 2018-03-07

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.