3/29/2013

AT90CAN128 Программатор микроконтроллеров AVR / 89S совместимый с AVR910



Схема программатора приведена на рисунке ниже. Предохранитель F1 служит для защиты линий питания порта USB от случайного замыкания по цепям питания программатора. Диоды VD1, VD2 – обычные выпрямительные, с прямым падением напряжения ~0,6…0,7В, предназначены для понижения питания микроконтроллера DD1 до 3,6 В. Согласно документации ATMEL на ATmega8(L), микроконтроллер может работать при таком напряжении питания до частоты немногим выше 14 МГц. Светодиоды VL1(“RD”), VL2(“WR”) сигнализируют о текущих действиях программатора, и, соответственно, обозначают режимы чтения и записи. Светодиод VL3(“PWR”) предназначен для сигнализации подачи питания на программатор.




 Джампер J1 – (MODify) служит для начального программирования управляющего МК программатора. При его замыкании, к разъему ISP подключается внешний программатор и производится загрузка в МК управляющей программы. После программирования управляющего МК программатора этот джампер необходимо разомкнуть и замкнуть джампер J2 - NORMal.
    С помощью джампера J3 LOW SCK возможно понижать тактовую частоту порта SPI МК программатора до ~20 кГц. При разомкнутом джампере частота SPI нормальная, при замкнутом - пониженная. Переключать джампер можно на ходу, так как управляющая программа МК программатора проверяет состояние линии PB0 при каждом обращении к порту SPI. Не рекомендуется переключать джампер при запущенном процессе записи/чтения программируемого МК, т.к., скорее всего, это приведет к искажению записываемых/читаемых данных. Джампер J3 введен для возможности программирования МК AVR, тактируемых от внутреннего генератора 128 кГц.
    Резисторы R10 - R14 предназначены для согласования уровней сигналов МК программатора и внешних, подключенных к программатору, цепей (программируемый МК или другой программатор).
    Тактовая частота порта SPI МК программатора при разомкнутом джампере J3 равна 187,5 кГц. Это позволяет программировать контроллеры с тактовой частотой примерно от 570 кГц для ATtiny/ATmega, 750 кГц для 90S и 7,5 МГц для 89S. Контроллеры программируются от 10 до 30 секунд (при использовании утилиты AVRProg v.1.4 из пакета AVR Studio) вместе с верификацией в зависимости от объема FLASH памяти и тактовой частоты.
    На вывод LED разъема ISP выведен меандр с частотой 1 МГц для "оживления" МК, у которых были ошибочно запрограммированы фьюз-биты, отвечающие за тактирование. Сигнал генерируется постоянно и не зависит от режима работы программатора.
    Программатор тестировался с программами AVRProg v.1.4 (входит в пакет AVRStudio), ChipBlasterAVR v.1.07 Evaluation, CodeVisionAVR, AVROSP (ATMEL AVR Open Source Programmer). Кроме того, программатор тестировался с программой AVRDUDE, однако, программа с данным программатором не совместима, так как не все команды протокола AVR910 отрабатывает корректно.
    На данный момент с вышеперечисленными программами протестировано программирование контроллеров 89S53, 89S8252, 90S2313, 90S8515, ATtiny13, ATtiny26, ATtiny45, ATtiny2313, ATmega48, ATmega8, ATmega8515, ATmega8535, ATmega16, ATmega32, ATmega64, ATmega128, AT90CAN128.
    Я рекомендую повторять схему один-в-один, так как выкидывание "лишних" деталей из схемы может привести либо к неправильному функционированию программатора, либо к возможному выходу из строя USB порта на РС, за что, естественно, я ни какой ответственности не несу.

3/28/2013

Through Hole Devices Are Becoming Hard To Get 2SK170




I had no problems getting the 2SK170 JFETs from Futurlec.  They were on tape.  I don’t know what manufacturer, but they are not Toshiba.

Right now, I think a lot of the major semi makers are abandoning through hole parts, and going to surface mount only.  To get a through hole part, one may have to buy a large amount (a whole reel) or get the part from a maker such as KEC (Korea Electronics), BEL (Bharat Elec) or Rohm.

You can get the National Semi Discrete Data Book 1978 Edition (PDF) from Archive.org.  When you look up a transistor, it tells you the process that it was from.  In other words, the chip inside the transistor is sorted from the chips made by a certain process.  Some have higher specifications, for instance higher gain.  Thes may be sold as 2N3904.  The lower gain chips may be sold as 2N3903.  But they are the same chip, and if the circuit is not critical, you may be able to substitute the 2N3904 for the 2N3903.

 In the Pro Electron Series, you may find that the older transistors such as the BC107 were packaged in the TO-106 package, which is no longer made.  But you may be able to find an equivalent transistor, such as the BC547, using the same process in the TO-92 package, which is common and still being made.

Regarding the 2SK170.  It may not be recommended for new designs, but the replacement, the 2SK880, is not through hole, it’s surface mount, and that would mean redesigning the PC board.  So the assembler must use the 2SK170 until his supply of PC boards has been used up.  The alternative would be to try to find a substitute JFET.  If the JFET is in the Databook, you could find out what process is used, and then find other JFETs that use that process and try to find one that would substitute for the 2SK170.

I also got some 2N7000 MOSFETs.  They also came on tape, but the tape has the side toward the MOSFETs coated with aluminum foil.  This is to prevent damage from static electricity.  The MOSFETs are held onto the the tape with masking tape.  Normally the leads are cut off above the tape as the part is put into the PC board.  The masking tape is never disturbed.  But in my case, I don’t have a machine so I usually pull the part off the tape, and sometimes the masking tape pulls of with the part, sometimes it stays on the tape and the part leads pull free.  The problem here with the MOSFETs is they are more sensitive than JFETs to static.  That’s why there’s the aluminum foil.  And the masking tape is triboelectric.  This means when the tape is pulled off, it generates static electricity.  So by pulling off the MOSFETs I could be causing them to burn out.

What to do?  I could try to duplicate the machine and just cut the leads off above the tape.  But then the leads are shortened and obviously not the same as when they were made.  My thoughts are that if I squeeze the 3 leads between my fingers and pull the MOSFET off the tape, the static from the masking tape will go through my fingers and not damage the MOSFET.  Or should I try to cut the masking tape off before I pull the MOSFET off the foil?  I’ll have to experiment a bit to find out how each works.


3/27/2013

Simplest FM Transmitter S8050



This is the simplest fm transmitter circuit you can ever find on internet,because so many “simple transmitters” (they call it simple but many of them don’t work!) on internet will not work as those circuits are designed poorly. i had built around 100s of transmitters in the past and most of them were built successfully, because the design is just cool and reliable. This circuit is for those who have built many fm transmitters without any sign of working!, so try this one and i am sure you can make it!.



An Fm transmitter is a circuit/device to transmit audio signals to an fm radio receiver through air (wirelessly). The input (audio)to an fm transmitter can be fed using a microphone or the output of your music player to be transmitted, and the signal which you transmit can be received using an FM radio, the advantages of FM TRANSMITTERS ARE many:

1.You may transmit audio to another room/floor of your house without using any wires!

2.You may transmit your own voice if you used an electret microphone in the circuit

3.You don’t need to build a receiver to receive the ransmitting audio as any standard fm radio can be used to receive your voice/audio and many..!



this circuit can transmit audio to a distance of around 50 meters if you used 2n3904 transistor and boost the supply voltage to 6V, and 1Km(1 kilometer) if used S8050 transistor with 9V supply!


Components you need

R1 – 47K resistor

R2 – 100 ohms resistor

C1 – 22n none polarised capacitor

C2 – 1n none polarised capacitor

C3 – 4.7pf none polarised capacitor

c4 – 22n none polarised capacitor

T1 – Transistor BC547(short range),2N3904(medium range,recommended),S8050(long range)

VC1 – 22pf Variable trimmer capacitor (trimcap)

L1 – Aircore inductor, 6turns on a 3mm dia former eg.Wind over a pen refill.

Antenna – a short length wire

3V battery (Use only battery)

Good quality pcb or veroboard. (breadboards may not work)

Testing
after building is done,power the circuit using a 3V battery and connect any audio source to “audio input” pin properly, set an fm radio minimum 3 meters away. Start tuning the radio and tuning the VC1 at the same time untill you receive the transmitting audio, if you can hear the audio then you are DONE!.

Notes

1.All components in the circuit is not intended to change their values

2.Using correct value components in the circuit is vital

3.If the transmitting audio is too loud and unclear, then add a 100K or 1 Mega ohm resistor across the audio input pin, the value of this resistor depends on how much powerful you audio signal is and should be selected untill you get a very clear voice.

3/26/2013

SMART AC POWER STRIP LM358N



The schematic of the Smart Strip circuit is shown. The ac line input is connected directly to the 117-Vac line of a power strip. The voltage is rectified by diode D1 and filtered by capacitor C2. The load-sense lines are connected to the ac socket in the power strip that will contain the device that will be used to turn the others on. When the load sense device is turned on, current flows through R1, a 1-Ω, 10-W resistor. To limit the power in R1 to 5 W, therefore, amaximum load ofno more than 5 A should be connected to the load sense outlet. The resulting voltage drop across R1 is fed to one section of an LM358N op amp, IC1-a, through resistors R2 and R3. Zener diode D4 limits the supply for the op amp to 15 Vdc. The voltage drop across R1 could be very small if the device plugged into the load sense socket does not draw much current. To ensure that the circuit is sensitive enough to detect such small-load devices, the gain of IC1-a is set at 470 by resistors R2 and R4. Because the out-put IC1-a is halfway rectified, diode D2 and capacitor C3 are used to form a peak-hold circuit. As long as CB is charged to 0.7 V or more (when a powered-up load sense device is detected), transistor Q1 will be on, and relay RY1 will close. When those normally open contacts close, the hot line is connected to the "load-switched" sockets, effectively turning on any devices that are connected to those outlets. Diode D1, resistor R6, and capacitor C1 provide a dc supply for the 12-V coil of the relay; diode D3 acts as a clamping diode.

3/25/2013

Scrivere una EEPROM 24C04 usando l'interfaccia I2C


L'articolo descrive come utilizzare l'interfaccia I2C sull'Max2990 per interfacciarsi con una EEPROM 24C04.

Questa application note ed il codice firmware descrivono come l'interfaccia I2C sul modem di comunicazione power-line Max2990 può essere usata per interfacciare con EEPROM 24C04. Il bus I2C è controllato dall'MAX2990 (è il master) ed il 24C04 EEPROM è lo slave. Lo schema seguente mostra la configurazione hardware utilizzata in questo esempio.


L'SCL e l'SDA devono essere configurati come open-drain. Questa configurazione è necessaria per la comunicazione I2C per funzionare correttamente. Dato che l'I2C è una funzione alternativa per una porta GPIO, il firmware deve garantire che il pullup sugli ingressi SCL e SDA è disattivato durante l'inizializzazione.



3/22/2013

Multi-purpose dual power supply regulator board AMS1117



All embedded systems require electric power to operate. Most of the electronic components inside them, including the processors, can operate at a wide range of supply voltage. For example, the operating voltage range for the PIC16F1847 microcontroller is 2 to 5.5 V. But there are certain applications where you need a regulated constant voltage to avoid malfunctioning of the circuit or getting erroneous results. For instance, any application that involves analog-to-digital conversion (ADC) requires a fixed reference voltage to provide accurate digital count for input analog signal. If the reference voltage is not stable, the ADC output is meaningless. Here is my latest dual power supply regulator board that provides constant 3.3V and 5.0V outputs from an unregulated DC input (6.5-10V). It is small in size and can be easily enclosed inside the project box along with a project circuit board. It can also be used to power test circuits on breadboard. The board uses two AMS1117 series fixed voltage regulators and receives input power through a DC wall wart or an external 9V battery.


The regulator circuit uses two AMS1117 series fixed voltage regulators, AMS117 5.0 and AMS1117 3.3, to derive constant 5.0V and 3.3V outputs from an unregulated DC input voltage. The circuit diagram of the board is shown below.


3/21/2013

IR2110 based power stage circuit




I started to build up the Open-BLDC circuit on a breadboard. Then a problem occurred. The low side works as it should but the high side just did not. After several hours of trying and reading the data sheet of IR2110 I gave up and asked Federico again for help. After some time we found an application note AN-978 from International Rectifier. This explained everything. You need to select very carefully the Boot capacitor. This is the one between VB and VS pins of IR2110. It is providing the charge for the gate of the high side MOSFET when you turn it on.

For testing you can take a big capacitor, so that when you manually switch on the high side you see something happen. I took a 330uF capacitor and it is enough to turn the high side MOSFET on for about 30 seconds. Still you have to be careful because the capacitor only gets charged when the low side MOSFET is turned on. So after turning on the power the capacitor is not charged and you have to turn the low side MOSFET on first, then turn it off again and finally switch the high side on.


In the final design one should probably select the right bootstrap capacitor. The equation for calculating that value is described on page 6 of the International Rectifier application note AN-978.


You can probably get rid of the capacitor and the diode if you connect VCC directly to VB. The problem you get then is that when the current on VS gets higher then 12V you get a problem. But I may be mistaken. Correct me if I am wrong.


Conclusion: read the damn application notes and I still have problems with understanding the electrical engineer talk! 


I hope this helps someone. You can see my circuit for one half bridge attached to this post. And a picture of my breadboard.


I use the two LEDs to see what happens with the MOSFETs. They are glowing a little when both sides are off. The one connected to 12V is switching off when the high side is on and the one connected to GND switches off when the low side is on. I love LEDs!

3/20/2013

TIP122-E-C related Technical information


The figure shows a simple rain sensor design that incorporates pitch and volume controls in the alarm signal. Whenever the sensor is bridged by droplets of water, the Darlington transistor TR1/TR2 will conduct. This enables IC1, a 555 astable tone generator, to function, powering a small loud-speaker through a driver transistor (TR3). VR2 determines the pitch of the audio tone, which can be anything from about 25 Hz to 18 kHz, while VR3 adjusts the volume. The sensitivity of the circuit is set by VR1. The Darlington pair could be constructed with two separate ZTX300s or a single TlP122. For the sensor, use a small piece of stripboard, linking alternate strips into an interlocking design. The circuit will operate from a standard 9-V PP3-type battery.




3/19/2013

projects/bench psu personal bench power supply mk1 LM2596



This Hackspace project aims to create simple, low cost, robust, and safe variable voltage power supplies for experimental use in projects. While we have good bench power supplies in the Hackspace it is often useful to have something personal and portable for you projects. It is hoped that the Personal Bench Power Supply will develop over a few iterations as we learn.

I have gone for a very basic specification for the Mk1 version to achieve an availability .
- Low cost £5 to £10
- No exposed mains voltage to builder or user
- Voltage range < 3 Volts to > 12 Volts variable
- Current up to 2A (not variable limited) Fuse protection
- 4mm screw binding post output
- Visual readout of voltage
- Laser cut or simple self build case
- Pocket size
Power Source To achieve the voltage range, current, and safety objectives; a laptop power supply is used. Usually these provide between 16 Volts and 19 Volts and adequate current). These are power supplies are usually very low cost or free.
The plan is to plug the laptop power supply into the variable regulator module. Panel mounted power jack sockets seem common in 2.1mm and 2.5mm pin, but not common in 1.5mm, so a laptop power supply with a 2.1 or 2.5 plug is preferred (need to look into long vs. short plugs)

Regulator Board
From the voltage range, current, and size perspective a switching regulator is most appropriate for the variable regulator. The disadvantage of switching regulators is their higher ripple voltage on the output especially at lower currents.
This is the switching regulator module I chose. The module is low cost at £1 each, and avoids having to make a PCB.

The boards come in a few different pcb layout but generally have the following circuit using the LM2596 regulator.



The TI/National WebBench power supply design too also supports the LM2596. Analysis of the above circuit with the design tool shows that the LM2596 will operate in discontinous mode at the currents we will supply, so ripple on the output may be an issue in some applications.

Voltmeter
The voltmeter is based on a ready built module costing around £1.70 each. It is a 3 digit red LED meter reading from 0 to 99.9V:


The schematic shows the voltmeter is based on an STM8 flash micro and is hackable in itself:



Note: the devices S1 and S2 are not switches, but 4 off 220R resistor array to limit LED current. The digit drive M4 is not used because it is only a 3 digit display.

3/18/2013

Upgrade Parrot CK3000 Evolution with a Max232 chip



In order to make the CK3000 work well with Android phones you will need to upgrade it to version 5.25c. You could do get this done by a professional, or you could buy a rather expensive official cable. I'm making the cable myself with the help of other people who made a similar one first.


This is a simple application of the Max232 chip i have:




I used the original data and power connectors for the upgrade. The data connector has a kind of appendix to which i connected the data wires (not very professional).

I also connected the required wire between pin 9 & 10 (not showing in this pic):


The actual setup on the protoboard.
I used a standard 5V AC/DC adapter.
The capacitors are 1uF 50V (10 cents each):


