Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

how to make a timer with 4 7-segment LED display

Status
Not open for further replies.

Analyzer

Full Member level 6
Joined
Nov 18, 2001
Messages
374
Helped
3
Reputation
6
Reaction score
3
Trophy points
1,298
Activity points
3,518
how to expand io

Hi there,

I would like to control 3 seven segment Led display with Pic, but i would like to use Pic 16F84A.One of my friend gave me a clue for this but i have no idea how to do this.He saw a circuit like that and it has 3*4015 shift register and a 16F84.So i would like to know how to use 4015 with pic and what is the relation of 4015 and 7 segment led display? Is there another way to to this without 4015? What is 4015? :)

Thanks in advance

Analyzer.
 

74595 ccs

Analyzer said:
What is 4015?
CMOS DUAL 4-STAGE STATIC SHIFT REGISTER WITH SERIAL INPUT/PARALLEL OUTPUT
**broken link removed**
It is a standard logic IC in the 4000 family made by a lot of vendors.

Analyzer said:
Is there another way to to this without 4015?
I think the easiest way is to use the ICM7212:
**broken link removed**

Or the ICM7218:
**broken link removed**
**broken link removed**
 

74hc595 io expand

If you prefer I²C interface, you can use the Philips SAA1064; 4-digit LED-driver with I²C-bus interface:
**broken link removed**
 

icm7218 projects

You only need 7 lines for the 7seg data and 3 multiplex lines to each segment which is no problem with the 16F84. You can also use a BCD to 7 seg decoder IC like a 74LS47 if you want to save on 7 seg data output lines that you may need for other devices.
 

74595 cascade problem

Hi ME,

Thank you for your kind help.I'm grateful to you.I found a piece of schematic, 3*4015 are used for this circuit.All pin9 and pin1 of the ic's are connected to one pin of mcu.Port_A0 is connected to 1D.I can not understand what i can do with ic? What is it for?What relationship with 4015 and 7 segment display?

Thanks in Advance.

Analyzer.
 

pic16f84 hc595

Analyzer said:
Hi ME,

Thank you for your kind help.I'm grateful to you.I found a piece of schematic, 3*4015 are used for this circuit.All pin9 and pin1 of the ic's are connected to one pin of mcu.Port_A0 is connected to 1D.I can not understand what i can do with ic? What is it for?What relationship with 4015 and 7 segment display?

Thanks in Advance.

Analyzer.
The 4015 is used as a port-expander which converts 4-bit serial data to 4-bit parallel data. Pin 1 and Pin 9 is the clock inputs and can be driven from the same serial clock output pin from the PIC. The 4015 data inputs need to be connected to seperate output pins at the PIC. The 4-bit serial data is shifted into the 4015 at each clock cycle, so you need 4 clock cycles to shif in 4 bits. It's very similar to SPI interface, but only 4 bit.
Each output pin from the 4015 controls one segment. There are seven segments plus a dot at each display unit and one 4015 have precisely 8 output pins.
 

pic16f84 port expander 4094

Hi,

I'm trying to expand ports of 16F84A without 74HC595.(Preferrable with 4015) Would you give some examples in ccs c please? I need code+schematic+article etc. everything about this subject.

Thanks in advance.

Analyzer.

Topics have been merged. Don't start a new topic in different forum about same problem!
 

4094 16f84

I have posted chapter 9.8 of this book. The book can be downloaded here:
**broken link removed**


PICmicro MCU C®
An introduction to programming
The Microchip PIC in CCS C
By Nigel Gardner




9.8 SPI Communication

Like I2C, SPI is a two or three wire communication standard to hardware
devices. SPI is usually not a bus, since there is one master and one slave.

One wire supplies a clock while the other sends or receives data. If a third wire
is used, it may be an enable or a reset. There is no standard beyond this, as
each device is different.

