FLowcode V5 + PIC18F45K22 Crystal Clock .. Need Help Please

For questions and comments on programming in general. And for any items that don't fit into the forums below.

Moderators: Benj, Mods

Post Reply
south_wind
Posts: 7
Joined: Mon Jan 04, 2016 3:49 pm
Has thanked: 3 times

FLowcode V5 + PIC18F45K22 Crystal Clock .. Need Help Please

Post by south_wind »

I'm trying to program PIC18F45K22 with flowcode 5 but I have a problem with external clock

I tested my program using 1 sec delay LED but it gave me a delay not equal to 1 sec

even when I interface LCD its not working

Could you please tell me what is wrong , this is my first time I use PIC18F

Thank you
Attachments
clock.jpg
clock.jpg (44.71 KiB) Viewed 8706 times
clock2.jpg
(485.76 KiB) Downloaded 4984 times

medelec35
Matrix Staff
Posts: 9521
Joined: Sat May 05, 2007 2:27 pm
Location: Northamptonshire, UK
Has thanked: 2585 times
Been thanked: 3815 times

Re: FLowcode V5 + PIC18F45K22 Crystal Clock .. Need Help Ple

Post by medelec35 »

Hi south_wind ,
Can you post your flowchart and a full circuit diagram please.
Martin

south_wind
Posts: 7
Joined: Mon Jan 04, 2016 3:49 pm
Has thanked: 3 times

Re: FLowcode V5 + PIC18F45K22 Crystal Clock .. Need Help Ple

Post by south_wind »

Hi Medelec35
I attached my simple test flowchart
I'm using ready for pic from mikroelektronika as a hardware
thank you ..
Attachments
Untitled.jpg
(450.62 KiB) Downloaded 4968 times

medelec35
Matrix Staff
Posts: 9521
Joined: Sat May 05, 2007 2:27 pm
Location: Northamptonshire, UK
Has thanked: 2585 times
Been thanked: 3815 times

Re: FLowcode V5 + PIC18F45K22 Crystal Clock .. Need Help Ple

Post by medelec35 »

Can you please post the flowchart itself, rather than a screen shot.
It makes life easier for us to check it all out.

Since you have not got the free version of Flowcode V5, you will need to register for an account upgrade so you can post in the V5 section.
Take a look at this link

Martin
Martin

south_wind
Posts: 7
Joined: Mon Jan 04, 2016 3:49 pm
Has thanked: 3 times

Re: FLowcode V5 + PIC18F45K22 Crystal Clock .. Need Help Ple

Post by south_wind »

yeah sure sorry for that :) , I'm using 8MHZ external crystal
Attachments
Flowcode1.fcf
(8.5 KiB) Downloaded 311 times

medelec35
Matrix Staff
Posts: 9521
Joined: Sat May 05, 2007 2:27 pm
Location: Northamptonshire, UK
Has thanked: 2585 times
Been thanked: 3815 times

Re: FLowcode V5 + PIC18F45K22 Crystal Clock .. Need Help Ple

Post by medelec35 »

I can help with this issue,
But for the future reference you will need to register for an upgraded account as stated above.
Issue with the flowchart you have posted is the configuration settings are different to the screen shot you posted.
For example in the flowchart you posted, the watchdog timer is enabled you should start off with it disabled.

The extended instruction set, single supply ICSP and portB A/D should also be disabled.

When you program make sure you see programming has been verified.

You are on the right tract to make sure LED is flashing at the correct rate.

Normally LCD Start is placed before the start of the main loop.

Martin
Martin

south_wind
Posts: 7
Joined: Mon Jan 04, 2016 3:49 pm
Has thanked: 3 times

Re: FLowcode V5 + PIC18F45K22 Crystal Clock .. Need Help Ple

Post by south_wind »

Hello medlec35 and thank you for helping me
when I used a 8mhz external crystal and put the setting into 32MHz I guess it works fine , I don't know why ?!!
Attachments
ADJUSTING CLOCK.fcf
(13.5 KiB) Downloaded 308 times

Post Reply