Maker Pro
Maker Pro

Defeating MAX232 and MAX 233.....

J

Jan Panteltje

Well, I have this embedded system, and only 3.3V level out on serial.
Asked for a MAX233 in the shop.. needed to be ordered, was expensive...
Told them: Forget it, I will use transistors.

But the second thing, No supply should be used, not even the 3.3V

My solution? I control the terminal (Linux minicom) and the RS232 port too (outb() ).
So here it is folks:



Embedded connector

9 pol D connector --------0 >
|
c
TXD 3 -------------------------- 5k6 ------------------------ b NPN
| e
k |
Diode 1N1448 |
a |
| |
GND 5 -------------------------------------------------------------------0 GND
|
|
+12V |
DTR 4 ---------------------- |
| | |
| 5k6 |
c | |
b ------| |
e NPN | |
| | |
RXD 2 ------------| | |
| | |
e | b
b ------| ----- c e----- 3k3 --------------0 <
c | |
| PNP c | NPN
| b------|
| e NPN |
| | 3k3
- 12V | | |
RTS 7 ------------------------------


All NPN transistors BC547, all PNP transistors BC 557.



As you can see the top is classical, but the reverse path uses a common base for level shifter :)
I start minicom, hardware flow control off, and then after that a small program that sets
DTR to +12 V and RTs to -12 V, there is my supply :)

Maxim defeated :)
 
A

Andrew Holme

Jan Panteltje said:
Corrected diagram, the common base is a PNP of course :)

Nice level shifter :)

What about using MOSFETs in the output circuit to eliminate base drive?
Some RS232 ports have high source impedances, and the voltage can droop
quite a bit when you start drawing milliamps.
 
S

Spehro Pefhany

Well, I have this embedded system, and only 3.3V level out on serial.
Asked for a MAX233 in the shop.. needed to be ordered, was expensive...
Told them: Forget it, I will use transistors.

But the second thing, No supply should be used, not even the 3.3V

My solution? I control the terminal (Linux minicom) and the RS232 port too (outb() ).
So here it is folks:


I think you should have a BE resistor on the input so that touching
one's finger on the TXD line won't drive it nuts with line frequency
signals. You could use all 10K resistors.

You could also use the ST3232.


Embedded connector
9 pol D connector --------0 >
|
c
TXD 3 -------------------------- 5k6 ------------------------ b NPN
| e
k |
Diode 1N1448 |
a |
| |
GND 5 -------------------------------------------------------------------0 GND
|
|
+12V |
DTR 4 ---------------------- |
| | |
| 5k6 |
c | |
b ------| |
e NPN | |
| | |
RXD 2 ------------| | |
| | |
e | b
b ------| ----- c e----- 3k3 --------------0 <
c | |
| PNP c | PNP
| b------|
| e NPN |
| | 3k3
- 12V | | |
RTS 7 ------------------------------


All NPN transistors BC547, all PNP transistors BC 557.



As you can see the top is classical, but the reverse path uses a common base for level shifter :)
I start minicom, hardware flow control off, and then after that a small program that sets
DTR to +12 V and RTs to -12 V, there is my supply :)

Maxim defeated :)


Best regards,
Spehro Pefhany
 
J

Jan Panteltje

Nice level shifter :)

What about using MOSFETs in the output circuit to eliminate base drive?
Some RS232 ports have high source impedances, and the voltage can droop
quite a bit when you start drawing milliamps.

Yes, right, I should perhaps have kept the 5k6 higher, but I am using flashing
fast baudrates... and it was the second resistor I grabbed from the box...
Are MOSFETS more expensive then junction stuff? I bought a load
of junction PNP / NPN and they go into everything.
 
J

Jan Panteltje

I think you should have a BE resistor on the input so that touching
one's finger on the TXD line won't drive it nuts with line frequency
signals. You could use all 10K resistors.

You could also use the ST3232.

Yes, true, I looked up that data sheet, but it needs caps I think.
The MAX233 does not need caps on the charge pump I think.
Maybe just a few resistors and junction transistors is even cheaper then
a ST3232?

This one could be integrated, if only everybody had full control of DTR and
RTS.
 
J

Jamie

Jan said:
Well, I have this embedded system, and only 3.3V level out on serial.
Asked for a MAX233 in the shop.. needed to be ordered, was expensive...
Told them: Forget it, I will use transistors.

But the second thing, No supply should be used, not even the 3.3V

My solution? I control the terminal (Linux minicom) and the RS232 port too (outb() ).
So here it is folks:



Embedded connector

9 pol D connector --------0 >
|
c
TXD 3 -------------------------- 5k6 ------------------------ b NPN
| e
k |
Diode 1N1448 |
a |
| |
GND 5 -------------------------------------------------------------------0 GND
|
|
+12V |
DTR 4 ---------------------- |
| | |
| 5k6 |
c | |
b ------| |
e NPN | |
| | |
RXD 2 ------------| | |
| | |
e | b
b ------| ----- c e----- 3k3 --------------0 <
c | |
| PNP c | NPN
| b------|
| e NPN |
| | 3k3
- 12V | | |
RTS 7 ------------------------------


All NPN transistors BC547, all PNP transistors BC 557.



As you can see the top is classical, but the reverse path uses a common base for level shifter :)
I start minicom, hardware flow control off, and then after that a small program that sets
DTR to +12 V and RTs to -12 V, there is my supply :)

Maxim defeated :)
that's cheating! :)
Just hope the PC/Flap top supports the full voltages..
 
J

Jan Panteltje

The below sites have simple two transistor setups.

http://www.qsl.net/pa3ckr/bascom and avr/rs232/index.html
Yea that one is not to spec I think.
I had considered the 3.3V zener method, but that
1) pins you down to 3.3V (mine also works on 5V).
2) those zeners are less stable, more dificult to get.
3) an other capacitor.
4) the output impedance driving low (towards negative) is only 4k7 in that circuit.
5) it has 11 components, mine only 10.
6) 4 different types of resistors, in my circuit all can be 5k6 if must be.
7) less transistors, more looks good in the flyer.
8) was not designed by me, so no fun.
9) likely patented, mine is public domain now.
10) Will think of some more over time, yes, mine is already build...
:)
 
S

Si Ballenger

Yea that one is not to spec I think.

I had considered the 3.3V zener method, but that
1) pins you down to 3.3V (mine also works on 5V).
2) those zeners are less stable, more dificult to get.
3) an other capacitor.
4) the output impedance driving low (towards negative) is only 4k7 in that circuit.
5) it has 11 components, mine only 10.
6) 4 different types of resistors, in my circuit all can be 5k6 if must be.
7) less transistors, more looks good in the flyer.
8) was not designed by me, so no fun.
9) likely patented, mine is public domain now.
10) Will think of some more over time, yes, mine is already build...
:)

Are your assumptions of having power available from the DTR pin
supported by all serial programs?
 
J

Jan Panteltje

Are your assumptions of having power available from the DTR pin
supported by all serial programs?

If you re-read the thread (google?) you will find that I started out
by saying that in this case I had full control over the terminal.
That second circuit you referred to has the same issue.

Anyways it makes sense to supply system inclusive cable (that has actually
DTR and RTS wired), and software for the PC.
Won't work with a null modem cable ;-)

And it won't work in Vista... HAHHAHAHAHHAHAHAHA, I only support Linux.
LOL
 
J

Joop

I have never come around to build this, but found this years ago and
kept it in my ideas book.
Should be independent of embedded VCC level. A shunt resistor for
input static protection might be wise. This is the version with the
least amount of discrete components that I have seen.

VCC
+
|
|
.-.
| |2K2
| |
'-'
|
|------
||-+
RXD ||<-
--------||-+ BS170
|
|
===
GND


VCC
+
|
|
BS250 +-||---
<-||
+-||
TXD |
-----------|
.-.
| |2K2
| |
'-'
CTS |
 
S

Si Ballenger

If you re-read the thread (google?) you will find that I started out
by saying that in this case I had full control over the terminal.
That second circuit you referred to has the same issue.

Anyways it makes sense to supply system inclusive cable (that has actually
DTR and RTS wired), and software for the PC.
Won't work with a null modem cable ;-)

And it won't work in Vista... HAHHAHAHAHHAHAHAHA, I only support Linux.
LOL

Then I guess "Defeating MAX232 and MAX 233....." was an over
stated bit of "fantasy thinking". ;)
 
J

Jan Panteltje

I have never come around to build this, but found this years ago and
kept it in my ideas book.
Should be independent of embedded VCC level. A shunt resistor for
input static protection might be wise. This is the version with the
least amount of discrete components that I have seen.

VCC
+
|
|
.-.
| |2K2
| |
'-'
|
|------
||-+
RXD ||<-
--------||-+ BS170
|
|
===
GND


VCC
+
|
|
BS250 +-||---
<-||
+-||
TXD |
-----------|
.-.
| |2K2
| |
'-'
CTS |

Would not a BS170 die if you connected the cable and there was some charge on
it?
Maybe some zener would be needed?
 
J

Jan Panteltje

Then I guess "Defeating MAX232 and MAX 233....." was an over
stated bit of "fantasy thinking". ;)

Nope, it is working here.
Vista is an insult to computing, more hardware and power needed to to less
(because of constant encryption/decryption, why the thing eats power), and
can no longer be considered sane electronics / programming, so it is irrelevant
to computing and electronics.

In fact this circuit is working so very good I am amazed.
 
S

SioL

Jan Panteltje said:
Nope, it is working here.
Vista is an insult to computing, more hardware and power needed to to less
(because of constant encryption/decryption, why the thing eats power), and
can no longer be considered sane electronics / programming, so it is irrelevant
to computing and electronics.

Unfortunately it is far from irrelevant, but there's nothing me or you can
do about it.
In fact this circuit is working so very good I am amazed.

You sure are easily impressed.

SioL
 
J

Jan Panteltje

Unfortunately it is far from irrelevant, but there's nothing me or you can
do about it.

Well i have been programming for Linux for >10 years now, many applications,
look how MS starts to screek.
So I *did* something about it.
that proves it is possible to do somethin gabout it, start by installing Linux,
not Vista.
You sure are easily impressed.

Not by you posts.
 
S

SioL

Jan Panteltje said:
Well i have been programming for Linux for >10 years now, many applications,
look how MS starts to screek.
So I *did* something about it.
that proves it is possible to do somethin gabout it, start by installing Linux,
not Vista.

Well, Vista is still far from irrelevant so whatever you were doing those
10 years... did not work, it seems Linux is loosing the desktop war.

I appreciate the effort, though.

SioL
 
S

Si Ballenger

Nope, it is working here.
Vista is an insult to computing, more hardware and power needed to to less
(because of constant encryption/decryption, why the thing eats power), and
can no longer be considered sane electronics / programming, so it is irrelevant
to computing and electronics.

sour grapes

noun

Definition:

affected scorn: the scornful denial that something is attractive
or desirable because it is unobtainable

[In allusion to Aesop's fable The Fox and the Grapes where the
fox disparages some grapes as sour when he cannot reach them]
 
J

Jan Panteltje

sour grapes

I am familiar with teh expression.
But it does not apply to a disgraceful attempt to show the world bloat
and misuse of processor power, distrust of people, cheap go at commercial gain,
AND NO NEW FEATURES.
Not to forget forced incompatibility with everything else.

No, the label 'OS' does not apply to the Vista failure.
 
Top