CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

Simple CanBus question.

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
lecutus



Joined: 12 Aug 2009
Posts: 40

View user's profile Send private message

Simple CanBus question.
PostPosted: Tue Dec 29, 2009 3:17 pm     Reply with quote

Simple CanBus question. Does the Can bus always send out info or does it have to be asked?

Situ:
I trying to rewrite a engine control package, sending/receiving parameters. Sending parameters to change rpm, gear, etc. Receiving from the engine as to confirm what it thinks it did; on board parameters.

As it stands I can write to the eeprom: id, engine, trans. I can see the display of this information in hyperterminal.

When checking can_kbhit, it reads 0. From what I understand this means nothing in the can buffer. So how to fill it is the question.

What 's supposed to happen
Check buffer
check for id that matches truck to be process – multi truck scenario
yes – parse string to its basic components.
Send via rs232 for further processing and display at outward controller/gui
Send from outward controller/gui parameters back to can bus.
Check buffer.

I'm using j1939.

Thanks
L.
Shocked Shocked
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Tue Dec 29, 2009 5:07 pm     Reply with quote

CAN bus controllers have a "listen only" mode. It's listed as one of the
modes in the CCS drivers. I haven't used this mode.
Quote:
enum CAN_OP_MODE {CAN_OP_CONFIG=4, CAN_OP_LISTEN=3, CAN_OP_LOOPBACK=2, CAN_OP_DISABLE=1, CAN_OP_NORMAL=0};

For more information, Google for this:
Quote:
can bus data logger listen only


However, I think you're really asking, does your particular vehicle
send out all the information that you desire onto the CAN bus at
a periodic rate.
lecutus



Joined: 12 Aug 2009
Posts: 40

View user's profile Send private message

PostPosted: Wed Dec 30, 2009 8:50 am     Reply with quote

Awright, let me reiterate.

I, as the user may need to send information, such as gear, rpm, to effect the engine.

The engine is to send back information as to its current situation.

That simple.

L.
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group