Hello,
im making a simple mini project to turn on the lights by using barcode scanner,computer, usb to rs232 convert, transistors, relays, and bulb
im scanning a barcodes and im processing it through software in computer and generating a logic '1' or '0' depending on the barcode, and taking a output from computer as logic '0', or logic '1' and the corresponding transistor is turned on and the relay is driven and lights the bulb but whether this logic works with transistors i dont want to use uc if it works with transistors how do i need to connect please suggest something. Sorry if any thing wents wrong up there
Please give useful informations.
We don´t know what signals are available at your "USB-to-RS232" converter. So how can we say what where to connect.
Please clarify: Are there true "RS232" or "TTL" levels?
***
The circuit neither work for RS232 levels nor for TTL levels.
***
Your circuit tries to activates either the one relay or the other relay. Then on each relay only the "NO" (not "NC") contact is used.
--> why don´t you use a signle relay but use both NO and NC contact?
Still we don´t have any information about your used module and it´s signals.
***
The lower relay driving circuit will´t work. Disconnect it.
When you connect USB_GND to RELAY_SUPPLY_GND, then the upper relay driver circuit may work with 0V/3.3V input levels.
But I recommend to lower the base resistor to about 470R.
We suppose that your USB/TTL inerface has extra pin DTR ,CTS
if true, you can use DTR or CTS Satus from "RS232" PC software , to get a stable commande "1" or "0"
impossible via TX line ,
except if you add a RC filter to get an average DC value when sending somme data :
minima is 1 byte (10 bits) with data=0xFF