Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Who's gonna explain me from a to zz about osscc options

Status
Not open for further replies.

TKS

New Member
pleaze i need to know where to fin the info and how to use it..11

i'm getting mad..

TKS
 
TKS said:
pleaze i need to know where to fin the info and how to use it..11

It's all in the MicroChip datasheets and application notes (as are most things!).

But basically don't get excited over the various options, usually you only use one or two of them - XT for crystals up to 4MHz, and HS for faster crystals - but they seem pretty tolerant anyway!.

I purposely used the 16F628 in my tutorials because it has an internal oscillator, by including the config setting in the source code it removes any worries about oscillators.
 
oww boy

wy you don't untherstand me aftermaking suchs good tutorials..??

the data sheet is like hocus spocus for me..
and i want to learn wy i put something in the asm file..

soow if you can do me a favour..(i hope you do and have fait in it..)
tell me exactly..
: how you come choosing the config you did when you wrote : __config 0x3D18

in the data sheets of the chip used: 16F628 i see this on page 26


bit 7 bit 0
bit 7-4 Unimplemented: Read as '0'
bit 3 OSCF: INTRC/ER oscillator frequency
1 = 4 MHz typical(1)
0 = 37 KHz typical
bit 2 Unimplemented: Read as '0'
bit 1 POR: Power-on Reset STATUS bit
1 = No Power-on Reset occurred
0 = A Power-on Reset occurred (must be set in software after a Power-on Reset occurs)
bit 0 BOD: Brown-out Detect STATUS bit
1 = No Brown-out Reset occurred
0 = A Brown-out Reset occurred (must be set in software after a Brown-out Reset occurs)
Note 1: When in ER Oscillator mode, setting OSCF = 1 will cause the oscillator frequency to change to the frequency specified by the external resistor.


soow tell me please how do you produce 0x3D18 from the text above.

my calc says that: 3D18 = 11110100011000 or has this nothing to do whit it..??

TKS

hope i'm doing right.. and that you can explain..
also hope that i will be able to produce config settings my self.

if you like it more i put my nonworking code here...(masm accepted whit 0 faults..)
 
i need to know because

if i'm not for sure that is good how can i look further..??

whit other words.. how can i go buying stuff if i don't know if i have the money..

if i wanna know i my program is good thirst i will have to check that my settings are correct..

and guess 1 think timing is important..my ledd doesn't flash..
it keepr lighting..

will post the code:
 
Check page 94 :!: :!:
0x3D18 = 11 1101 0001 1000 '14 bit config, 13 to 0.
bit 13-10 =1111 ;Program memory code protection off
bit 9 =0 ;Unimplemented: Read as ‘0’
bit 8 =1 ;Data memory code protection off
bit 7 =0 ;RB4/PGM is digital I/O
bit 6 =0 ;BOD Reset disabled
bit 5 =0 ;RA5/MCLR pin function is digital Input
bit 3 =1 ;PWRT disabled
bit 2 =0 ;WDT disabled
bit 4,1-0=100 ;INTRC oscillator: I/O function on RA6/OSC2/CLKOUT pin

I hope this help !!

STEVE
 
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top