Cristiano If you only need a couple of levels, you can use a transistor to switch in/out another external resistor. Or, if the display is driven from a separate supply, you can change the voltage of this. If you need to vary the brightness over a range, then PWM is the way to go. RP 2009/12/8 Marcel Birthelmer : > On Mon, Dec 7, 2009 at 7:22 PM, Cristiano Cesaretto > wrote: >> Hi all. >> I was wondering if someone has an advice for a driver for a 7 segments >> display. I need to be able to adjust the brightness of the display "in >> software", with a command. The display drivers I have found so far expect an >> external resistor to set the brightness level. >> >> Other approaches are ok, if I can get the same result. I also have enough >> pins to connect directly avery single segment of the display, if this helps. > > The way to go would be to use a PWM signal to strobe the LEDs at a > frequency of 100Hz or so, with a duty cycle proportional to the > desired brightness. You can accomplish this either by driving a > transistor in the common anode/common cathode of the LED display, or > by using AND gates to AND the PWM signal to the drive inputs of each > of the segments. If you have multiple digits that you're looking to > multiplex, it gets more interesting. I've used a NAND gate that fed > four logic-level FETs connected to each of four common cathode LED > digits, so that each digit could be turned on/off at will and also > brightness-regulated via the PWM. > -- > http://www.piclist.com PIC/SX FAQ & list archive > View/change your membership options at > http://mailman.mit.edu/mailman/listinfo/piclist > -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist