diff options
| author | 2007-02-14 05:29:18 +0000 | |
|---|---|---|
| committer | 2007-02-14 05:29:18 +0000 | |
| commit | fa981a8b96ec3d09385a0b14b4342e574b7bbe29 (patch) | |
| tree | 512bc4640fd1f1501d4c2af09469224d881f07b9 /src/iso.c | |
| parent | bugfix segfault in raw1394_iso_shutdown on no iso activity due to not initial... (diff) | |
added raw1394_read_cycle_timer, contributed by Pieter Palmers
git-svn-id: svn://svn.linux1394.org/libraw1394/trunk@169 53a565d1-3bb7-0310-b661-cf11e63c67ab
Diffstat (limited to 'src/iso.c')
| -rw-r--r-- | src/iso.c | 14 |
1 files changed, 14 insertions, 0 deletions
@@ -498,6 +498,20 @@ void raw1394_iso_shutdown(raw1394handle_t handle) handle->iso_mode = ISO_INACTIVE; } +int raw1394_read_cycle_timer(raw1394handle_t handle, + u_int32_t *cycle_timer, u_int64_t *local_time) +{ + int err; + struct raw1394_cycle_timer ctr = { 0 }; + + err = ioctl(handle->fd, RAW1394_IOC_GET_CYCLE_TIMER, &ctr); + if (!err) { + *cycle_timer = ctr.cycle_timer; + *local_time = ctr.local_time; + } + return err; +} + static int _raw1394_iso_recv_packets(raw1394handle_t handle) { struct raw1394_iso_status *stat = &handle->iso_status; |
