public class CanFestivalJNI extends Object implements CanOpenInterface
| Constructor and Description |
|---|
CanFestivalJNI() |
| Modifier and Type | Method and Description |
|---|---|
void |
addReceivedPDO(int cobId)
Configures the pdo with the given cob_id for reception on the master node.
|
void |
clearCallBack(int nodeId)
to be used in case of timeout.
|
String |
info(int nodeID)
Returns the information for the given nodeID.
|
void |
init() |
void |
init(int master,
String baud,
String busName,
int nodeID)
Initialization of the master node.
|
boolean |
isReady() |
void |
quit() |
void |
reset(int nodeId)
Slave reset
|
long |
rsdo(int nodeId,
int index,
int subindex)
Send a read sdo command.
|
int |
scan()
Sends a scan on the can bus.
|
void |
setBootMessageListener(BootMessageListener bml) |
void |
setEmergencyMessageListener(EmergencyMessageListener eml) |
void |
setTimeoutMillis(long to) |
void |
ssta(int nodeId)
Slave start
|
void |
ssto(int nodeId)
Slave stop
|
void |
start() |
void |
stop() |
PDOData |
sync()
Sends a sync message on the canbus and synchronously waits for the received
pdo configured in the master to be received.
|
void |
wsdo(int nodeId,
int index,
int subindex,
int size,
long data)
Send a write sdo command.
|
@Command public void addReceivedPDO(int cobId)
CanOpenInterfaceaddReceivedPDO in interface CanOpenInterface@Command
public void init(int master,
String baud,
String busName,
int nodeID)
CanOpenInterfaceinit in interface CanOpenInterfacemaster - 1baud - "125K"busName - nodeID - the master nodeIdpublic void setEmergencyMessageListener(EmergencyMessageListener eml)
setEmergencyMessageListener in interface CanOpenInterfacepublic void setBootMessageListener(BootMessageListener bml)
setBootMessageListener in interface CanOpenInterface@Command public PDOData sync() throws org.lsst.ccs.drivers.commons.DriverException, org.lsst.ccs.drivers.commons.DriverTimeoutException, ConcurrentCallException
sync in interface CanOpenInterfaceorg.lsst.ccs.drivers.commons.DriverException - in case of a failure accessing the hardware, or if the hardware returns an errororg.lsst.ccs.drivers.commons.DriverTimeoutException - if the hardware doesn't respond within the specified timeoutConcurrentCallException - if a sync command is running and hasn't completed yet@Command public int scan()
CanOpenInterfacescan in interface CanOpenInterface@Command public String info(int nodeID) throws org.lsst.ccs.drivers.commons.DriverException
CanOpenInterfaceinfo in interface CanOpenInterfacenodeID - the node idorg.lsst.ccs.drivers.commons.DriverException@Command
public void wsdo(int nodeId,
int index,
int subindex,
int size,
long data)
throws org.lsst.ccs.drivers.commons.DriverException,
org.lsst.ccs.drivers.commons.DriverTimeoutException,
ConcurrentCallException
wsdo in interface CanOpenInterfacenodeId - index - subindex - size - data - org.lsst.ccs.drivers.commons.DriverException - in case of a failure accessing the hardware, or if the hardware returns an errororg.lsst.ccs.drivers.commons.DriverTimeoutException - if the hardware doesn't respond within the specified timeoutConcurrentCallException - if a write sdo / read sdo command was sent on the same node and hasn't completed yet@Command
public long rsdo(int nodeId,
int index,
int subindex)
throws org.lsst.ccs.drivers.commons.DriverException,
org.lsst.ccs.drivers.commons.DriverTimeoutException,
ConcurrentCallException
rsdo in interface CanOpenInterfacenodeId - index - subindex - org.lsst.ccs.drivers.commons.DriverException - in case of a failure accessing the hardware, or if the hardware returns an errororg.lsst.ccs.drivers.commons.DriverTimeoutException - if the hardware doesn't respond within the specified timeoutConcurrentCallException - if a write sdo / read sdo command was sent on the same node and hasn't completed yetpublic void ssta(int nodeId)
ssta in interface CanOpenInterfacenodeId - public void ssto(int nodeId)
ssto in interface CanOpenInterfacenodeId - public void reset(int nodeId)
reset in interface CanOpenInterfacenodeId - public void quit()
quit in interface CanOpenInterfacepublic void init()
init in interface CanOpenInterfacepublic void start()
start in interface CanOpenInterfacepublic void stop()
stop in interface CanOpenInterfacepublic boolean isReady()
isReady in interface CanOpenInterface@Command public void setTimeoutMillis(long to)
@Command public void clearCallBack(int nodeId)
Copyright © 2018 LSST. All rights reserved.