Problem with input signals from darlington driver source

Flint10

New Member
I want to read an input from a darlinton driver source but I am having problems with the output of the darlington not going low enough i.e. down to approx 1 volt and not zero. This is not low enough to trigger my PICAXE - 28X2.

Is there a simple way of converting this 1 volt to 0V?

Any help would be much appreciated.
 

MFB

Senior Member
You could add a standard diode and pull down resistor at the input of the PICAXE. A Low will therefore be 0.3V and a high will be 4.3V, assuming a 5V supply.
 

premelec

Senior Member
I'll second that MFB! just a silicon diode in series with the signal should do it - or 2 diodes in series if necessary and don't forget the 10K or so resistor at the PICAXE input to keep it from floating or rectifying various RFI...
 

Flint10

New Member
Thanks guys for your prompt advice. I have implemented your mods. I thought it might be the outputs from the darlington driver but alas no.

I am trying to interpret digital signals from a midi device which uses a ULN2803A driver. The idea is that when particular notes are detected the Picaxe -28X2 then switches the relevant relays on and off, either singularly or in pairs, triples etc.

I can get it to work on single notes but the problem occurs when multiple notes are detected.

At the moment LED's on the PIC output go on when a note (event) has been read. No relays are fitted yet.

The program seems to work in principle but I have noticed that when 2 or more events are detected they do not always provide the right output condition. I have noticed that if I shorten the program and only detect certain groups of events it seems to work OK. Also , sometimes an outpput LED may light up fleetingly suggesting that the event has been read but the event doesn't latch even though the code say's high B.1( fot instance) .

I initially thought that the PIC speed was the problem so I have fitted a 10Mhz resonator allowing to to run at 40Mhz.

I have tried to follow the manual regarding interrupt routines and think I understand it. I must admit though I do find the hintsetup and setintflags a bit of an headache to understand.

However, I have dioded an hardware interrupt on INT0 to check when any (upto 5) inputs are triggered then gosub to the interrupt routine to read pinsC condition into a variable b2. This is then used in the relevant subroutine to latch the appropraite outputs.

To help you understand the relvant interrupt code is as follows:-

init:

setfreq em40
input B.0 ; INT0 to check for any input event
output A.0 ; set A.0 as output pin
hintsetup %00000001 ; setup hardware interrupt on B.0
setintflags %00000001, %00000001 ; set hardware Int0 to interrupt
let dirsB = %11111110
let dirsA = %000000001

goto mainloop


interrupt: ;check to see if any input is selected
b2 = pinsC ;read pinsC and put in varialbe b2
hint0flag = 0
hintsetup %00000001
setintflags %00000001, %00000001 ; reset hintflags
return

Is it correct or have I missed the point somewhere?

Sorry for the long post, but this problem is really streching my patience..... Any advice/suggestions would be most appreciated.

Cheers,

Alan
 
Top