CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

10F200 - MCLR as standard I/O

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
rikotech8



Joined: 10 Dec 2011
Posts: 376
Location: Sofiq,Bulgariq

View user's profile Send private message

10F200 - MCLR as standard I/O
PostPosted: Wed Aug 15, 2012 10:43 am     Reply with quote

I'm using PIC10F200 and I want to use MCLR pin as normal I/O pin.
I declared into fuses NOMCLR but I can't use my GP3 yet.
Here is the code:
Code:

#include <10f200.h>
#use delay(clock = 4M)
#fuses NOMCLR,NOWDT,NOPROTECT

void main()
{
int port_b;
set_tris_b(0);
port_b = 0x0f; //GP0.....GP3 - set.
#byte port_b = 0x06; //thr address of PORT_B
}

From GP0 to GP2 I have high level output.
On GP3 I have high impedance.
One more question. How to set the oscillator: internal 4Mhz?
FvM



Joined: 27 Aug 2008
Posts: 2337
Location: Germany

View user's profile Send private message

PostPosted: Wed Aug 15, 2012 11:17 am     Reply with quote

A brief datasheet reading is suggested:
Quote:
Please note that GP3 is an input only pin.


PIC10F200 has 4 MHz internal oscillator as the only oscillator option. Nothing to setup.
rikotech8



Joined: 10 Dec 2011
Posts: 376
Location: Sofiq,Bulgariq

View user's profile Send private message

PostPosted: Wed Aug 15, 2012 12:42 pm     Reply with quote

I see. Thank you!
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
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


Powered by phpBB © 2001, 2005 phpBB Group