MCUdude / MegaCoreX

An Arduino hardware package for ATmega4809, ATmega4808, ATmega3209, ATmega3208, ATmega1609, ATmega1608, ATmega809 and ATmega808
GNU Lesser General Public License v2.1
239 stars 47 forks source link

4809 Serial3 undefined #178

Closed mabwindsor closed 1 year ago

mabwindsor commented 1 year ago

I have a custom board using a 4809. Programming is on MS visual Studio, with VisualMicro IDE The programming and functions have been perfect until last Saturday April 29 2023.
The project uses all the 4 ports, but now it refuses to recognize Serial3. If I use the '3209 chip model it compiles perfectly. I have replaced the Microsoft VS, and the Visual studio, same result.

However, if I use the Arduino IDE, the project compiles.

MCUdude commented 1 year ago

Hi!

I don't make any effort in supporting Visual Micro. If it works with MegaCoreX that great, but I won't do any custom code to make Visual Micro work.

I submitted a new boards manager release yesterday (v1.1.2), but this didn't touch any of the core settings line serial ports. The issue may be that the the code somehow is trying to build for ATmega4808 instead? This only have three serial ports. Can you post the complete build output so I can have a look at what's going on?

mabwindsor commented 1 year ago

4809_Serial3_problem.txt MB

MCUdude commented 1 year ago

Here is a clue:

Core Include Paths
Include Path "file:///C:/Program%20Files%20(x86)/Arduino/hardware/MegaCoreX-master/megaavr/cores/coreX-corefiles"
Include Path "file:///C:/Program%20Files%20(x86)/Arduino/hardware/MegaCoreX-master/megaavr/variants/40pin-standard"

You're building for the 40pin-standard variant, but the 40-pin chip doesn't have a fourth serial port, only Serial0, Serial1, and Serial2. Try building for the the 48-pin standard pinout instead.

mabwindsor commented 1 year ago

Thank you, I thought it was me making an error. The Visual Micro interface does not allow a choice of packages. I will take the matter up with them. Again, thanks for your help.

Mike B

On Wed, May 3, 2023 at 1:22 PM Hans @.***> wrote:

Here is a clue:

Core Include Paths Include Path "file:///C:/Program%20Files%20(x86)/Arduino/hardware/MegaCoreX-master/megaavr/cores/coreX-corefiles" Include Path "file:///C:/Program%20Files%20(x86)/Arduino/hardware/MegaCoreX-master/megaavr/variants/40pin-standard"

You're building for the 40pin-standard variant, but the 40-pin chip doesn't have a fourth serial port, only Serial0, Serial1, and Serial2. Try building for the the 48-pin standard pinout instead.

— Reply to this email directly, view it on GitHub https://github.com/MCUdude/MegaCoreX/issues/178#issuecomment-1533426057, or unsubscribe https://github.com/notifications/unsubscribe-auth/A2KK6XJUSA2AVG5FOTVMCA3XEKH5XANCNFSM6AAAAAAXTF7A4M . You are receiving this because you modified the open/close state.Message ID: @.***>

MCUdude commented 1 year ago

I think it should be possible to change the desired pinout in Visual Micro as well?

mabwindsor commented 1 year ago
Problem solved! Visual Micro does allow package selection.Somehow the selection got changed to the 40pin package, and I didn’t notice.Your analysis of the problem led me to checkout all the settings, and that solved the problem.Many thanks for the help. MikeB Sent from Mail for Windows From: HansSent: May 4, 2023 5:00 AMTo: MCUdude/MegaCoreXCc: mabwindsor; State changeSubject: Re: [MCUdude/MegaCoreX] 4809 Serial3 undefined (Issue #178) I think it should be possible to change the desired pinout in Visual Micro as well?—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you modified the open/close state.Message ID: ***@***.***>