Coder Social home page Coder Social logo

Comments (3)

 avatar commented on June 10, 2024

@Sod-Almighty What do you mean "mapped to the Arduino pin numbers"? Why would that make sense?

Also, of course PA0 == PB0 == PC0 == PD0. They are all macros for 0.

from avr-libc.

Sod-Almighty avatar Sod-Almighty commented on June 10, 2024

Well, it was two years ago, but presumably I meant it would be helpful if PB0 meant "whatever damn arbitrary number Arduino assigns to pin PB0".

After all, how is anyone supposed to know which pin "6" maps to on any given chip? You have to google it. And if it's not mentioned anywhere, you're screwed. I tried looking in the hardware folder for some kind of definition, but didn't find anything. Where are they defined? What is pin 4 on an ATtiny85, for instance?

from avr-libc.

rpavlik avatar rpavlik commented on June 10, 2024

Well, the meanings of those are set out in the datasheet (pa0 means GPIO port A, bit/pin 0 - it's a datasheet concept not an Arduino one, the Arduino pin numbers are indeed somewhat arbitrary so they are in a nice order on original Arduino boards), but that's neither here nor there. (And actually many of these files are generated automatically by atmel/microchip from their internal docs...)

I made this repo literally as just a "mirror" - copy with history - of the upstream avr-libc project (used by Arduino and others) so I could interact with a git repo instead of svn. Unfortunately at that time I couldn't disable issues on a repo. However, it's been years since this has been updated, issues can now be disabled, and I'd strongly recommend looking at upstream docs (search for avr-libc in your preferred search engine) if you're still having issues: it is very in depth though also fairly advanced. Code examples by others should also be helpful and hopefully easy to find - there is a lot of avr sample code out there, even for the attiny chips.

Good luck!

from avr-libc.

Related Issues (4)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.