Sorry I may have confused things a little by mentioning the future plans in terms of current display and temperature display. Please ignore that, as motor current is taken care of on different pins and all that i was suggesting is that the display will show current usage when the power is turned on and when the power is off the display reverts to a temperature display. My only concern here is reading the analogue voltage input across those two pins and getting a value from it. Chris peter green wrote: > it really depends on the level of the signals and the accuracy you need. the > no hardware way would be to read both seperately through seperate ADC > channels and subtract, if you wan't more accuracy or to save a pin on the > pic then build a differential amplifier (one op-amp and some resistors) or > an instrumentation amplifier (3 op-amps and more resistors but much higher > imput impedance). > > >> -----Original Message----- >> From: piclist-bounces@mit.edu [mailto:piclist-bounces@mit.edu]On Behalf >> Of Chris Gavin-Egan >> Sent: 24 September 2006 00:15 >> To: Microcontroller discussion list - Public. >> Subject: Re: [PIC] Relative Newbie needs assistance >> >> >> Ok guess Jpgs aren't allowed... here's a link to the jpg >> >> http://www.gavin-egan.com/thermistor.jpg >> >> The full diagrams can be found at www.sinclairc5.com >> >> Chris Gavin-Egan wrote: >> >>> My ascii drawing didn't turn out too well, here's a jpg >>> >>> >>> >>> picture of circuit to ula >>> >>> Chris Gavin-Egan wrote: >>> >>> >>>> Hi all >>>> >>>> I've been lurking for a while and I have been working on a >>>> >> hobby project >> >>>> for the past year (when i have had time) essentially learning >>>> >> whatever i >> >>>> can when I have spare time. >>>> >>>> Working on projects like this are the only way i find that i REALLY >>>> learn, however I think i am now truly stuck and quite possibly >>>> >> out of my >> >>>> depth and that is one of those thing i hate admitting. >>>> >>>> Basically I am working on producing a daughter board with a >>>> >> 16f628-A pic >> >>>> on it to replace an ageing 21 year old Ferranti ULA chip that is >>>> pre-programmed for working in an instrumentation pod of a Sinclair C5 >>>> electric car. The problems associated with this is that I am working to >>>> the constraints of the original electronics that are there. I >>>> >> understand >> >>>> what the inputs and outputs of this chip are (which helps!!!) >>>> >>>> I am going to sell these to Sinclair enthusiasts when I finish, only >>>> because when the original chip malfunctions the C5 cant be driven. I >>>> will never make a profit with them because of the time and effort taken >>>> so far but in reality that is not the reason I am working on >>>> >> them. It is >> >>>> primarily just a project that forces me to learn but also because so >>>> many people over the years have made promises that they are >>>> >> working on a >> >>>> replacement chip for it and none have ever come to anything I dont want >>>> this project to fail and I am so close. >>>> >>>> The choice of 16f628 was primarily because of the I/O count ADC and the >>>> size of the chip in comparison to the ULA which is a 28pin DIL (Giving >>>> me a little room for manoeuvring within the original chip outline) >>>> >>>> I am about 60% of the way there. My daughter board works in a basic >>>> fashion - it operates the power control to the main power relay- >>>> illuminates LED's as appropriate and and i am just now trying to get >>>> some of the other functions to work. >>>> >>>> The First problem i have is really as follows. >>>> There is a 5v supply feeding a thermistor that is as shown below which >>>> detects the temperature of the motor across a std voltage divider . >>>> >>>> >>>> 5v------- 10k ntc thermistor------------------------- ferranti dil >>>> socket input 1 >>>> | | >>>> | | >>>> | 100ohm >>>> 10nf | >>>> | | >>>> 0v-----------1k ohm------------------------------------------ferranti >>>> dil socket input 2 >>>> >>>> It has a thermistor and voltage divider on 2 pins of the chip >>>> >> and what i >> >>>> am having problems with is understanding how to get pic to accept the >>>> voltage across these two pins. >>>> >>>> The operation of the system is that when the 10k thermistor reaches >>>> around 1000 ohms (in practice this is actually 750ohm )the input across >>>> the two is about 0.3 - 0.5v and the chip sets off an audible alarm i >>>> know it probably has a simple answer but my brain is now in a rut. >>>> >>>> What I was going to do is take the analogue voltage and display that on >>>> the LED bargraph as an approximate temp display. This display is >>>> presently being utilised by the ULA as a current meter for the motor, I >>>> simply thought that this display could be utilised as a temp display >>>> whenever the motor is not being used as well as utilising the audible >>>> output that is presently there. >>>> I hope this makes some sense. >>>> >>>> Its also funny how looking at this and talking about it on email has >>>> made me come up a couple of thoughts but my head hurts. >>>> >>>> Thankyou >>>> >>>> >>>> >>>> >>>> >>>> >>>> >> -- >> http://www.piclist.com PIC/SX FAQ & list archive >> View/change your membership options at >> http://mailman.mit.edu/mailman/listinfo/piclist >> > > -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist