ms can to analog coolant temp gauge.

A forum for discussing the MegaSquirt related (but non-B&G) board development, assembly, installation, and testing.

Moderators: jsmcortina, muythaibxr

ms can to analog coolant temp gauge.

Postby Vauxi » Sat Mar 18, 2017 11:59 am

Hello.
I'm totally noob to the whole arduino and micro controller stuff. I've read a lot of posts in different forums about arduinos and I'm confused a lot :D What I have been planning is to use original instrument panel without modifying it at all. Idea is to replace original coolant temp gauge ptc resistor with can based pwm transistor control. This should be possible? What do I need? Looks like Teensy 3.2 is where to go? Do I need some chip to decode can signals too? Or is just basic bus terminator resistor enough? This whole idea may èxpand to the speedo too. But we'll see.. And if teensy is okay to go. Is just basic npn transistor coupling enough for job?
Vauxi
Helpful MS/Extra'er
 
Posts: 48
Joined: Sun Feb 19, 2017 9:06 am

Re: ms can to analog coolant temp gauge.

Postby Vauxi » Wed Aug 23, 2017 3:59 am

I've been struggling to get any can signal to the teensy board. I have two different can transreceiver and both of them doesn't react to the signal what ms2 v3 is sending out. So I figure that I should scope it. This is what I found

Image

Signal base voltage is 1.5V. Both swing voltages are around 1V. Are these correct ? I measured from open jimstim pins. Transreceivers are based to mcp2551 and SN65HVD230. I assume that these ready to connect transreceiver boards has correct pinouts. What could possibly be wrong ?

I use teensy 3.2 as arduino.
Vauxi
Helpful MS/Extra'er
 
Posts: 48
Joined: Sun Feb 19, 2017 9:06 am

Re: ms can to analog coolant temp gauge.

Postby jsmcortina » Wed Aug 23, 2017 4:54 am

Is your baud rate set correctly ?

James
I can supply, repair or upgrade Megasquirts in UK. http://www.jamesmurrayengineering.co.uk

My Success story: viewtopic.php?f=104&t=34277
MSEXTRA documentation at: http://www.msextra.com/doc/index.html
jsmcortina
Site Admin
 
Posts: 33991
Joined: Mon May 03, 2004 1:34 am
Location: Birmingham, UK

Re: ms can to analog coolant temp gauge.

Postby Vauxi » Wed Aug 23, 2017 5:17 am

Do you mean at transreceiver boards or at teensy ? At teensy, propably yes. But there is no signal coming in. I dunno about these transreceivers.
http://www.ebay.co.uk/itm/1PCS-SN65HVD230-CAN-bus-transceiver-communication-module-For-arduino-/191754615615?epid=1888865950&hash=item2ca5773b3f:g:G~kAAOSw7FRWZSvA One is like this.
Vauxi
Helpful MS/Extra'er
 
Posts: 48
Joined: Sun Feb 19, 2017 9:06 am

Re: ms can to analog coolant temp gauge.

Postby Matt Cramer » Wed Aug 23, 2017 6:40 am

I don't have experience programming the CAN protocol side of things, but I can confirm that it's possible to run some analog gauges off a PWM output. I did that for my '72 Chevy truck when I swapped in an LSx motor, which didn't have a separate coolant temperature sensor for the gauge.
Matt Cramer
Super MS/Extra'er
 
Posts: 13743
Joined: Thu Apr 16, 2009 8:08 pm

Re: ms can to analog coolant temp gauge.

Postby Raymond_B » Wed Aug 23, 2017 7:45 am

Have you looked at this thread?

viewtopic.php?f=123&t=61723
1995 Ford Lightning. Dart based 427 Windsor, Novi 2000, full sequential, E-85, etc. MS3/3X
Friends don't let friends share tunes...
http://www.buildpics.org/
Raymond_B
Master MS/Extra'er
 
Posts: 583
Joined: Thu Mar 06, 2014 2:17 pm
Location: Texas

Re: ms can to analog coolant temp gauge.

Postby Vauxi » Wed Aug 23, 2017 8:42 am

Yes I have. I've been swapping cables etc so many times. I don't know how I can or do I need to change transreceiver mode/state. Have to look on that.
Vauxi
Helpful MS/Extra'er
 
Posts: 48
Joined: Sun Feb 19, 2017 9:06 am

Re: ms can to analog coolant temp gauge.

Postby Raymond_B » Wed Aug 23, 2017 8:47 am

Use the Teensy's serial monitor to see if you are getting data.

Bust basically, and you probably know this, it needs to be set up like this.

Megasquirt ---------> CAN transceiver ----------> Teensy

Lastly, the MS2 you are using is set up for CAN right? And you have CAN broadcasting turned on?
1995 Ford Lightning. Dart based 427 Windsor, Novi 2000, full sequential, E-85, etc. MS3/3X
Friends don't let friends share tunes...
http://www.buildpics.org/
Raymond_B
Master MS/Extra'er
 
Posts: 583
Joined: Thu Mar 06, 2014 2:17 pm
Location: Texas

Re: ms can to analog coolant temp gauge.

Postby Vauxi » Wed Aug 23, 2017 10:16 am

Basic connection is known. Serial monitor doesn't display anything. Scoped the serial tx and rx lines to the teensy and there is no data going on. I have turned on the dash broadcast. That signal is shown in the image above.
Vauxi
Helpful MS/Extra'er
 
Posts: 48
Joined: Sun Feb 19, 2017 9:06 am

Re: ms can to analog coolant temp gauge.

Postby seishuku » Wed Aug 23, 2017 10:24 am

You won't see anything on the RX/TX lines unless the proper dominate bit on the tx line is set (IIRC).
Is RX connected to RX and TX connect to TX?

The MCP transceiver is 5v, while the HVD230 is 3.3v, so just keep that in mind.

Also, is it just the teensy and MS in the bus? Is there a termination resistor in place?
seishuku
Experienced MS/Extra'er
 
Posts: 208
Joined: Tue Dec 01, 2009 5:38 pm
Location: Wisconsin, USA

Re: ms can to analog coolant temp gauge.

Postby Vauxi » Thu Aug 24, 2017 8:17 am

Now I have some signal leaving from transreceiver. I dunno, it might be all this time a partially broken ground line. As I'm using only jumper leads. No breadboard here, yet. I've tried about any scketch I could find all from techdrop to the raymonds whole code. All of them shows in serial monitor either hello text or nothing at all. This time wires are tx-tx and rx-rx. Yep 5V is needed to MCP. MCP is now sending 5V squarewave signal to the Teensy and propably having something back because there is signal on rx line too. There was only one terminator so 120ohms were between can lines. It is a bit tricky to install another one when not using breadboard.

From Raymonds code, I removed // of three lines from serial print section and now I have welcome text at serialmonitor. I should have displayed much more than that?

I'm so noob at this. Try to bear with me :D

CAN Dash output is 50Hz. CAN baud in teensy code is 500k.
Vauxi
Helpful MS/Extra'er
 
Posts: 48
Joined: Sun Feb 19, 2017 9:06 am

Re: ms can to analog coolant temp gauge.

Postby Raymond_B » Thu Aug 24, 2017 10:19 am

Vauxi wrote:Now I have some signal leaving from transreceiver. I dunno, it might be all this time a partially broken ground line. As I'm using only jumper leads. No breadboard here, yet. I've tried about any scketch I could find all from techdrop to the raymonds whole code. All of them shows in serial monitor either hello text or nothing at all. This time wires are tx-tx and rx-rx. Yep 5V is needed to MCP. MCP is now sending 5V squarewave signal to the Teensy and propably having something back because there is signal on rx line too. There was only one terminator so 120ohms were between can lines. It is a bit tricky to install another one when not using breadboard.

From Raymonds code, I removed // of three lines from serial print section and now I have welcome text at serialmonitor. I should have displayed much more than that?

I'm so noob at this. Try to bear with me :D

CAN Dash output is 50Hz. CAN baud in teensy code is 500k.


Have you been able to do basic tests with the Teensy? Like the LED program? Have you ensured that is all working correctly
1995 Ford Lightning. Dart based 427 Windsor, Novi 2000, full sequential, E-85, etc. MS3/3X
Friends don't let friends share tunes...
http://www.buildpics.org/
Raymond_B
Master MS/Extra'er
 
Posts: 583
Joined: Thu Mar 06, 2014 2:17 pm
Location: Texas

Re: ms can to analog coolant temp gauge.

Postby Vauxi » Thu Aug 24, 2017 11:06 am

