One pin for both an input (switch) and output (LED) ??

Started by Dave Mucha in Piclist12 years ago 2 replies

Hi all, I am looking for a way to use one pin for both an input and an output. An LED is the output. and a switch would be the input. I can...

Hi all, I am looking for a way to use one pin for both an input and an output. An LED is the output. and a switch would be the input. I can see a few ways to have both on one pin, but not sure if there is a preferred way. It seems the simplest way is to have a resistor, and LED and a switch all in series. then pull the LED-switch line down to power the LED, then monitor the voltage to t


Instruction Time

Started by Paul in Piclist12 years ago 12 replies

Hi. I am after a clear answer cause i'm trying the PIC Datasheets and its giving me a headache! What i would like to know is, say my...

Hi. I am after a clear answer cause i'm trying the PIC Datasheets and its giving me a headache! What i would like to know is, say my PIC16F877 is running on a 4MHz clock, how long does it take for example to turn a bit on? If i did this: bsf LED bcf LED How long would the LED be on for? 1us? I have read that most instructions take 1 cycle, which do not? I'm guessing Goto and Call? Hop


Multi Pattern LED Controller

Started by kalingajay in Piclist9 years ago 2 replies

Hi all, I am new to PICs. I found a multi pattern LED controller based on PIC16F628A. It has more than 10 LED patterns and each pattern runs...

Hi all, I am new to PICs. I found a multi pattern LED controller based on PIC16F628A. It has more than 10 LED patterns and each pattern runs a 5 time and automatically jumps to next pattern. I very much like to build project like this. I try to write a program (code) for it but it is very difficult. The program in PIC can't copy because it is locked. Please anyone can help me. ----------...


LED Displays

Started by dump_cmd in Piclist14 years ago

