View previous topic :: View next topic |
Author |
Message |
Printpix52
Joined: 18 Jun 2014 Posts: 282 Location: D.F.
|
Posted: Mon May 25, 2020 1:46 am Post subject: ARDUINO UNO_USB_SERIAL MONITOR |
|
|
Hello everyone
I have trouble opening serial monitor on my ARDUINO UNO when I press reset this card ARDUINO UNO already works and every time I compile the program does not load the program at 100% but it stays at 60% and I have to reset them ARDUINO UNO and serial Monitor works .
The BASCOM 2.0.8.2 program. I have to reset every time I compile the program to open the monitor.
My computer is 64 bit window 10 PRO.
Can my BASCOM 2.0.8.2 update them?
I made a simple program as a monitor test in SERIAL.
Code: | $regfile = "m328pdef.dat"
$crystal = 16000000
$hwstack=40
$swstack = 16
$framesize = 32
$baud = 19200
'-------------------------------------------------------------------------------
'****************************[Configuraciòn]************************************
'-------------------------------------------------------------------------------
'*************************[Variables/Constante]*********************************
'-------------------------------------------------------------------------------
'*************************[Programa Principal]**********************************
Do
Print "HOLA MUNDO"
Waitms 200
Loop
End |
|
|
Back to top |
|
|
albertsm
Joined: 09 Apr 2004 Posts: 5913 Location: Holland
|
Posted: Mon May 25, 2020 10:01 am Post subject: |
|
|
I have no clue what you mean.
But lets be clear : this forum is not for support on ARDUINO serial monitor or ARDUINO. It is for using BASCOM-AVR with arduino hardware.
If you use bascom and arduino at the same time (the serial monitor) you get a problem with either bascom or arduino when you want to open the same serial port.
bascom uses the serial port for the programmer and for the terminal emulator.
bascom can directly program arduino boards but you need to have the right settings : Select Programmer 'ARDUINO' , 115200 baud and the proper COM port
see also the arduino-uno example:
Code: |
'-------------------------------------------------------------------------------
' ARDUINO-UNO-REV3.BAS
' (c) 1995-2020, MCS Electronics
' This is a sample file for the Mega328 based ARDUINO board UNO REV3
' Select Programmer 'ARDUINO' , 115200 baud and the proper COM port
'-------------------------------------------------------------------------------
$regfile = "m328def.dat" ' used micro
$crystal = 16000000 ' used xtal
$baud = 19200 ' baud rate we want
$hwstack = 40
$swstack = 40
$framesize = 40
Config Clockdiv = 1 ' either use this or change the divider fuse byte
'-------------------------------------------------------------------------------
Config Portb = Output ' make portb an output
Do
Toggle Portb ' toggle level
Waitms 1000 ' wait 1 sec
Print "UNO REV3" ' test serial com
Loop
|
other arduino loaders might require different baud.
of course you can always use the External programmer mode too which calls avrdude, that is the same programmer used by arduino. _________________ Mark |
|
Back to top |
|
|
Printpix52
Joined: 18 Jun 2014 Posts: 282 Location: D.F.
|
Posted: Mon May 25, 2020 4:52 pm Post subject: |
|
|
Hi Alberstm.
Code: | But lets be clear : this forum is not for support on ARDUINO serial monitor or ARDUINO. It is for using BASCOM-AVR with arduino hardware. |
Yes It is for using BASCOM-AVR with arduino hardware.
Code: | If you use bascom and arduino at the same time (the serial monitor) you get a problem with either bascom or arduino when you want to open the same serial port. |
No, Arduino close and BASCOM open
Quote: | bascom uses the serial port for the programmer and for the terminal emulator. |
Yes
[/img] |
|
Back to top |
|
|
Printpix52
Joined: 18 Jun 2014 Posts: 282 Location: D.F.
|
Posted: Mon May 25, 2020 5:04 pm Post subject: |
|
|
Code: | bascom can directly program arduino boards but you need to have the right settings : Select Programmer 'ARDUINO' , 115200 baud and the proper COM port |
|
|
Back to top |
|
|
Printpix52
Joined: 18 Jun 2014 Posts: 282 Location: D.F.
|
Posted: Mon May 25, 2020 5:09 pm Post subject: |
|
|
But BASCOM_AVR is not working by terminal emulator.
I type the ARDUINO reset and this error appears.
I attach the photos
[img][/img] |
|
Back to top |
|
|
Printpix52
Joined: 18 Jun 2014 Posts: 282 Location: D.F.
|
Posted: Mon May 25, 2020 5:13 pm Post subject: |
|
|
AVR_Simuladr works fine and BASCOM-AVR terminal emulator does not work.
Besides, a black box with the mouse appears.
[img][/img] |
|
Back to top |
|
|
albertsm
Joined: 09 Apr 2004 Posts: 5913 Location: Holland
|
Posted: Mon May 25, 2020 7:21 pm Post subject: |
|
|
i recommend to look at your own screen shots. especial the one from the programmer and the red text. it gives a clear clue.
also, the simulator has nothing to do with this. _________________ Mark |
|
Back to top |
|
|
Printpix52
Joined: 18 Jun 2014 Posts: 282 Location: D.F.
|
Posted: Mon May 25, 2020 10:36 pm Post subject: |
|
|
Good I leave them because I am already working on this BASCOM AVR Simulator program.
And the black square restangular because it didn't have them like this in BASCOM 2.0.8.2 it had them working well.
I will wait for the latest update 2.0.8.3. |
|
Back to top |
|
|
Printpix52
Joined: 18 Jun 2014 Posts: 282 Location: D.F.
|
Posted: Tue May 26, 2020 12:02 am Post subject: |
|
|
But my STK500 card works very well 100% works well with simulator and emulator terminal.
ARDUINO UNO does not work well on USB, something is wrong with the BASCOM 2.0.8.2 program.
[img][/img] |
|
Back to top |
|
|
albertsm
Joined: 09 Apr 2004 Posts: 5913 Location: Holland
|
Posted: Tue May 26, 2020 8:45 am Post subject: |
|
|
you use $regfile for a M328 while the programmer detects a M328P.
it would be the same if you use M128 and select M88.
it is visible in RED in the screen shots you made.
this means you need to alter the $regfile or use the M328 which you told the compiler you use. _________________ Mark |
|
Back to top |
|
|
O-Family
Joined: 23 May 2010 Posts: 320 Location: Japan
|
Posted: Tue May 26, 2020 10:10 am Post subject: |
|
|
It seems that the Arduino reset command cannot be accepted from the BASCOM-programmer when the user's program is running and a large amount of data continues to be sent to the PC from the serial line.
I think the Mega328P keeps sending data, blocking commands.
If the transmission interval is 500mS or more, it is operating normally.
Code: |
Do
Print "HOLA MUNDO"
Waitms 500
Loop
End
|
|
|
Back to top |
|
|
Printpix52
Joined: 18 Jun 2014 Posts: 282 Location: D.F.
|
Posted: Tue May 26, 2020 7:40 pm Post subject: |
|
|
albertsm wrote: | you use $regfile for a M328 while the programmer detects a M328P.
it would be the same if you use M128 and select M88.
it is visible in RED in the screen shots you made.
this means you need to alter the $regfile or use the M328 which you told the compiler you use. |
I will check again. |
|
Back to top |
|
|
Printpix52
Joined: 18 Jun 2014 Posts: 282 Location: D.F.
|
Posted: Tue May 26, 2020 7:41 pm Post subject: |
|
|
O-Family wrote: | It seems that the Arduino reset command cannot be accepted from the BASCOM-programmer when the user's program is running and a large amount of data continues to be sent to the PC from the serial line.
I think the Mega328P keeps sending data, blocking commands.
If the transmission interval is 500mS or more, it is operating normally.
Code: |
Do
Print "HOLA MUNDO"
Waitms 500
Loop
End
|
|
I'm going to try and check. |
|
Back to top |
|
|
Printpix52
Joined: 18 Jun 2014 Posts: 282 Location: D.F.
|
Posted: Tue May 26, 2020 9:25 pm Post subject: |
|
|
My ARDUINO_UNO chip is atmega328p already fixed and Waitms of 300 ------ >>> 1000 works fine !!!! wow !!
Already resolved and 100% ARDUINO_UNO works
The bad was the time Waitms 200 does not work well.
I did minimum test is 300 to 1000 if you load the program.
I have not noticed but had them working before the old version BASCOM X.X.X.X.
Thank you very much to my friend albertm and o_Family
[img][/img] |
|
Back to top |
|
|
Printpix52
Joined: 18 Jun 2014 Posts: 282 Location: D.F.
|
Posted: Wed Jul 15, 2020 5:37 am Post subject: |
|
|
Printpix52 wrote: | AVR_Simuladr works fine and BASCOM-AVR terminal emulator does not work.
Besides, a black box with the mouse appears.
[img][/img] |
After update 2.0.8.3
[img][/img] |
|
Back to top |
|
|
|