Before logging an issue, please update to the latest release of Visual Micro from the Downloads Page.

When Logging a Support Issue in the Forum, please ensure you have also:-

  • Enabled vMicro > Compiler > Show Build Properties
  • Re-Compile your program with these settings enabled
 
Save the new Output to a Text File and....
  • Click the Reply button and attach as .txt file OR
  • Click here to Email us with the file attached, and a link to your post
Support requests without the output above may be impossible to answer, so please help us to help you
 
Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Serial not declared in this scope (Attiny85 project) (Read 4460 times)
bivalvo
Newbies
*
Offline


Posts: 5
Joined: Sep 9th, 2019
Serial not declared in this scope (Attiny85 project)
Sep 9th, 2019 at 12:33pm
Print Post  
Hello everybody!

I'm new in this community, so first of all, I have to say that I'm very happy of being part of this. Hello!

And now, my question: I've created a IDE project with target: Attiny85. When I try to build, the log shows me an error 'Serial not declared in this scope', which is logic, because Attiny85 has not a HW Serial Port. The main problem is that 'Serial' is not appearing anywhere on my code. In fact, the error is pointing to a code line which is completely empty... So I guess that Serial library is included in my project by default. The problem is that I don't know exactly where is the interface to exclude libraries from my project... It's kinda hidden menu for me right now...

Can anybody help me? I would be grateful. Smiley

PS: Excuse my english, it's not my mother language.
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12071
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Serial not declared in this scope (Attiny85 project)
Reply #1 - Sep 9th, 2019 at 12:47pm
Print Post  
You can not use serial debug mode with the tiny. Please change the configuration name on the tool bar from Debug to Release.

If the problem continues please set vMicro>Debugger>Off. If it is already set to Off then select Off again.
  
Back to top
WWW  
IP Logged
 
bivalvo
Newbies
*
Offline


Posts: 5
Joined: Sep 9th, 2019
Re: Serial not declared in this scope (Attiny85 project)
Reply #2 - Sep 9th, 2019 at 7:15pm
Print Post  
OK thank you. It worked for me!

So it's not possible to debug with breakpoints even if I'm on Release mode, right?

Thank you!
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12071
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Serial not declared in this scope (Attiny85 project)
Reply #3 - Sep 10th, 2019 at 11:30am
Print Post  
You need to use Debug for debugging. 

The visual micro usb debugger uses Serial by default but you can override that to use the Transport=SoftwareSerial. Your mcu has little memory so that might not be a solution.

Alternatively you can use hardware debugging in atmel studio but you need to buy the appropriate hardware debugger.

« Last Edit: Sep 10th, 2019 at 11:30am by Tim@Visual Micro »  
Back to top
WWW  
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint