How do I set a variable identifier in an xPC CAN send block for the softing CAN-AC2-PCI

1 次查看(过去 30 天)
I am trying to pass a CAN message into a CAN send block for the xPC softing CAN block canac2pcisend (for the CAN-AC2-PCI hardware). I would like to be able to use a variable name for my identifier so I can put this in part of my masked subsystem and pass the value in. If I try to set the name to a variable, my input port on the block disappears. Does anyone know how to do this? Rather than having [1163] in the Identifiers field on my block, I am putting [TBCANID] and have TBCANID defined as a parameter in the mask for the subsystem this block is in. If I change what is in the brackets to anything other than a number in the allowable range, the input port just disappears.

采纳的回答

Jill
Jill 2012-2-17
I have fixed the problem. I had a variable name mismatch and rather than issuing an error, it just got rid of the input port. Once I used the correct name, the input port remained.
There is an additional problem that I encountered and that is that you cannot put the CAN transmit block for this device into a masked subsystem. The vehicle network toolkit has this same problem and it has a bug report out on it. Can anyone verify that this is indeed a bug in the xPC CAN transmit for softing CAN-AC2-PCI. When you mask the subsystem it is in, and try to use the variable name of a mask parameter for the identifier in the CAN transmit, it gives the following error "undefined function or variable".

更多回答(0 个)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by