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

Arduino Mega2560 rx1 / tx1 + serial port

2 posters

Go down  Message [Page 1 of 1]

Lomithrani



First and foremost Im quite new to Arduino and hadnt done any cpp for years so thank you VERY much for this wonderfull tool you have done.

I think I may have found a bug hopefully you'll be able to repro.

After some debugging I really didnt understand the output of the serial port monitor of a serial port I had wired to rx1/tx1 , it just wasnt what I was trying to print to it.
My variable was set as such :
_serial = &Serial1;
and rx1 was connected to the tx of the serial port and tx1 to rx of the serial port.

After some debugging and because I was getting desperate I just switched to _serial = &Serial2 and rx2 and tx2 on the arduino and now everything works as expected.

I can send you the whole code / sim if you need but that really seems to be all there is to it.

arcachofo

arcachofo

Hi and thank you for reporting.

There is an error in one of the configuration files.
You can fix it yourself by editing the file:
SimulIDE_version/data/AVR/m640_1280_2560/m640_regs.xml

Change line 242 from this:
Code:
bits="UCPOL1,UCPHA1,UDORD1,USBS1,UPM10,UPM11,UMSEL10,UMSEL11" />

To this:
Code:
bits="UCPOL1,UCSZ10,UCSZ11,USBS1,UPM10,UPM11,UMSEL10,UMSEL11" />

You can do it easily from SimulIDE:
Go to File explorer->data->AVR->m640_1280_2560
And double-click in file m640_regs.xml
It will open in SimulIDE Editor.
Do the changes and save.
Then restart SimulIDE.

Arduino Mega2560 rx1 / tx1 + serial port  Fileex10

Lomithrani



Thanks, I'll try asap !

Sponsored content



Back to top  Message [Page 1 of 1]

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