Author Topic: Can I substitute Attiny841 for Attiny85  (Read 1609 times)

0 Members and 1 Guest are viewing this topic.

Offline bigjoncoopTopic starter

  • Contributor
  • Posts: 49
  • Country: us
Can I substitute Attiny841 for Attiny85
« on: March 13, 2022, 12:35:26 am »
hey fellaz,

i was able to purchase a bunch of Attiny841 IC's recently. I found a diy project that's using a Attiny85 and was wondering if could use the Attiny841 instead with out any modification?

and does anyone know of a chart or simple way to easily determine if which attiny and be substituted for which?
 

Online MarkF

  • Super Contributor
  • ***
  • Posts: 2551
  • Country: us
Re: Can I substitute Attiny841 for Attiny85
« Reply #1 on: March 13, 2022, 02:52:40 am »
I haven't worked with the ATtiny families.
You just have to search the datasheets.

However, I will let you answer your own question:

 

Online hans

  • Super Contributor
  • ***
  • Posts: 1642
  • Country: nl
Re: Can I substitute Attiny841 for Attiny85
« Reply #2 on: March 13, 2022, 08:41:11 am »
No those parts have 2 different datasheets.

You can probably port over many peripherals, as they will be coded similar or even use the same register layout but with slight deviations.
« Last Edit: March 13, 2022, 08:49:17 am by hans »
 

Online Kleinstein

  • Super Contributor
  • ***
  • Posts: 14249
  • Country: de
Re: Can I substitute Attiny841 for Attiny85
« Reply #3 on: March 13, 2022, 09:19:32 am »
The Atiny841 has a different number of pins with supply at non compatible pins - so there have to be HW changes.
The SW side would very likely also need changes. Here at least the pheriphery is still very similar (though 16 bit timers instead of 8 bit ones). So the port of the SW should be resonable simple, but still a little work and the code may end up slightly longer.
 

Offline bigjoncoopTopic starter

  • Contributor
  • Posts: 49
  • Country: us
Re: Can I substitute Attiny841 for Attiny85
« Reply #4 on: March 14, 2022, 06:50:07 am »
@Kleinstein
@hans
@MarkF

Thanks for your replys.

But i should have explained my question better. I realize they have different amount of pins and pinout.
What I should have asked is, can I run the same sketch / code on them.
 

Offline sleemanj

  • Super Contributor
  • ***
  • Posts: 3028
  • Country: nz
  • Professional tightwad.
    • The electronics hobby components I sell.
Re: Can I substitute Attiny841 for Attiny85
« Reply #5 on: March 14, 2022, 07:27:09 am »
That all depends on the code.

Since you say "sketch" then I would guess we are talking about Arduino.  When using an appropriate core (https://github.com/SpenceKonde/ATTinyCore) then high level functions and libraries will **probably** work.

Low level stuff will probably **not** work, as registers and so forth will be different.
~~~
EEVBlog Members - get yourself 10% discount off all my electronic components for sale just use the Buy Direct links and use Coupon Code "eevblog" during checkout.  Shipping from New Zealand, international orders welcome :-)
 

Offline westfw

  • Super Contributor
  • ***
  • Posts: 4200
  • Country: us
Re: Can I substitute Attiny841 for Attiny85
« Reply #6 on: March 14, 2022, 08:53:10 am »
All that said, the tiny841 has MORE features than the tiny85, except for the high speed timer clocking.  So it should be easier to get a t85 sketch working on an 841 than the other way around.

 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf