Page 1 of 1

FlowCode V5 for PIC - internal oscillator issue

Posted: Mon May 14, 2012 5:38 pm
by iamwhoiam
Hi all. I am trying to find the correct option in FlowCode 5 for PIC, to set the INTERNAL oscillator for my PIC 16F628A, and it is SO confusing!

Here is where I go, in FlowCode: "Build >> Project options >> General (tab) >> Configure chip"

The options I see for the oscillator are pretty confusing, considering I am used to "INTRC NOCLKOUT" or similair. Would someone be kind enough to show me which option means "internal oscillator, NO clock output", please, as this is bemusing at the very least.

Thank you, God bless :-)

Re: FlowCode V5 for PIC - internal oscillator issue

Posted: Mon May 14, 2012 6:27 pm
by medelec35
Hi iamwhoiam,
You need to select

Code: Select all

INTOSC I/O
(INTernal OSCillator with RA6 as Input/Output)

Don't forget to disable

Code: Select all

Watchdog Timer
and

Code: Select all

Low Voltage Programming

Martin

Re: FlowCode V5 for PIC - internal oscillator issue

Posted: Tue May 15, 2012 12:56 am
by iamwhoiam
medelec35 wrote:Hi iamwhoiam,
You need to select

Code: Select all

INTOSC I/O
(INTernal OSCillator with RA6 as Input/Output)

Don't forget to disable

Code: Select all

Watchdog Timer
and

Code: Select all

Low Voltage Programming

Martin
Thanks! :D

Talk about ambiguous design - they NEED to fix that, and make it abundantly clear what it means. It's all very well THEM knowing (the designers of flowcode) but why not just stick to industry standard descriptions and designations, instead of thinking up and implementing some obscure acronym :-S LOL

Re: FlowCode V5 for PIC - internal oscillator issue

Posted: Tue May 15, 2012 8:39 am
by Steve
iamwhoiam wrote:It's all very well THEM knowing (the designers of flowcode) but why not just stick to industry standard descriptions and designations, instead of thinking up and implementing some obscure acronym
For information, we use configuration naming conventions provided by Microchip.

Re: FlowCode V5 for PIC - internal oscillator issue

Posted: Tue Sep 16, 2014 2:56 am
by Genilsonsa
Hello use Flowcode 5'm wanting to use the internal oscillator used an icon in c OSCCON = 0x60 and when I compile with the error?

Teste.c (148: 2): error: identifier unknown 'OSCCON'
Teste.c (148: 2): error: invalid operand 'OSCCON'
Teste.c (148: 8): error: failed to generate expression

Re: FlowCode V5 for PIC - internal oscillator issue

Posted: Tue Sep 16, 2014 3:08 am
by Genilsonsa
This is the program I want to use the internal oscillator 4mhz.Podem help me?

Re: FlowCode V5 for PIC - internal oscillator issue

Posted: Tue Sep 16, 2014 5:51 am
by STibor
Hi,
Not include the controller "osccon" register.
Internal 4MHz clock by default.
PCON register sets the bit OSCF (1bit) or 4MHz (0bit) from 48kHz.

Re: FlowCode V5 for PIC - internal oscillator issue

Posted: Tue Sep 16, 2014 5:44 pm
by Genilsonsa
Hello sorry so many perguntas.Para use the internal oscillator I no longer use the ICON C "OSCCON = 0 x 60"?

Re: FlowCode V5 for PIC - internal oscillator issue

Posted: Tue Sep 16, 2014 6:13 pm
by STibor
Hello,
Not be used to delete the C code macro or write c code before // characters.
// Post code is not interpreted by the compiler.

Re: FlowCode V5 for PIC - internal oscillator issue

Posted: Wed Sep 17, 2014 10:48 am
by Benj
Hello,

Instead of this.

Code: Select all

OSCCON = 0X60 ;
Try this.

Code: Select all

osccon = 0x60;
Note that the register name and the x in 0x is now lowercase and should now be recognised by the compiler.

Re: FlowCode V5 for PIC - internal oscillator issue

Posted: Sat Sep 27, 2014 2:50 am
by Genilsonsa
Hello moderators and colleagues tested the internal oscillator configured pic 16F628A and INTOSC and put a ICON in C lowercase letter OSCCON = 0x60; .Testei error when compiling the program with the same pic 16F88 and is compiled normalmente.Isso bug Flowcode? Someone can help me?

Re: FlowCode V5 for PIC - internal oscillator issue

Posted: Sat Sep 27, 2014 2:57 am
by Genilsonsa
Every time I compile the error !!!!!!!!!!!!!! If I compile with PIC 16F88 always compile successfully

Re: FlowCode V5 for PIC - internal oscillator issue

Posted: Sat Sep 27, 2014 6:00 am
by medelec35
Hi Genilsonsa,
No it's not a bug.
STibor wrote:Not include the controller "osccon" register.
Internal 4MHz clock by default.
PCON register sets the bit OSCF (1bit) or 4MHz (0bit) from 48kHz.
&
STibor wrote:Hello,
Not be used to delete the C code macro or write c code before // characters.
// Post code is not interpreted by the compiler.
Both statements are absolutely correct!

16F628A only have an internal dual speed oscillator and the default is 4MHz ( 16F828A uses PCON register which by default set at 8 = 4MHz)
This means there is no osccon register that is used like there are in other devices to select desired internal osc speed.

to work at 4MHz.

For your flowchart to compile you must remove osccon C code block as it's not required.
With no osccon register within your target device, you will get an error if left in.

If your hardware is not working then you have some other issue.

Re: FlowCode V5 for PIC - internal oscillator issue

Posted: Mon Sep 29, 2014 12:35 am
by Genilsonsa
Medelec35 Hello thanks for replying and I'm looking on the forums for days trying to understand how to use the internal oscillator and had not gotten a clear explanation so that you deu.Vou test the program in practice to see if it falls to certo.Muito Thanks

Re: FlowCode V5 for PIC - internal oscillator issue

Posted: Mon Sep 29, 2014 5:53 pm
by Genilsonsa
I auditioned with internal oscillator with pic 16F628A and worked here redondinho.Agradeço everyone who helped .Very Thanks