Hi For an upcoming project I am looking for a schematic and program (prefferably in CCS's PICc) to display a scaled analog...

Hi For an upcoming project I am looking for a schematic and program (prefferably in CCS's PICc) to display a scaled analog value on a 4- digit, 7-segment LED display. Does anyone know of such a circuit. Any help would be greatfully received.


HELP- PIC LED flasher

Started by asha_2108 in Piclist13 years ago 4 replies

Hi, does anyone have any source codes for flashing an RGB(tricolour) LED using a PIC 12F675 or similar PIC?? I'm doing a...

Hi, does anyone have any source codes for flashing an RGB(tricolour) LED using a PIC 12F675 or similar PIC?? I'm doing a project on it, and need some help with the coding. Have to use assembler, but even C would do. trying to program it by using different hex


HELP!!!!!!!! switching on an led with 'c'

Started by shaunundergrad in Piclist14 years ago 1 reply

hi guys, i have a reasonable understanding of assembly and a reasonable understanding of 'c', however i have never used the...

hi guys, i have a reasonable understanding of assembly and a reasonable understanding of 'c', however i have never used the two together, we have a lab session in couple of weeks where we have to switch on a led using 'c'(then more complicated things straight after). i


Re: Getting at least 5V@15mA output from RA4 pin of PIC16F72

Started by Eirik Karlsen in Piclist9 years ago

Jason, you asked for 5V out (source) at high current, and there is just no way of doing that. If you just want the LED to light up it is...

Jason, you asked for 5V out (source) at high current, and there is just no way of doing that. If you just want the LED to light up it is probably more common to do as you suggest and sink instead (LED anode to +5V). No need to do the math very accurately, just select a resistor that gives 'good' brightness, and check the current. Use lowest acceptable current... there is little difference i...


Multiple LED's on one pin?

Started by smitty505000 in Piclist14 years ago 19 replies

Hey guys, Do I need a transistor to drive say 10 LED's on one output pin? Its going to be like 220ma. If so what kind of...

Hey guys, Do I need a transistor to drive say 10 LED's on one output pin? Its going to be like 220ma. If so what kind of transistor? Thanks, Smitty


Scrolling LED display

Started by Nandakumar J in Piclist10 years ago 1 reply

Can somebody hilighten me on the method of amking the scrolling LED display Regards jnk

Can somebody hilighten me on the method of amking the scrolling LED display Regards jnk


Weirdest thing ever

Started by Anonymous in Piclist14 years ago 43 replies

I set up an extremely simple program to alternately blink 2 LED's. I have my output pins on my 16F628 connected to 470 Ohm...

I set up an extremely simple program to alternately blink 2 LED's. I have my output pins on my 16F628 connected to 470 Ohm resistors then to the LED. They don't alternate, but when I touch one of the resistors, then everything works fine. Any ideas??


New LED display

Started by leon_heller in Piclist14 years ago

I'm trying out a newish 4-digit 7-segment LED display from Kingbright (CC56-12GWA), I noticed it in the current Rapid Electronics...

I'm trying out a newish 4-digit 7-segment LED display from Kingbright (CC56-12GWA), I noticed it in the current Rapid Electronics catalogue and ordered one. It's got 0.56" high digits (green) and 12 pins, and is much easier to use than the standard displays, being multipl


Portc problems

Started by seicento9999 in Piclist14 years ago 1 reply

Hello All On the 16f873 I am using, portc bits 0 and 1 are used for diagnostic leds. Each pin has a dropper resistor and led to...

Hello All On the 16f873 I am using, portc bits 0 and 1 are used for diagnostic leds. Each pin has a dropper resistor and led to ground. The port is set up as an outputs apart from bits 3 and 4 which are used for I2C comms. One led is set up to flash every time the program ex


Re: LED's - limits for serial wiring

Started by Leon Heller in Piclist13 years ago

----- Original Message ----- From: "Ian Phillips" <> To: <> Sent: Monday, November 22, 2004 9:11 PM Subject: RE: [piclist] Re:...

----- Original Message ----- From: "Ian Phillips" <> To: <> Sent: Monday, November 22, 2004 9:11 PM Subject: RE: [piclist] Re: LED's - limits for serial wiring > > You're right, you do have to be careful and it is usually best no


PIC running way too slow ?

Started by holopoint.rm in Piclist14 years ago 1 reply

I have a PIC18F452 with a 20mhz crystal. I setup timer0 interrupt with a DIV multiplier of 256 20,000,000/4/256/256 = 76...

I have a PIC18F452 with a 20mhz crystal. I setup timer0 interrupt with a DIV multiplier of 256 20,000,000/4/256/256 = 76 interrputs per second. I flip the state of a led each interrupt. from the led blink rate I can see that the interrupt is called once every 3 seconds or so.


Writing to an LED in embedded C

Started by tuurbo46 in Piclist13 years ago 9 replies

Hi Im quite a newbie to embedded C and im in a bit of a muddle. I currently have a tri-led connected to 2 pins(RC4 and RC5)...

Hi Im quite a newbie to embedded C and im in a bit of a muddle. I currently have a tri-led connected to 2 pins(RC4 and RC5) on portc of a 16C773 pic chip(at this point we wont worry about the model of the chip). I have portc bits(RC4 and RC5) set to output mod


16f84 / 16f88 port a differences

Started by Lez in Piclist12 years ago 3 replies

Built the 2 resistor serial link as shown in some pic basic PDF files, and I have had no problem with the 16f84 (1k for pic serout, 22k...

Built the 2 resistor serial link as shown in some pic basic PDF files, and I have had no problem with the 16f84 (1k for pic serout, 22k for serin) re-compiled the program for a 16f88, plugged chip in, data from chip to PC is ok but data from PC to chip is not being seen by the PIC. I have led's on the lines, both led's glow when data is moving, a


question about PIC drain

Started by Phil in Piclist14 years ago 17 replies

I was curious about current draw on the PIC so I set up a couple of test cases and measured the current. My test setup uses a...

I was curious about current draw on the PIC so I set up a couple of test cases and measured the current. My test setup uses a 16F628A, crystal and an LED on the PWM pin. I use PWM to the LED. With PWM at 0 duty, the circuit is drawing 0.6 mA. with the PWM at 100% duty its drawing


Re: please help me with pic12f675 programming for pwm ,adc and led

Started by Paul James E. in Piclist14 years ago 7 replies

Vaishnavi236, Although I won't write the program for you, I will help and guide you however I can. Let me know what you need...

Vaishnavi236, Although I won't write the program for you, I will help and guide you however I can. Let me know what you need to do first. Regards, Jim > Hello , > I am doing a project using PIC MICROCONTROLLER


PIC18F458 Getting Started

Started by Anonymous in Piclist13 years ago 2 replies

Hello, I have worked with the 16 series before and I am mostly familar with it. I am attempting to start a project with the...

Hello, I have worked with the 16 series before and I am mostly familar with it. I am attempting to start a project with the 18F458. Can someone tell me how to construct a simple circuit to blink an LED? I am using C. Thank you, Shamoon


PIC PROBLEM!

Started by Anonymous in Piclist14 years ago 3 replies

Hey, I bought 5 16F628's and I can't get a simple thing to work! I'm using PicBasic and my program is... High 0 And...

Hey, I bought 5 16F628's and I can't get a simple thing to work! I'm using PicBasic and my program is... High 0 And I have a LED hooked up to RB0. To no success. Any help? Shamoon