The following is C code to send a 10 bits command MSB first to a device.
Note: The shift_left function returns a single bit (the bit that gets shifted out)
and this bit is the data value used in the output_bit function.
Code:
main()
   {
   long cmd;
   cmd=0x3e1;
   for(i=1;i<=6;i++)          //left justify cmd
      shift_left(cmd,3,0);
   output_high(PIN_B0);       //enable device
             //send out 10 data bits each with a clock pulse
   for(i=0;i<=10;++i)
   {
      output_bit(PIN_B1, shift_left(cmd,2,0));
      output_high(PIN_B2); //B2 is the clock
      output_low(PIN_B2);
   }
   output_low(PIN_B1); //disable device
   output_low(PIN_B0);
}
The following is C code to read a 8 bits response. Again shift_left is used,
and the data that is shifted in is bit on the input pin.
Code:
main()
{
   int data;
   output_high(PIN_B0); //enable device
   //send a clock pulse and
   //read a data bit eight times
   for(i=0;i<=8;++i)
   {
      output_high(PIN_B2);
      output_low(PIN_B2);
      shift_left(&data,1,input(PIN_B1));
   }
   output_low(PIN_B0); //disable device
}
The previous are two great examples of shifting data in and out of the
PICmicro®MCU a bit at a time. They can be easily modified to talk to a
number of devices. Slower parts may need some delays to be added.

Some PIC’s have built in hardware for SPI. The following is an example of using
the built in hardware to write and read.
Code:
main()
{
   int data;
   setup_spi(SPI_MASTER | SPI_H_TO_L | SPI_CLK_DIV_16);
   output_high(PIN_B0);
   spi_write(3);
   spi_write(0xE1);
   output_low(PIN_B0);
   output_high(PIN_B0);
   data=spi_read(0);
   output_low(PIN_B0);
}
Note: Built in hardware does have restrictions. For example, the above code
sent 16 bits not 10. Most SPI devices ignore all bits until the first 1 bit, so this will
still work.
 

4094 port expander

Analyzer said:
Hi there,

I would like to control 3 seven segment Led display with Pic, but i would like to use Pic 16F84A.One of my friend gave me a clue for this but i have no idea how to do this.He saw a circuit like that and it has 3*4015 shift register and a 16F84

Analyzer.

All you need is

7 pins for the 3 seven segment + 3 pins for multiplexing = 10 pins only

PIC16F84A have 13 pins (8 for portb and 5 for porta)

This left to you 3 pins for more functions.

You don't need any additional hardware.

Bye
 

how to expand pic16f84a datalines

Three additional pins are not much to play around with.
How many pins do you need for other purposees Analyzer?
 

ht9200a +pic +ccs

Hi,
I used 3x4015 and i have 24 output now.I can expand my ports how much i want.I need 22 outputs, this is enough for me now.Me is right, you know 3 pins is not enough to accomplish projects.Shift registers are very usable to convert serial data to parallel data.74HC595 is also a good shift register but there is a big price difference between 4015 and 74HC595.
Thanks for all your help.I solved my problem.

Analyzer.
 


picmicro code for saa1064

Hi Me,

Yea it is true for other countries but it is not true for my country :)
By the way i can give some clues who interests at these tecnique.I can not supply full project because it is commercial.

Analyzer.
 

pic saa1064 assembleur

I use 4094 serial to parallel konverter and with only 3 wires (clk, data and stobe) you can drive as much displays as you wish (carry from one connect to input of next).


Mr.Cube
 

ccsc de 74hc 595 e data veri gönderme

TPIC6B595 is better than. and can drive load 500mA.
 

icm7218 int char

Hi,

I build a code for expand the i/o of the pic16f84 and similar.
It needs 3 i/o pins of PIC to conevrt them to 8 i/o using 4015.

By simple calculation,

Using (4) 4015 ICs, u can conevrt ALL 13 i/o pins pic16f84 to 33 i/o pins

If you need a code for 74HC595 too reply.

Bye
 

sircuit ic 4015

The 74HCT259 can also be used to expand the output ports
 

display lcd cd4015

Hi,

There are many of shift-register ics we can use them,
But i think 4015 and 74HC595 is the cheapest

SphinX
 

16f 74hc595

Was just thinking...

Is it not possible to cascade shift registers with a clock and data line...

And then use 1 enable line to latch the clocked data to the output.

In this way you can have as many outputs as you like on 3 pins.
Number of outputs are the number of clock cycles.

Think I will try this also...
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top