* SPICE netlist
R1 N013 N020 1R
R2 N011 N020 0.1R
R3 N009 N020 0.01R
R4 N013 N008 3K3
R5 N011 N008 3K3
R6 N009 N008 3K3
R7 N008 N001 158K
R8 N020 N014 1K1
R9 N014 I_MON 158K
V1 Vcc 0 5
V2 0 Vee 5
D1 N002 N020 MBRB2545CT
Iload 0 N002 PWL(10m 0 20m 50m 30m 500m 40m 5A)
R10 N020 0 0.02R
R11 Vcc CURR_5A 1k
R12 Vcc CURR_500MA 1k
R13 Vcc N003 1k
R14 N018 N020 1K
R15 N019 N018 249K
R16 N022 N019 10k
R17 N031 N019 10k
D2 N016 N022 1N4148
R18 N017 N016 1k
R19 N032 N030 100R
R22 N025 N026 100R
R25 N012 N024 2k2
R26 N010 N017 2k2
Q1 0 N010 CURR_5A 0 BC556B
Q2 0 N012 CURR_500MA 0 BC556B
R20 N028 N025 10k
C1 N024 N028 10n
R21 N033 N032 10K
C2 N017 N033 10n
VGCOM N001 0 0.05
VI_SET N007 0 0.2
R32 I_LIM N005 10k
R33 N005 N004 11k
C3 N004 N006 1n
D3 N006 N005 1N4148
D4 I_CTRL N006 1N4148
R35 Vcc I_CTRL 5k
D5 N003 CURR_50MA 1N4148
R38 N026 N027 1k
R39 N029 Vref 10k
R40 N030 N029 10k
R41 N027 Vref 10k
R42 N023 0 1K
R43 0 N023 249K
M5 CURR_50MA CURR_500MA 0 0 2N7002
M4 CURR_50MA CURR_5A 0 0 2N7002
XU14 N007 N005 Vcc Vee N006 MC33274/MC ;pnba In+)In-)V+)V-)OUT
XU5 N008 N014 Vcc Vee I_MON MC33274/MC ;pnba In+)In-)V+)V-)OUT
XU1 0 N029 Vcc Vee N030 MC33274/MC ;pnba In+)In-)V+)V-)OUT
XU10 N032 N031 Vcc Vee N017 MC33274/MC ;pnba In+)In-)V+)V-)OUT
XU2 N025 N022 Vcc Vee N024 MC33274/MC ;pnba In+)In-)V+)V-)OUT
XU3 N023 N018 Vcc Vee N019 MC33274/MC ;pnba In+)In-)V+)V-)OUT
XU4 0 N027 Vcc Vee N026 MC33274/MC ;pnba In+)In-)V+)V-)OUT
C5 N019 N018 0
R44 N028 N024 1Meg
R45 N033 N017 1Meg
M1 N002 CURR_500MA N011 N011 IRLHM620
M2 N002 CURR_50MA N013 N013 IRLHM620
M3 N002 CURR_5A N009 N009 IRLHM620
Vref Vref 0 2.5
R29 0 N015 1K
R30 N015 I_LIM 24K
R31 N021 N001 24K
R34 N020 N021 1K
XU7 N021 N015 Vcc Vee I_LIM MC33274/MC ;pnba In+)In-)V+)V-)OUT
.tran 60m
.inc motoramp.lib

* LTspice schematic (.asc)
Version 4
SHEET 1 2672 1648
WIRE 728 -824 -1224 -824
WIRE 760 -792 -1224 -792
WIRE 792 -760 -1224 -760
WIRE 552 -664 552 -696
WIRE 552 -664 456 -664
WIRE 648 -664 552 -664
WIRE -1080 -600 -1176 -600
WIRE -760 -600 -952 -600
WIRE 88 -600 -72 -600
WIRE 200 -600 88 -600
WIRE 312 -600 200 -600
WIRE 392 -600 312 -600
WIRE 456 -600 456 -664
WIRE 552 -600 552 -664
WIRE -1176 -584 -1176 -600
WIRE -952 -584 -952 -600
WIRE 312 -568 312 -600
WIRE 648 -568 648 -584
WIRE -72 -520 -72 -600
WIRE 456 -488 456 -520
WIRE 456 -488 360 -488
WIRE 728 -488 728 -824
WIRE 728 -488 456 -488
WIRE 1256 -488 728 -488
WIRE -1176 -472 -1176 -504
WIRE -952 -472 -952 -504
WIRE 200 -440 200 -600
WIRE -72 -392 -72 -440
WIRE -1288 -376 -1288 -408
WIRE -1064 -376 -1096 -376
WIRE -952 -376 -984 -376
WIRE 552 -360 552 -520
WIRE 552 -360 248 -360
WIRE 760 -360 760 -792
WIRE 760 -360 552 -360
WIRE 1144 -360 760 -360
WIRE 88 -312 88 -600
WIRE -1160 -296 -1160 -376
WIRE -1096 -296 -1160 -296
WIRE -952 -296 -952 -376
WIRE -952 -296 -1032 -296
WIRE -936 -296 -952 -296
WIRE -808 -296 -856 -296
WIRE -760 -296 -760 -600
WIRE -248 -296 -760 -296
WIRE 648 -232 648 -504
WIRE 648 -232 136 -232
WIRE 680 -232 648 -232
WIRE 792 -232 792 -760
WIRE 792 -232 680 -232
WIRE -952 -216 -952 -296
WIRE -952 -216 -984 -216
WIRE -1288 -200 -1288 -296
WIRE -1288 -200 -1336 -200
WIRE -1272 -200 -1288 -200
WIRE -1160 -200 -1160 -296
WIRE -1160 -200 -1208 -200
WIRE -1048 -200 -1160 -200
WIRE -952 -184 -984 -184
WIRE 1144 -168 1144 -360
WIRE 1256 -168 1256 -488
WIRE 648 -152 648 -232
WIRE -8 -136 -56 -136
WIRE 312 -136 312 -472
WIRE 312 -136 72 -136
WIRE 1336 -120 1320 -120
WIRE -280 -88 -1336 -88
WIRE 552 -72 552 -360
WIRE 600 -72 552 -72
WIRE 1144 -56 1144 -72
WIRE 1256 -56 1256 -72
WIRE -248 -40 -248 -296
WIRE -200 -40 -248 -40
WIRE -56 -40 -56 -136
WIRE -56 -40 -120 -40
WIRE -8 -40 -56 -40
WIRE 200 -40 200 -344
WIRE 200 -40 72 -40
WIRE 648 -40 648 -56
WIRE 1208 -24 1208 -120
WIRE 1336 -24 1336 -120
WIRE -952 -8 -952 -184
WIRE 680 8 680 -232
WIRE -56 72 -56 -40
WIRE -56 72 -120 72
WIRE -8 72 -56 72
WIRE 88 72 88 -216
WIRE 88 72 72 72
WIRE 392 72 392 -600
WIRE -280 88 -280 -88
WIRE -184 88 -280 88
WIRE 456 88 456 -488
WIRE 632 88 456 88
WIRE -952 104 -952 72
WIRE -56 104 -120 104
WIRE 680 120 680 104
WIRE -1256 136 -1256 104
WIRE -1192 136 -1256 136
WIRE -1128 136 -1128 104
WIRE -1128 136 -1192 136
WIRE -568 136 -616 136
WIRE -536 136 -568 136
WIRE -344 136 -456 136
WIRE 88 136 88 72
WIRE 200 136 200 -40
WIRE 312 136 312 -136
WIRE -1192 152 -1192 136
WIRE 1080 152 1032 152
WIRE 1336 152 1336 56
WIRE 1336 152 1160 152
WIRE 1032 168 1032 152
WIRE 696 184 680 184
WIRE 872 184 760 184
WIRE 680 232 680 184
WIRE 760 232 680 232
WIRE 872 232 872 184
WIRE 872 232 840 232
WIRE -568 248 -568 136
WIRE -568 248 -600 248
WIRE -280 248 -280 88
WIRE -168 248 -280 248
WIRE -56 248 -56 104
WIRE -56 248 -88 248
WIRE -8 248 -56 248
WIRE 88 248 88 216
WIRE 88 248 72 248
WIRE 200 248 200 216
WIRE 200 248 88 248
WIRE 312 248 312 216
WIRE 312 248 200 248
WIRE 392 248 392 136
WIRE 392 248 312 248
WIRE -808 264 -808 -296
WIRE -808 264 -872 264
WIRE -696 264 -696 136
WIRE -696 264 -808 264
WIRE -664 264 -696 264
WIRE -568 280 -600 280
WIRE 88 280 88 248
WIRE 88 280 -56 280
WIRE 312 280 88 280
WIRE 88 296 88 280
WIRE -344 344 -344 136
WIRE 8 344 -344 344
WIRE 312 344 312 280
WIRE 488 344 312 344
WIRE 680 344 680 232
WIRE 680 344 568 344
WIRE 744 344 680 344
WIRE 872 360 872 232
WIRE 872 360 808 360
WIRE 920 360 872 360
WIRE 1032 360 1032 232
WIRE 1032 360 1000 360
WIRE 1080 360 1032 360
WIRE 744 376 680 376
WIRE 1208 376 1208 56
WIRE 1208 376 1144 376
WIRE 1272 376 1208 376
WIRE -760 392 -760 -296
WIRE -696 392 -760 392
WIRE -568 392 -568 280
WIRE -568 392 -616 392
WIRE -536 392 -568 392
WIRE -56 392 -56 280
WIRE -56 392 -456 392
WIRE 8 392 8 344
WIRE 88 392 88 376
WIRE 88 392 8 392
WIRE 152 392 88 392
WIRE 248 392 232 392
WIRE 680 392 680 376
WIRE 680 392 248 392
WIRE 1080 392 1032 392
WIRE 1208 408 1208 376
WIRE 1272 408 1272 376
WIRE 88 424 88 392
WIRE 920 456 904 456
WIRE 1032 456 1032 392
WIRE 1032 456 1000 456
WIRE 360 472 312 472
WIRE 376 472 360 472
WIRE 488 472 456 472
WIRE 616 472 488 472
WIRE 824 472 696 472
WIRE 904 472 904 456
WIRE 904 472 824 472
WIRE 248 488 248 392
WIRE 1032 504 1032 456
WIRE 1048 504 1032 504
WIRE 1208 504 1208 472
WIRE 1208 504 1128 504
WIRE 1272 504 1272 488
WIRE 1272 504 1208 504
WIRE 488 536 488 472
WIRE 520 536 488 536
WIRE 824 552 824 472
WIRE 824 552 584 552
WIRE 520 568 472 568
WIRE 248 584 248 568
WIRE 472 584 472 568
WIRE 360 680 360 472
WIRE 376 680 360 680
WIRE 488 680 456 680
WIRE 616 680 488 680
WIRE 728 680 696 680
WIRE 872 696 872 360
WIRE 920 696 872 696
WIRE 1080 696 1000 696
WIRE 1208 712 1144 712
WIRE 1272 712 1208 712
WIRE 1336 712 1336 152
WIRE 1336 712 1272 712
WIRE 1080 728 1032 728
WIRE 1272 728 1272 712
WIRE 488 760 488 680
WIRE 520 760 488 760
WIRE 1208 760 1208 712
WIRE 728 776 728 680
WIRE 728 776 584 776
WIRE 920 776 728 776
WIRE 1032 776 1032 728
WIRE 1032 776 1000 776
WIRE 520 792 472 792
WIRE 472 808 472 792
WIRE 1032 824 1032 776
WIRE 1048 824 1032 824
WIRE 1208 824 1128 824
WIRE 1272 824 1272 808
WIRE 1272 824 1208 824
FLAG -1192 152 0
FLAG -1256 24 Vcc
FLAG -152 120 Vcc
FLAG -1128 24 Vee
FLAG -152 56 Vee
FLAG -72 -392 0
FLAG 88 424 0
FLAG 648 -40 0
FLAG 680 120 0
FLAG 552 -696 Vcc
FLAG 776 328 Vcc
FLAG 776 392 Vee
FLAG 1112 344 Vcc
FLAG 1112 408 Vee
FLAG 1112 680 Vcc
FLAG 1112 744 Vee
FLAG 1256 -56 0
FLAG 1144 -56 0
FLAG -952 -472 0
FLAG -1016 -232 Vcc
FLAG -1016 -168 Vee
FLAG -952 104 0
FLAG -1288 -408 Vcc
FLAG -1336 -200 I_CTRL
FLAG -1336 -88 I_MON
FLAG -1224 -824 CURR_5A
FLAG -1224 -792 CURR_500MA
FLAG -1224 -760 CURR_50MA
FLAG 552 520 Vcc
FLAG 552 584 Vee
FLAG 552 744 Vcc
FLAG 552 808 Vee
FLAG 472 808 0
FLAG 472 584 0
FLAG 312 472 Vref
FLAG 248 584 0
FLAG -1176 -472 0
FLAG -1080 -600 Vref
FLAG -632 232 Vcc
FLAG -632 296 Vee
FLAG -872 264 I_LIM
SYMBOL res 72 120 R0
SYMATTR InstName R1
SYMATTR Value 1R
SYMBOL res 184 120 R0
SYMATTR InstName R2
SYMATTR Value 0.1R
SYMBOL res 296 120 R0
SYMATTR InstName R3
SYMATTR Value 0.01R
SYMBOL res 88 56 R90
SYMATTR InstName R4
SYMATTR Value 3K3
SYMBOL res 88 -56 R90
SYMATTR InstName R5
SYMATTR Value 3K3
SYMBOL res 88 -152 R90
SYMATTR InstName R6
SYMATTR Value 3K3
SYMBOL res -104 -56 R90
SYMATTR InstName R7
SYMATTR Value 158K
SYMBOL res 88 232 R90
SYMATTR InstName R8
SYMATTR Value 1K1
SYMBOL res -72 232 R90
SYMATTR InstName R9
SYMATTR Value 158K
SYMBOL voltage -1256 8 R0
SYMATTR InstName V1
SYMATTR Value 5
SYMBOL voltage -1128 120 R180
SYMATTR InstName V2
SYMATTR Value 5
SYMBOL schottky 376 72 R0
SYMATTR InstName D1
SYMATTR Value MBRB2545CT
SYMBOL current -72 -440 R180
SYMATTR InstName Iload
SYMATTR Value PWL(10m 0 20m 50m 30m 500m 40m 5A)
SYMBOL res 72 280 R0
SYMATTR InstName R10
SYMATTR Value 0.02R
SYMBOL res 440 -616 R0
SYMATTR InstName R11
SYMATTR Value 1k
SYMBOL res 536 -616 R0
SYMATTR InstName R12
SYMATTR Value 1k
SYMBOL res 632 -680 R0
SYMATTR InstName R13
SYMATTR Value 1k
SYMBOL res 584 328 R90
SYMATTR InstName R14
SYMATTR Value 1K
SYMBOL res 856 216 R90
SYMATTR InstName R15
SYMATTR Value 249K
SYMBOL res 1016 344 R90
SYMATTR InstName R16
SYMATTR Value 10k
SYMBOL res 1016 680 R90
SYMATTR InstName R17
SYMATTR Value 10k
SYMBOL diode 1016 168 R0
SYMATTR InstName D2
SYMATTR Value 1N4148
SYMBOL res 1176 136 R90
SYMATTR InstName R18
SYMATTR Value 1k
SYMBOL res 1016 760 R90
SYMATTR InstName R19
SYMATTR Value 100R
SYMBOL res 1016 440 R90
SYMATTR InstName R22
SYMATTR Value 100R
SYMBOL res 1192 -40 R0
SYMATTR InstName R25
SYMATTR Value 2k2
SYMBOL res 1320 -40 R0
SYMATTR InstName R26
SYMATTR Value 2k2
SYMBOL pnp 1320 -72 R180
SYMATTR InstName Q1
SYMATTR Value BC556B
SYMBOL pnp 1208 -72 R180
SYMATTR InstName Q2
SYMATTR Value BC556B
SYMBOL res 1144 488 R90
SYMATTR InstName R20
SYMATTR Value 10k
SYMBOL cap 1192 408 R0
SYMATTR InstName C1
SYMATTR Value 10n
SYMBOL res 1144 808 R90
SYMATTR InstName R21
SYMATTR Value 10K
SYMBOL cap 1192 760 R0
SYMATTR InstName C2
SYMATTR Value 10n
SYMBOL voltage -952 -600 R0
SYMATTR InstName GCOM
SYMATTR Value 0.05
SYMBOL voltage -952 -24 R0
SYMATTR InstName I_SET
SYMATTR Value 0.2
SYMBOL res -840 -312 R90
SYMATTR InstName R32
SYMATTR Value 10k
SYMBOL res -968 -392 R90
SYMATTR InstName R33
SYMATTR Value 11k
SYMBOL cap -1096 -392 R90
SYMATTR InstName C3
SYMATTR Value 1n
SYMBOL diode -1096 -280 R270
SYMATTR InstName D3
SYMATTR Value 1N4148
SYMBOL diode -1272 -184 R270
SYMATTR InstName D4
SYMATTR Value 1N4148
SYMBOL res -1304 -392 R0
SYMATTR InstName R35
SYMATTR Value 5k
SYMBOL diode 632 -568 R0
SYMATTR InstName D5
SYMATTR Value 1N4148
SYMBOL res 712 456 R90
SYMATTR InstName R38
SYMATTR Value 1k
SYMBOL res 472 664 R90
SYMATTR InstName R39
SYMATTR Value 10k
SYMBOL res 712 664 R90
SYMATTR InstName R40
SYMATTR Value 10k
SYMBOL res 472 456 R90
SYMATTR InstName R41
SYMATTR Value 10k
SYMBOL res 248 376 R90
SYMATTR InstName R42
SYMATTR Value 1K
SYMBOL res 264 584 R180
SYMATTR InstName R43
SYMATTR Value 249K
SYMBOL nmos 600 -152 R0
SYMATTR InstName M5
SYMATTR Value 2N7002
SYMBOL nmos 632 8 R0
SYMATTR InstName M4
SYMATTR Value 2N7002
SYMBOL Opamps\\opamp2 -1016 -264 M0
SYMATTR Value MC33274/MC
SYMATTR InstName U14
SYMBOL Opamps\\opamp2 -152 152 R180
SYMATTR Value MC33274/MC
SYMATTR InstName U5
SYMBOL Opamps\\opamp2 552 712 R0
SYMATTR Value MC33274/MC
SYMATTR InstName U1
SYMBOL Opamps\\opamp2 1112 648 R0
SYMATTR Value MC33274/MC
SYMATTR InstName U10
SYMBOL Opamps\\opamp2 1112 312 R0
SYMATTR Value MC33274/MC
SYMATTR InstName U2
SYMBOL Opamps\\opamp2 776 296 R0
SYMATTR Value MC33274/MC
SYMATTR InstName U3
SYMBOL Opamps\\opamp2 552 488 R0
SYMATTR Value MC33274/MC
SYMATTR InstName U4
SYMBOL cap 760 168 R90
SYMATTR InstName C5
SYMATTR Value 0
SYMBOL res 1256 504 M180
SYMATTR InstName R44
SYMATTR Value 1Meg
SYMBOL res 1256 824 M180
SYMATTR InstName R45
SYMATTR Value 1Meg
SYMBOL nmos 248 -440 M0
SYMATTR InstName M1
SYMATTR Value IRLHM620
SYMBOL nmos 136 -312 M0
SYMATTR InstName M2
SYMATTR Value IRLHM620
SYMBOL nmos 360 -568 M0
SYMATTR InstName M3
SYMATTR Value IRLHM620
SYMBOL voltage -1176 -600 R0
SYMATTR InstName Vref
SYMATTR Value 2.5
SYMBOL res -440 120 R90
SYMATTR InstName R29
SYMATTR Value 1K
SYMBOL res -600 120 R90
SYMATTR InstName R30
SYMATTR Value 24K
SYMBOL res -600 376 R90
SYMATTR InstName R31
SYMATTR Value 24K
SYMBOL res -440 376 R90
SYMATTR InstName R34
SYMATTR Value 1K
SYMBOL Opamps\\opamp2 -632 200 M0
SYMATTR Value MC33274/MC
SYMATTR InstName U7