And now the software process. I used a laptop and a USB-to-serial adapter.

I started using an inverter (DC-to-AC adapter) and it faild almost always. Later i switched to a wall socket and it went better.



* Update process and symptoms:
- Select CK3000 Evolution.
- Select Serial update.
- Select 115200 baud.
- Wait for "XPRAM downloading". Progress bar should not move yet.
   - If progress bar moves there may be something wrong.
   - If it says something like "Cannot set baud rate" probably the wire between pin 9&10 is not ok.
   - If it says something like "Cannot open port" disconnect the usb device, click back and next.
- Power on the parrot. After 1 to 5 seconds progress bar will start moving. It will take about 10 seconds to finish.
   - If you get an error like "Cannot send data" there may be a bad cable.
   - If the bar loops over and over something is wrong. Better try again.
The rest of the process is relatively fast except the "Flash programming" which takes more than one minute.
It can randomly stall or throw the "Cannot send data" error at any time. If it happens try again.
* Myths:
- "If you put two CK3000 close to each other they update the firmware automatically". It didn't happen to me.
- "You can do a wireless update with a bluetooth virtual serial port". I wasn't able to create a serial bluetooth connection. Parrot officially only supports cabled upgrades for the CK3000.

3/15/2013

The PCBs IRF3205 Have Arrived


The PCBs have arrived back from Chiltern Circuits. There are 8 panels, each containing 28 printed circuit boards.
I’ve made a minor change to the circuit too. The IRFZ44N MOSFET has been replaced by an IRF3205. The new transistor has a lower ‘on resistance’ so a little less power is consumed within the device. The Z44N has an on resistance of 17 milliohms (0.017 ohms), but the 3205 is less than half that at just 8 milliohms (0.008 ohms).
The IRF3205 does have a correspondingly higher gate capacitance (about 3.2 nanofarads), so I’ve reduced the gate resistance from 10k ohms to 4k7. Tests confirm that this has little or no effect on the charge pump circuit – the gate voltage is still over 20 volts relative to ground.

3/13/2013

2N3906 Simple sinyal üreteci devresi



Bu devre bir basit signal.It sinyalleri üretebilir, Alternating.Which çalışmak için uygulanabilir ışık ve ses hem de. Bisiklet veya sola çevirin ve bisiklet hakkının Örneğin Taillight için. 2N3906





Güç kaynağı devresi içine girerken. devresi astable çok vibratör gibi Q1 ve Q2 olacaktır tarafından. ON Bu herhangi bir şekilde çalışmak ve ışık kaynağı cihazının (LED1-LED4) için transistors.Connected iki tüm time.And Pin Collection (C) OFF.Or tersi olacaktır. Ses kaynağı cihazına Buzzer BZ1 olduğu için. transistörün bir cihaz C pimi bağlı izin verirken ışık ve her zaman ses sinyali arasında running.The sırayla olduğunu.

3/12/2013

Fuente SMPS con MC34063






Este integrado, es un conversor DC/DC StepUP, StepDown o Inversor de tensión, es decir, puede funcionar como fuente elevadora de tensión, reductora de tensión o bien inversora de tensión.
En este caso se utilizara la configuración elevadora de tensión que es la que realice en la práctica ya que necesitaba extraer 12V a partir de 5V, en este blog van a encontrar otras fuentes similares con el integrado LM2577 o 555, ambas funcionan bien, la que utiliza el 2577 es integrada de potencia pero es la mas costosa por el integrado que utiliza. La que utiliza el timer 555 es la más barata y configurable pero carece de realimentaciones y pwm, etc.…. Por ultimo la que menciono en ese post es similar a la del 2577 pero no es de potencia, es decir, el integrado 34063 solo proporciona 100mA en su salida como máximo pero es posible aumentar esa potencia con un transistor externo, de esta forma le he podido extraer 200mA sobre 12V, lo cual nos permite alimentar algunos dispositivos de baja señal. MC34063

Nótese que he mencionado que solo le extraje 200mA esto es porque esta alimentado con el puerto USB, el cual según normas IEEE nos proporciona unos 500mA como estándar en notebooks y desktops por lo que la limitación esta en el USB, si en cambio lo alimentáramos con 6V desde 4 pilas podríamos extraer mas potencia de salida con ese transistor.
El calculo del choque de RF lo dejare para otro post ya que no viene al caso, la bobina L1 esta construida en un núcleo toroidal de 20mm de diámetro exterior y 15mm de diámetro interior, en el cual se arrollan 20 vueltas de alambre AWG 20 (0,8mm), de esta forma su inductancia ronda los 100uHy claramente se puede comprar el choque ya construido.

La tensión de salida de esta fuente será función de la realimentación del integrado que ingresa por el pin #5 en su interior hay un comparador en donde el mismo integrado posee una tensión de referencia de 1,25V, por ende compara la tensión ingresada en el pin #5 con los 1,25V internos, nótese que si la tensión en este pin es menor a 1,25 la fuente aumentara el ciclo útil del pwm para enviar mayor tensión a la salida, lo mismo pasa en el caso contrario, si la tensión en el pin #5 es mayor a la de referencia reducirá la salida de tensión.
Entonces tendremos que jugar con estos valores de R3 y R4 para lograr la tensión de salida deseada.
El calculo para la tensión en la entrada del comparador es 1,25(1+(R4/R3)).

3/11/2013

UC3842 CURRENTMODE PWM CONTROLLER

The  UC3842  is available in an 8-Pin mini-DIP the necessary features to implement off-line, fixed-frequency current-mode control schemes with a minimal external parts count. This technique results in improved line regulation, enhanced load response characteristics, and a simpler, easier to design control loop. Topological advantages include inherent pulse-by-pulse current limiting.




3/08/2013

Frequency Divider by LM555 and 4040

 

U1 7555 is a CMOS version of 555 LM555 pdf datasheet.
The LM555 here is in Astable Oscillator mode, C1 and C4 are decoupling capacitors 0.1uF value, ceramic disc.
The output is around 100kHz, If C3 is plastic or mica the frequency output will be stable with temperature. It is better to use a crystal oscillator.
The 555 output is fed to clock input of 4040, the output of 555 will be a square wave, on every high to low transition (falling edge or negative transition) the counter increments by one and the output is 12 bit binary.
If input frequency is F the final output at Q12 is F/4096. The period T = 1/F.
If you make the 555 run at 1Hz, C3 around 7uF, Then this circuit becomes a long duration timer, the Q12 period will be 4096 seconds or 68 minutes

3/07/2013

Digital voltmeter using ICL7107



The circuit given here is of a very useful and accurate digital voltmeter with LED display using the ICL7107 from Intersil. The ICL7107 is a high performance, low power, 3.5 digit analog to digital converter. The IC includes internal circuitry for seven segment decoders, display drivers, reference voltage source and a clock. The power dissipation is less than 10mW and the display stability is very high.
The working of this electronic circuit is very simple. The voltage to be measured is converted into a digital equivalent by the ADC inside the IC and then this digital equivalent is decoded to the seven segment format and then displayed. The ADC used in ICL7107 is dual slope type ADC. The process taking place inside our ADC can be stated as follows. For a fixed period of time the voltage to be measured is integrated to obtain a ramp at the output of the integrator. Then a known reference voltage of opposite polarity is applied to the input of the integrator and allowed to ramp until the output of integrator becomes zero. The time taken for the negative slope to reach zero is measured in terms of the IC’s clock cycle and it will be proportional to the voltage under measurement. In simple words, the input voltage is compared to an internal reference voltage and the result is converted in a digital format.
The resistor R2 and C1 are used to set the frequency of IC’s internal clock. Capacitor C2 neutralizes the fluctuations in the internal reference voltage and increases the stability of the display.R4 controls the range of the voltmeter. Right most three displays are connected so that they can display all digits. The left most display is so connected that it can display only “1” and “-“.The pin5(representing the dot) is connected to ground only for the third display and its position needs to be changed when you change the range of the volt meter by altering R4. (R4=1.2K gives 0-20V range, R4=12K gives 0-200V range ).


3/06/2013

An Arduino Compatible Using CP2102





Standard Arduino boards use FTDI’s FT232RL to interface with computer’s USB port. Since FT232R is just a USB to UART converter, it is possible to build an Arduino compatible USB interface using other USB to UART chips.

