-
Notifications
You must be signed in to change notification settings - Fork 10
Amp1394 Library Swig Status
Zihan Chen edited this page Dec 15, 2016
·
8 revisions
- Rename swig file to Amp1394.i & change module name
- Write some testing files
- Document swig typemap techniques
No. | Methods | FW | Eth | Python |
---|---|---|---|---|
1 | Constructor | Y | Y | fw = amp1394.FirewirePort(0) |
1 | NumberOfUsers | Y | Y | nuser = fw.NumberOfUsers() |
1 | GetNumOfNodes | Y | Y | nnodes = fw.GetNumOfNodes() |
2 | GetNode2Board | N | N | N/A |
3 | Reset | Y | N | fw.Reset() |
4 | IsOK | Y | N | ok = fw.IsOK() |
5 | AddBoard | Y | Y | ret = fw.AddBoard(board) |
6 | RemoveBoard | Y | Y | ret = fw.RemoveBoard(bid) |
7 | GetBoard | Y | Y | board = fw.GetBoard(bid) |
8 | GetNodeId | Y | Y | nid = fw.GetNodeId(bid) |
9 | GetFirmwareVersion | Y | Y | fver = fw.GetFirmwareVersion(bid) |
10 | ReadAllBoards | Y | Y | ret = fw.ReadAllBoards() |
11 | ReadAllBoardsBroadcast | Y | Y | ret = fw.ReadAllBoardsBroadcast() |
12 | WriteAllBoards | Y | Y | ret = fw.WriteAllBoards() |
13 | WriteAllBoardsBroadcast | Y | Y | ret = fw.WriteAllBoardsBroadcast() |
14 | ReadQuadlet | Y | Y | ret, val = fw.ReadQuadlet(bid, 0x03) |
15 | WriteQuadlet | Y | Y | ret = fw.WriteQuadlet(bid, 0x03, 0x44) |
16 | WriteQuadletBroadcast | Y | Y | fw.WriteQuadletBroadcast(0x03, 0x55) |
17 | ReadBlock | Y | Y | fw.ReadBlock(bid, addr, numOfQuad) |
18 | WriteBlock | Y | Y | fw.WriteBlock(bid, 0x1000, [0x11, 0x22]) |
19 | WriteBlockBroadcast | Y | Y | fw.WriteBlockBroadcast(0x1000, [0x11, 0x22]) |
20 | PromDelay | Y | Y | fw.PromDelay() |
21 | StopCycleStartPacket | Y | Y | fw.StopCycleStartPacket() |
NOTE
# ReadBlock interface takes number of quadlets as input
bid = 0
fw.ReadBlock(bid, 0x1000, 3)
# returns:
# [True, array([285212672, 570425344, 855638016], dtype=uint32)]
No. | Methods | Status | Python |
---|---|---|---|
1 | ReadStatus | Y | |
2 | ReadPowerStatus | Y | |
3 | ReadSafetyRelayStatus | Y | |
4 | ReadSafetyAmpDisable | Y | |
5 | ReadEncoderPreload | Y | |
6 | ReadDoutControl | Y | [ret, high, low] = ReadDoutControl(index) |
7 | WritePowerEnable | Y | |
8 | WriteAmpEnable | Y | |
9 | WriteSafetyRelay | Y | |
10 | WriteEncoderPreload | Y | |
11 | WriteDigitalOutput | Y | |
12 | WriteWatchdogPeriod | Y | |
13 | WriteDoutControl | Y | |
14 | WritePWM | Y | |
15 | GetDoutCounts | Y |