Require Assistance to Create TSC1 Increment Feature

Discuss issues and ideas you have to configuring displays with PowerVision
SidJayasinghe
Posts: 11
Joined: Tue Oct 26, 2010 5:13 am

Require Assistance to Create TSC1 Increment Feature

Post by SidJayasinghe » Thu Apr 28, 2011 11:34 am

I have a requirement to create a TSC1 based speed increment (& decrement) feature within the PV450 as follows:

Button#2 will be allocated as Engine Speed Increment.
Button#8 will be allocated as Engine Speed Decrement.

Functionality required:
Engine has been started and is running at idle speed.
PV450, upon power up will always send TSC1 message with data value such that TSC1 =450 RPM (this value set during configuration)
A counter (STEP SIZE) is required, with range [1-100]. (this value is set during configguration only at this stage.)
Pressing button#2 causes following: New TSC1 speed request = old TSC1 speed request + Step Size.
Pressing button#2 again repeats following: New TSC1 speed request = old TSC1 speed request + Step Size.
Holding button#2 down causes the above to RAMP at a preset period, where the FREQUENCY of recalculating is within a range of [PERIOD: 0.1 sec - 2 sec] as follows: New TSC1 speed request = old TSC1 speed request + ((Time button is held / Period) * Step Size).
The last calculated value is held until power to the PV450 is recycled.

TSC1 should have a range [TSC1 RANGE: 400 RPM - 3000 RPM]
Button#8 will be a speed decrement, same as above, but negative.
The PV750 could also be used in lieu of PV450.

Look forward to your assistance.

Sid Jayasinghe
ksaenz
Enovation Controls Development
Enovation Controls Development
Posts: 263
Joined: Thu Aug 19, 2010 7:53 am

Re: Require Assistance to Create TSC1 Increment Feature

Post by ksaenz » Fri Apr 29, 2011 8:15 am

To send the TSC1 message you need to add PGN 0 to the J1939/NMEA Parameters list (Database section) and add the parameters you want to send to the Transmit Device of the CAN port you are using (Environment Setup section).

To increase and decrease the requested speed you need to make calculation events.
Remember that on calculation events you just need to add the right side of the formula so it will look something like this:

Code: Select all

"J1939.Engine.Engine Requested Speed" + "UserDefinedVariable.StepSize"
rather than this:

Code: Select all

"J1939.Engine.Engine Requested Speed" = "J1939.Engine.Engine Requested Speed" + "UserDefinedVariable.StepSize"
To limit the range you can add the MIN() and MAX() functions to the calculation events like this:

Code: Select all

MAX("J1939.Engine.Engine Requested Speed" - "UserDefinedVariable.StepSize", 400)
MIN("J1939.Engine.Engine Requested Speed" + "UserDefinedVariable.StepSize", 3000)
You could fire the calculation events from the button presses directly or you could fire a transition in a state machine that will execute the calculation events upon entering or exiting a state.

Regards,

ksaenz
SidJayasinghe
Posts: 11
Joined: Tue Oct 26, 2010 5:13 am

Re: Require Assistance to Create TSC1 Increment Feature

Post by SidJayasinghe » Tue May 10, 2011 12:46 pm

Hi Kristan,

I have been travelling the last weeks and have come back to this project which I now need to complete and deliver asap!! Only thing is that whilst I know the logic I need, I'm not certain of where to start, but believe I need to create/define the variables, write the calculation, then tie these to the button press for each. Do you have any sample files I can use for reference and for writing future events?

Also this is my first PV450 job. Is the USB donwload process the same process as the PV750, using the two lowermost right hand side buttons??

Any guidance is greatly appreciated,

Kind regards and thanks

Is there a number I could contact you on?

Kind regards
Sid Jayasinghe
+61-413-749-317
ksaenz
Enovation Controls Development
Enovation Controls Development
Posts: 263
Joined: Thu Aug 19, 2010 7:53 am

Re: Require Assistance to Create TSC1 Increment Feature

Post by ksaenz » Tue May 10, 2011 2:32 pm

Hi Sid,

You are correct, start with creating the variables, the make calculation events for them, and finally tie the button presses to the calculation events (or state transitions).

You can read the topic below and use the configuration I attached as an example:
viewtopic.php?f=5&t=202

To go the bootload screen in the PV450 you just need to hold one button when you power up.

I will send you my contact information by PM.

Regards,

ksaenz
SidJayasinghe
Posts: 11
Joined: Tue Oct 26, 2010 5:13 am

RevisionRe: Require Assistance to Create TSC1 Increment/ Fea

Post by SidJayasinghe » Mon May 16, 2011 10:15 am

Hi,

Kristian has been of great assistance, helping us to program the PV450 with a TSC1 control based Speed Increment / Speed Decrement.

ECM (keyswitch) power control works fine (Key#1= ECM Key power ON whilst key#5 = ECM power OFF which thelatter is used to stop the engine).
CRANK ON (key #3) remains in the latcehd position, when ideally it would always be broadcasting a [PGN65290 (data=0), changing state upon keypress ##3). data value 1 would only transmit for approx 10 seconds, then revert to data value 0. {Currently I am using key #6 to fire an action to change the crank signal (PGN65290) back to data value =0.}

I have sent the db3 file to teh following site for you to download. Possibly best to use this site to return any modifie dfile back to me.

https://www.yousendit.com/download/MEtU ... MEpFQlE9PQ


Areas where I require urgent assistance are:

Keypress #2 should be the engine "crank" signal (PGN65290 [data=1]via Axiomatic module). This should have had a 10 second delay. Instead itseems to latch ON, continuously. Temporarily I have fitted a 'Stop Cranking" via #7 key press to cut the cranking cycle. I am not familiar with creating timers, etc.

Can you add a "10 second active, then OFF" to the Crank (ON) variable for when Button 5 is pressed? Initially we had the PGN65290 [data=0] as the default 'fired' broadcast (starter OFF), and this value temporarily changed to 1 when Button #3 has been pressed. I think this timer got lost with the addition of the PGN65300 keylock. I need the engine to NEVER CRANK unless the button #3 is pressed.

*I will need to include "RAMP ON HOLD" feature for the the speed increment / speed decrement. With the CANCapture, I can see that keys #2 & #4 respectively change the message's data values change. (I tried to engine test today, however due to engine low fuel indication, )the Recall button (popup) was permanently switched on screen - And I couldn't access button #2 to Increment Speed...... Given I have engine control functions (TSC1) assgined(to a key that is common with other features, (Pop Up-,,. ) such as Recall, I need to understand how best we can adopt these revisions.

*With the addition of the Key Lock feature (PV450 keys (1, 3, 5, should ONLY be active when PGN 63500 is present on the datalink. PGN63500 is beng broadcast by the Axiomatic (AX02190 module when itself is powered up...
I would like to be able to Increment (key @2) and decrment key (key#4) when the the engine is started via teh autostart (CASCADE)
I am not sure if PGN63500 is being broadcast by the PV450 as if it were coming from address "0" - but no engine were present at the time of bench testing.

I also notice that in environment, port setup that the axiomatic has been set up with Axiomatic Byte 1. I am not sure how Kristian intended for this to be used, though I believe it may be a misunderstanding of how the PV450 recognises that the axiomatic module is switched ON. ThePV450 did not need to broadcast with respect to this PGN.


I intend to test the TSC1 broadcast as it stands tomorow morning, but believe the customer requires 'RAMP ON HOLD". They would like it such that the ramp rate is 'adjustable' in the initial setup configuration. (In effect the change to a new speed via TSC1 would be at a transition ramp rate different to the engine default ramp rate.)

Please call me should you have any queries.

Thanks
Sid
+61-413-749-317
jtilley
Enovation Controls Development
Enovation Controls Development
Posts: 31
Joined: Wed Sep 08, 2010 10:02 am

Re: Require Assistance to Create TSC1 Increment Feature

Post by jtilley » Mon May 16, 2011 4:40 pm

Hi Sid,

Kristian is out of town this week. I'll be providing assistance in his absence.

Attached is an updated configuration.

Changes:
  • I added basic key repeat on the TSC1 inc/dec buttons
    • See the state machine "FFCAN Adjust TSC1 Speed" for more detail on its operation
    • You can adjust the repeat speed by changing the timer on the "TSC IncDec Key Repeat" event
  • I added the 10s crank sequence (at least how I understood that it should work)
    • See the "FFCAN Tx Crank" state machine for more detail on its operation
    • You can exit before the 10s timeout by pressing the Crank button a second time
  • I removed the Stop Crank button since it should now be unnecessary
  • I moved the TSC1 dec button down to Key.6 in order to accommodate the Recall button that you mentioned
  • I made the TSC1 inc/dec step size a variable, so that you can make it user configurable
    • I might have misunderstood your requirement on this topic
You had mentioned not being familiar with creating timers.
You can see how I used timers in the state machines listed above.
Basically, when you add a timer to an event, the event will be fired when the timer expires.
If it's a one-shot timer, the timer must be started with the CCM->StartTimer(timer) action.
If it's a recurring timer, it will automatically be running on system startup,
but you can stop and start it with the CCM->CancelTimer(timer) and
CCM->StartTimer(timer) actions, respectively.

Let me know if you have any more questions.

Thanks
Attachments
CMNS-RobLaine, QSB6.7 (Rev04).db3
(8.23 MiB) Downloaded 33 times
Joe Tilley
Software Engineer
FW Murphy
jtilley
Enovation Controls Development
Enovation Controls Development
Posts: 31
Joined: Wed Sep 08, 2010 10:02 am

Re: Require Assistance to Create TSC1 Increment Feature

Post by jtilley » Mon May 16, 2011 4:46 pm

One last thing I forgot to mention.

The PGN for the message coming from the Axiomatic device was marked as 65300 in the J1939 database in the configuration. I corrected it to 63500, per your post. Hopefully this will allow the PV450 to properly detect when the Axiomatic device is active.

Thanks
Joe Tilley
Software Engineer
FW Murphy
SidJayasinghe
Posts: 11
Joined: Tue Oct 26, 2010 5:13 am

Re: Require Assistance to Create TSC1 Increment Feature

Post by SidJayasinghe » Tue May 17, 2011 11:02 am

Hi Joe,

Kristian advised he'd be travelling this week, so your assistance is greatly appreciated. I hope to be able to get to the machine tomorrow, and shall provide feedback.

This mornings test (with prior revision) went into immediate cranking upon powering up of the system (this is a manual start mode). I believe this to be a combination of PV450 and the CAN convertor module. Shall benchtest in the morning first.

Other things I noticed and will require your assistance/advice with include:
(i) I need to change the priority of the TSC1 message as the engine speed would not rise above the engine's set speed point. I think a simple change in priority will fix this, but need to verify which pages need the priority change.
(ii) The CAN messages for Power ON, Crank/(if required), crank cut & TSC1 broadcast are simultaneously broadcast from the 2x PV450. This causes error when the J1939 message is sent as only one PV450 was "in control". Can you see a way of maintaining both PV450 displays in the ON status, yet have the messages be disiguishable by the engine? I have not encountered having 2x identical transmit devices connected to a single J1939 BUS. Now I'm thinking of powering only one a PV450 at a time (easyfix via select switch), as splicing a select switch in the power feed to each display would solve be easily achieved.

Your advice is greatly appreciated

Kind reagrsd

Sid
jtilley
Enovation Controls Development
Enovation Controls Development
Posts: 31
Joined: Wed Sep 08, 2010 10:02 am

Re: Require Assistance to Create TSC1 Increment Feature

Post by jtilley » Tue May 17, 2011 2:43 pm

Hi Sid,

The TSC1 message is defined in the configuration as a Free Form CAN message. You can see this by navigating to Environment Setup and selecting CANPort1 in the tree view. There will be a list of Free Form CAN Messages in the pane on the right, and one of those will be the TSC1 message (named "Tx TSC1").

Currently, the CAN ID of the message is 0x0C000000, which means the priority is 3. To adjust the priority, simply modify the CAN ID:
  • 0x08000000 for priority 2.
  • 0x04000000 for priority 1.
  • 0x00000000 for priority 0.
For the issue with two PV450s simultaneously transmitting, you could modify the "UserDefinedVariable.PlugA.Address" variable so that they are different on each display. By default, the source address of the PV450 is 242 (0xF2). You could change one of the configurations so that the source address is 0xF3 (243). This would make it easy to distinguish between the two displays on the CAN bus. This may or may not work if the ECU you're communicating with isn't able to distinguish its controller based on source address.

You could also modify the state machines in the PV450 configuration such that they won't start transmitting anything until some trigger happens that you define (such as a button press). Then you could just activate the PV450 that you wish.

You could also create a hardwired switch as you described. That would definitely solve the problem, but if you'd like to have both displays active at the same time with only one transmitting, that is definitely something that can be solved through configuration.

Let me know if you have any questions.

Thanks
Joe Tilley
Software Engineer
FW Murphy
SidJayasinghe
Posts: 11
Joined: Tue Oct 26, 2010 5:13 am

Re: Require Assistance to Create TSC1 Increment Feature

Post by SidJayasinghe » Thu May 19, 2011 10:57 am

Hi Joe,

Thanks for the file. However there seems to be something which has gone back a step - I think. I'll require your urgent assistance (or in your absence that of one of your colleagues) to have a look a the file you sent me....

I cannot get any of the buttons to work at all. I am not entirely sure that I follow your notes as to the logic how key 1 / key 3 / key 3 and key2 and key4 are supposed to be accessible.

I can confirm that:
PGN65300 is transmitting data of value 1. But nothing occurs.

I was intending to head out to the customer's again tomorrow morning as the pump will be delivered to their customer late tomorrow so sekk your urgent assistance.......

If possible can you please call me - II'll send my details in a PM.

Thanks and kind regards

Sid
jtilley
Enovation Controls Development
Enovation Controls Development
Posts: 31
Joined: Wed Sep 08, 2010 10:02 am

Re: Require Assistance to Create TSC1 Increment Feature

Post by jtilley » Thu May 19, 2011 3:07 pm

Hi Sid,

I'm sure that it is the PGN for the Axiomatic module. Based on a previous post of yours, I had changed the PGN from 65300 to 63500. It seems that this was in error, and if you change the PGN back to 65300, everything should work again.

To change the PGN:
  • Navigate to Database -> J1939/NMEA Parameters
  • Find PGN 63500 with description "Axiomatic PGN"
  • Change the PGN from 63500 to 65300
  • Save, Create, and Load to the PV450.
That should fix the problem. Sorry for the trouble.

Thanks
Joe Tilley
Software Engineer
FW Murphy
mbowdich
Posts: 209
Joined: Tue Oct 05, 2010 10:54 am

Re: Require Assistance to Create TSC1 Increment Feature

Post by mbowdich » Thu May 19, 2011 10:27 pm

Sid,

A couple of things to note on your application.

Yes, you can have multiple displays. I currently am using an application with 8 PV750s connected that all have identical software. They are connected to a diesel engine and an XM500. Each gets its own node number when configured. I handle the transmission of commands a couple of ways. For some of them that need to be broadcast from multiple nodes at the same time (different SPNs in the same PGN are coming from more than 1 source), I transmit only the SPN needed and fill the rest of the bits with 1s (J1939 for leave the last command). This way, the controller sees 2 messages, 1 with real data and 1 with all binary 1s. The controller uses the real data and ignores the one with the 1s.

The other thing I do for PGNs that I transmit the same SPN from multiple sources at a time, is to turn on and off the transmission. I am using FreeForm CAN to transmit the PGN and a state machine with a timer for timing. I start up the displays by cancelling the timers, and I only start up the timer on the 1 dispaly that I want to have command at that time. I have a button that is used on each display to transfer the command between dispalys.

One thing to keep in mind for using TSC1 from the display. Some controllers cannot accept slow transmission rates for TSC1 and ignore it if it is too slow, resulting in non-control (Detroit Diesel DDEC IV is an example that requires 10 ms or faster transmission repetition). From what I have been told, the display cannot accurately count faster than 50 ms, so this may or may not present a problem. If your controller supports slower TSC1 transmission rates, then it should be no problem.
SidJayasinghe
Posts: 11
Joined: Tue Oct 26, 2010 5:13 am

Re: Require Assistance to Create TSC1 Increment Feature

Post by SidJayasinghe » Wed May 25, 2011 11:09 am

Hi Joe / Kristian,

I tried the configuration sent to me over the weekend (Rev09), however noted the following:
* crank is now default=0, and is also cancelled by pressing Key#3 a second time. This is good.
* crank is however able to be re-engaged by pressing the Key#3 again. Ideally I would like to place the following rules, but whilst I know the logic, I am not sure how to program in PowerVision 2.2:
(i) crank enable for only 10 seconds after Key#3 is pressed. This is currently good. AND
(ii) disable cranking if Engine Speed >300 RPM, AND
(iii) do not allow (manual) recranking for 10 seconds AFTER Engine Speed=0.
item (ii) above is would be most important.
* TSC1 does not work in this configuration (with the bug fix for delatching of key repeat function. I had the customer confirm the engine calibration is set to throttle engine speed via SAE J1939 TSC1 protocol. I also tested this actual engine with the Murphy built 32-35-0126 control panel and was able to ramp engine speed from (low) idle upto high idle-so I conclude the engine is setup correctly. (End user has requested max engine (pump) speed of 1850 RPM -I can change this at our end)
* I also need to engage the logic for speed control (TSC1) when PGN65300=0 (as per my email earlier this week)
(i) If ((Axiomatic PGN65300 is not equal to 1) AND (Engine Speed>300 RPM)), THEN
(ii) PV450 to transmit TSC1=400 RPM and begin “Autostart warmup timer” and count for 120 seconds (adjustable upto 600 seconds). After this timer expires, THEN
(iii) PV450 to transmit TSC1 set speed of 1850 RPM, calculated to ramp at 100 RPM/sec(adjustable, variable??) (I'm thinking that I could work this out as a combination of the TSC1 Step Size variable and the recurring repeat rate)

* TSC1 INC & DEC needs to function only when PGN65300=1. This is currently correct in the configuration. I spoke with end user today and this is how they want to operate - contrary to what I mentioned in a recent email.

I have attached my latest revision (Rev10), which you can use as a basis for the modifications. (Rev10 is basically Rev09 modified with corrections to Requested Engine Speed (Increase Engine SPeed and Decrease Engine Speed) functions.

Whilst my major concern is why TSC1 is not functional at all, can you please advise estimated time to allow for the above changes (when PGN65300 is not equal to 1).

Please advise if you nee dme to do a CANCapture of the TSC1 message as being broadcast by the Murphy Control Panel 32-35-0126, which has some specific Controls and Modes for the TSC1 message to meet Cummins requirements

I cannot seem to attach the db3 file here, so will You send it to you.

If you need further information, please feel free to call me.

Thanks and kind regards

Sid
Attachments
CMNS-RobLaine, QSB6.7 (Rev10).db3
(8.27 MiB) Downloaded 26 times