One such alternative is Silicon Labs‘ CP2102. I particularly like this USB to UART transceiver because very few extra components are required for it to work. As an added benefit, this chip is also cheaper than the ubiquitous FT232R. Of course, there are also a few trade offs. First of all, CP2102 does not provide a bit bang interface (the X3 pins on the Arduino board on the other hand can be used for bit bang operations, but the X3 pins are not soldered with header pins by default and thus for the average users no bit bang support should not be an issue). Secondly, CP2102 does not have the configurable general purpose I/O pins to drive the TX/RX LEDs. There are other minor differences as well (for instance the maximum transmission speed for FT232R is 3Mbps while CP2102 tops at 1Mbps. Both chips are more than adequate for the maximum 115,200 baud rate supported in Arduino environment), but they do not affect the performance in our application of interfacing with Arduino.

Here is the schematics for using CP2102 with ATmega328p (the circuit below is compatible with the Arduino IDE):



3/05/2013

ATmega64 Test Board

Achtung! Abweichend vom Plan müssen folgende Dinge beachtet werden:
Pin 20 ist der Reset-pin. Er ist active-low was bedeutet, er muss über einen Taster auf Masse geführt werden. Drückt man den Taster wird der Pin auf 0V (Ground) gezogen und der yC führt einenr Reset aus
Pin 64 ist die Versorgungsspannung vom A/D-Wandler. Sie muss an die 5V VCC-Leitung angeschlossen werden.
Vielleicht mache ich nochmal ein überarbeitetes Schema
Achtung! Je nach Bauform sind die Pinbelegungen unterschiedlich!!!!! Bei falscher Beschaltung reichen die 5V des USB-Portes aus um die gesamte Schaltung zu grillen. Also vorher mindestens drei mal überprüfen. Die Pinbelegungen im Schaltplan beziehen sich auf auf den ATmega64 Bauform TQFP/MLF und auf den FT232R Bauform QFN32.

3/04/2013

H-Bridge Motor Driver Using Bipolar Transistors 2N2907A



The classic beginner’s DC motor driver circuit that appears in every electronics textbook is the bipolar transistor H-bridge.

An H-bridge is an arrangement of transistors that allows a circuit full control over a standard electric DC motor. That is, an H-bridge allows a microcontroller, logic chip, or remote control to electronically command the motor to go forward, reverse, brake, and coast.

For the purposes of this article, I’m focusing on a basic H-bridge that is a good choice for most robots (including BEAM robots) and portable gadgets. This H-bridge can operate from a power source as low as two nearly-exhausted 'AAA' batteries (2.2V) all the way up to a fresh 9V battery (9.6V).

In later pages, I'll compare the performance of three different part numbers of popular transistors (2N3904/2N3906 vs 2N2222A/2N2907A vs Zetex ZTX1049A/ZTX968) using a common robot motor from Solarbotics.

The H-bridge circuit (below) looks complicated at first glance, but it is really just four copies of a resistor + transistor + diode.


Schematic of a bipolar transistor hbridge circuit to drive a DC motor. Can you see the letter 'H'?
There are many different ways to draw the circuitry, but the above wiring diagram matches the model of most h-bridges.




Q1, Q3: These are NPN transistors. They connect the motor to ground (negative terminal of the battery).
Q2, Q4: These are PNP transistors. They connect the motor to +2.2V to +9.6V (positive terminal of the battery).
R1-R4: These resistors prevent too much current from passing through the base (labeled B) control pin of the transistor. The resistor value of 1 kilohm (1000 ohms) was chosen to provide enough current to fully turn on (saturate) the transistor. A higher resistance would waste less power, but might cause the motor to receive less power. A lower resistance would waste more power, but wouldn’t likely provide better performance for motors running on consumer batteries.
D1-D4: Diodes provide a safe path for the motor energy to be dispersed or returned to the battery when the motor is commanded to coast or stop. I notice many H-bridge circuits on the web lack these diodes. I suppose that’s safe enough for light loads at low voltages, but without diodes, a motor voltage spike can force its way through the unprotected transistors, damaging or destroying them.
M1: This is a direct-current (DC) motor. These are very common. You can find them in surplus stores online or in salvaged toys. The motor should have only two wires. Measure the resistance of the two motor wires using a multimeter. If the motor resistance is less than 5 ohms, then the transistor parts listed in this article are too weak to power the motor.

3/01/2013

Упрощённый усилитель звука на TEA2025B






Упрощённый усилитель звука на TEA2025B
Можно использовать аккумулятор от сотового (3.7в) вполне пойдёт для питания схемы.