Would you like to react to this message? Create an account in a few clicks or log in to continue.

You are not connected. Please login or register

Support 32-pin versions of ATmega48/88/168/328 Mcu

3 posters

Go down  Message [Page 1 of 1]

CommandMC

CommandMC

The 32-pin versions feature extra VCC and GND pins + ADC7 and ADC6 (Pins 19 and 22), which can be used as two additional Analog Input pins (for example, they are used as line sensor inputs on the AREXX AAR-04).

Context as to why I'd like to see those:
I'm using the above mentioned Mcu in school and, with online school going on, would like to create a digital representation of it. The only thing missing are those two analog input pins.
I've tried to use the Arduino Mega (ATmega2560) to circumvent this, but that does not support Pin Change Interrupts on every pin, a feature I also need.

arcachofo

arcachofo

You can use Arduino Nano which has those extra pins.

And you can add that 32 MLF package and it will work.

CommandMC

CommandMC

Oh, silly me. Didn't think the Nano would have those pins. Gonna use that then, thanks.

How would I go about adding that package? Do I just load the existing Mcu from the .package file and add the pins? Surely that can't be it

arcachofo

arcachofo

How would I go about adding that package?

1- You need to create a package file.

If there is an existing package that is exactly the same, you can use it.

If not:
You can have a look at atmega16m1 package which has square form factor:
SimulIDE_0.4.14-XXX/share/simulide/data/avr/atmega16m1.package

And create a new file for your new package with the proper pin description.
For example for atmega328MLF create the file:
SimulIDE_0.4.14-XXX/share/simulide/data/avr/atmega328MLF.package

You can create  a Logic Symbol package for the same MCU (optional):
SimulIDE_0.4.14-XXX/share/simulide/data/avr/atmega328MLF_LS.package


2- Then you need to add an entry in avs.xml file:
SimulIDE_0.4.14-XXX/share/simulide/data/avs.xml

I would add it below the existing 328 line:
Code:
<item name="atmega328" package="avr/atmega328" data="avr/atmega328" device="atmega328" ></item>
<item name="atmega328MLF" package="avr/atmega328MLF" data="avr/atmega328" device="atmega328" ></item>


Instead of atmega328MLF use whatever name you want.

CommandMC

CommandMC

Sorry for the late reply:
I'm gonna take a look at this after finishing my current project. If/When I get it working, would you want me to upload the files here?

Fizik_S

Fizik_S

Of course we want to see your project. You can upload the files here:
https://simulide.forumotion.com/f12-projects-made-in-simulide

arcachofo likes this post

Sponsored content



Back to top  Message [Page 1 of 1]

Permissions in this forum:
You cannot reply to topics in this forum