Yes. I managed to spin dc motor with the most basic pwm control code thorough dc motor controller and I got GPS signal to the serial monitor with example kitchen sink sketch. And of course I got the led turned on as first code ever. 8) So far CAN has been hair grayer difficult to handle.
Vauxi
Helpful MS/Extra'er
 
Posts: 48
Joined: Sun Feb 19, 2017 9:06 am

Re: ms can to analog coolant temp gauge.

Postby Raymond_B » Thu Aug 24, 2017 4:29 pm

Can you post some pictures of how you have it wired? Also the transceiver has the termination resistor set right?

Oh wait, also the Transceiver needs to be tx-rx and rx-tx to the Teensy
1995 Ford Lightning. Dart based 427 Windsor, Novi 2000, full sequential, E-85, etc. MS3/3X
Friends don't let friends share tunes...
http://www.buildpics.org/
Raymond_B
Master MS/Extra'er
 
Posts: 583
Joined: Thu Mar 06, 2014 2:17 pm
Location: Texas

Re: ms can to analog coolant temp gauge.

Postby racingmini_mtl » Thu Aug 24, 2017 5:52 pm

Raymond_B wrote:Oh wait, also the Transceiver needs to be tx-rx and rx-tx to the Teensy

No. It's Tx to Tx and Rx to Rx from Teensy to transceiver.

Jean
jbperf.com Main site . . . . . . . . . . . . . . . . . . . . . . jbperf.com Forum
Image
racingmini_mtl
Super MS/Extra'er
 
Posts: 8013
Joined: Sun May 02, 2004 6:51 am
Location: Quebec, Canada

Re: ms can to analog coolant temp gauge.

Postby Raymond_B » Thu Aug 24, 2017 6:05 pm

racingmini_mtl wrote:
Raymond_B wrote:Oh wait, also the Transceiver needs to be tx-rx and rx-tx to the Teensy

No. It's Tx to Tx and Rx to Rx from Teensy to transceiver.

Jean


That's what I get for doing this and then not touching it for a while. I'll go with "I was thinking about the Nextion serial connection", yeah that's it :)
1995 Ford Lightning. Dart based 427 Windsor, Novi 2000, full sequential, E-85, etc. MS3/3X
Friends don't let friends share tunes...
http://www.buildpics.org/
Raymond_B
Master MS/Extra'er
 
Posts: 583
Joined: Thu Mar 06, 2014 2:17 pm
Location: Texas

Re: ms can to analog coolant temp gauge.

Postby Vauxi » Thu Aug 24, 2017 11:28 pm

Image

I just couldn't show real image of the most sketchier wiring of all time. :D Unless you really want. :lol:
Ms2 has correct terminator value of 120ohm. I think that transreceiver is meant to steal signals of working can system? Thats why it has very high resistor value in it? Otherwise low values may affect the signals? Now as writing this I do have 60 ohms measured resistance between can h and l. Now there is noting else but steady 5 volts on the RX line and 0-5V signal on TX line at Teensy. Serial monitor welcomes me only with Hello Megasquirt text with Raymonds code. I just dont get it.
Vauxi
Helpful MS/Extra'er
 
Posts: 48
Joined: Sun Feb 19, 2017 9:06 am

Re: ms can to analog coolant temp gauge.

Postby Vauxi » Sat Aug 26, 2017 11:57 pm

What if can inputs are broken at teensy ? How I alter the code to use any other serial input? If I remember correct, some older can libraries used somekind other way to open/use ports?
Vauxi
Helpful MS/Extra'er
 
Posts: 48
Joined: Sun Feb 19, 2017 9:06 am

Re: ms can to analog coolant temp gauge.

Postby Vauxi » Mon Oct 16, 2017 8:59 am

I had a change to test jimstim and ecu that the can is working fully at their end. So the failure lies at teensy's end. :/ Well. Atleast this is ruled out now.
Vauxi
Helpful MS/Extra'er
 
Posts: 48
Joined: Sun Feb 19, 2017 9:06 am

Re: ms can to analog coolant temp gauge.

Postby Vauxi » Wed Oct 18, 2017 9:12 am

Ordered a new can transmitter. My two other has been broken from the beginning..
Vauxi
Helpful MS/Extra'er
 
Posts: 48
Joined: Sun Feb 19, 2017 9:06 am


Return to Expansion boards

Who is online

Users browsing this forum: No registered users and 2 guests