Forum - MCS Electronics

 

FAQFAQ SearchSearch RegisterRegister Log inLog in

Atmega328PB UART Question

 
Post new topic   Reply to topic    www.mcselec.com Forum Index -> BASCOM-AVR
View previous topic :: View next topic  
Author Message
TSEYFARTH

Bascom Member



Joined: 01 Jul 2006
Posts: 1054

usa.gif
PostPosted: Mon Aug 24, 2020 8:39 pm    Post subject: Atmega328PB UART Question Reply with quote

Hello all,

Is there anything special that needs to be done to use both of the USART's on the Atmega328PB?

Thanks,
Tim

(BASCOM-AVR version : 2.0.8.3 )
Back to top
View user's profile
EDC

Bascom Expert



Joined: 26 Mar 2014
Posts: 1135

poland.gif
PostPosted: Tue Aug 25, 2020 7:00 am    Post subject: Reply with quote

Im guessing.
Before any "Print" you should $baud=xxx and $baud1=xxx

You should "Open " Com1:" As #1 For Binary and then "Open "Com2:" For Binary As #2....->then
It is connvinient to make aliases for each of ones.
Const Usb = 1
Const Lora = 2

Print #usb , "Test should work"
Print #lora , "Should work too, but for second USART"

end
Back to top
View user's profile Visit poster's website
TSEYFARTH

Bascom Member



Joined: 01 Jul 2006
Posts: 1054

usa.gif
PostPosted: Tue Aug 25, 2020 5:54 pm    Post subject: Reply with quote

Hello and thank you for your reply EDC,

So nothing special then.
Great!

Thank you again.
Tim
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    www.mcselec.com Forum Index -> BASCOM-AVR All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum