[Arm-netbook] help needed with a ttl logic circuit

Luke Kenneth Casson Leighton lkcl at lkcl.net
Tue Aug 25 01:45:40 BST 2015


On Tue, Aug 25, 2015 at 12:31 AM, Daniel Serpell
<daniel.serpell at gmail.com> wrote:
> Hi!
>
> On Sat, Aug 22, 2015 at 2:21 PM, Luke Kenneth Casson Leighton
> <lkcl at lkcl.net> wrote:
>> hi folks could someone please help analyse this circuit to see if it is correct?
>>
>> http://hands.com/~lkcl/ttl_logic_circuit.png
>>
>> the requirement:
>>
>> * an STM32F's "BOOT0" is, by default "pulled to GND" in order that
>> "normal" operation happens
>>
>> * the boot operation needs to be selectable by a GPIO from a main CPU
>> (TTL, with a different voltage)
>>
>> * if however the main CPU's GPIO is *DISCONNECTED*, "normal" operation
>> of the STM32F is required.
>>
>> so, the main things here are:
>>
>> * the STM32F is run from a 3.3v supply
>>
>> * the CPU can be a totally different TTL voltage level from the
>> STM32F.  it could be 5.0V, it could be 3.3v, it could be 3.0v, it
>> could be even 1.8v.
>>
>> * the default behaviour needs to be "pull to GND", even if the input
>> is floating.
>>
>
> A little late to the discussion, but I would use something like:
>   https://github.com/sparkfun/Logic_Level_Bidirectional
>
> The schematic is here:
>   https://cdn.sparkfun.com/datasheets/BreakoutBoards/Logic_Level_Bidirectional.pdf
>
> To assure that the output is low when the LV input is disconnected,
> you could add a
> resistance from the input to ground, I would use a 2k resistor, so
> that at 1.8V the
> gate has 1.5V, setting a low state in the output.
>
> This circuit is cheap, and you would use only 3 resistors and one FET.

 ta daniel, yes i saw this circuit around in the exploration i've been doing.

 the only problem i have with it is this:

 when the input is at 0V, i assume that means that the other side of
the MOSFET also goes to 0V (plus a little bit - say 0.1V).

 however if the input were to go to, say.... 0.6V (because that's
within TTL levels), then the output would *also* go to 0.6V, plus a
little bit, that's 0.7v.

 .... and it's *way* over the acceptable threshold for BOOT0, which is
a full 0.3 volts *lower* than CMOS.  in this case (with a 3.3v supply)
it's 3.3 * 0.3 - 0.3 which is 0.69v...

 that's *barely* within tolerance.

 so i feel that some additional transistor or other components are
needed when using the MOSFET in order to make sure that the input is
definitely definitely pulled right down.

 i may be wrong here, please do tell me if i am.

 ralf wrote:

> You don't need the high beta of the combined transistors,

i'm not sure what high beta is, but the output definitely needs to go
below 0.69 volts in order to trigger BOOT0 ROM mode.  would the
suggested circuit (with the silicon diode) do that?

 thanks all,

l.



More information about the arm-netbook mailing list