Author Topic: MATLAB Vehicle Network Tool Box to Read CAN messages  (Read 15734 times)

santosh1802

  • Guest
MATLAB Vehicle Network Tool Box to Read CAN messages
« on: January 27, 2011, 06:06:50 PM »
Has any one tried using Vehicle Network Tool (VNT)  Box of MATLAB to read CAN messages?. I am planning to use MATLAB to read the messages on the bus to process the information, run some routines in  MATLAB and then transmit messages back on the bus. I just started working with PLUS+1 and I haven't bought the VNT toolbox yet. Appreciate your advice!!

Jelmer

  • Guest
Re: MATLAB Vehicle Network Tool Box to Read CAN messages
« Reply #1 on: January 31, 2011, 09:37:18 PM »
Nope didn't try, but I think it should work. As long as you know exactly what the message should look like. I know that it's done in bi-fuel diesel engines....but why would you want to use MATLAB ??

santosh1802

  • Guest
Re: MATLAB Vehicle Network Tool Box to Read CAN messages
« Reply #2 on: February 01, 2011, 03:58:57 AM »
Hi jelmer,

Thanks for the reply,

Actually I want to develop a MATLAB application that can read two comm ports on a laptop (GPS and wireless information )and the CAN BUS (USB). I am going to have one PLUS+1 I/O module and two PLUS+1 Controllers on my CAN BUS. Based on the information obtained from the two comm ports and the sensors on the CAN BUS, I want to send suitable commands to the PLUS+1 controllers that controls the speed of the motor and the steering of my machine.

Summary:

1) Receive sensor information ( CAN to serial conversion using MATLAB's VNT)

2) Process my sensor, GPS and wireless data information in MATLAB( NOTE: GPS and wireless data has nothing to do with Plus+1 guide, I am just telling you as to why I am using MATLAB) 

3) Send suitable command (serial to CAN conversion using MATLAB's VNT)

I am assuming that I can receive and transmit CAN messages using MATLAB in real time.

What  do you think?

Thanks again for your time

Cheers,
Santosh


Offline Federico

  • PLUS+1 Developer
  • ***
  • Posts: 18
  • Karma: +1/-0
    • Centro HidrĂ¡ulico S. A.
Re: MATLAB Vehicle Network Tool Box to Read CAN messages
« Reply #3 on: July 07, 2011, 02:04:06 PM »
Hi Santosh,
Not if I'm understanding your question,
But if you want to take data with P +1 and sent to Matlab via CAN, you can do easily, you just have to take into account the direction in which you send data to read it with Matlab.
Of course you need the USB CAN Gateway. (The CG150 Sauer Danfoss works very well).
Best regards.
Federico

santosh1802

  • Guest
Re: MATLAB Vehicle Network Tool Box to Read CAN messages
« Reply #4 on: July 23, 2011, 08:43:15 PM »
Federico,

Thanks for the reply. I was able to communicate and log data using MATLAB VNT.

Also, I tried the Kvaser Leaf HS so that I can use their libraries to get the data into my VB.net programs. It works very well.

I can now receive data and send control commands using my VB.net program on the CAN bus to control my machine.

Thanks,
Santosh