]>
Commit | Line | Data |
---|---|---|
713be7a4 | 1 | struct scope { |
7906b395 MG |
2 | struct { |
3 | struct usb_dev_handle *dev; | |
fc648ed8 | 4 | int ep_bulk_out; |
fc648ed8 MG |
5 | int ep_bulk_in; |
6 | unsigned int wMaxPacketSize_in; | |
7b575069 MG |
7 | unsigned char bTag; |
8 | int brokenRigol; | |
90e416c4 | 9 | struct usbtmc_capabilities *cap; |
7906b395 | 10 | } usb; |
78fb0984 MG |
11 | struct { |
12 | struct { | |
13 | char lang[32]; | |
14 | int counter_enabled; | |
15 | int beep_enabled; | |
16 | } system; | |
17 | ||
18 | struct { | |
19 | int key_lock; | |
20 | } keyboard; | |
21 | ||
22 | struct { | |
23 | /* TODO */ | |
24 | } measure; | |
25 | ||
26 | struct { | |
27 | char type[32]; | |
28 | char mode[32]; | |
29 | int averages; | |
30 | double srate_chan1; | |
31 | double srate_chan2; | |
32 | double srate_digital; | |
33 | } acquire; | |
34 | ||
35 | struct { | |
36 | /* TODO */ | |
37 | } display; | |
38 | ||
39 | struct { | |
40 | /* TODO */ | |
41 | } channel; | |
42 | ||
43 | struct { | |
44 | char mode[32]; | |
45 | double offset; | |
46 | double delayed_offset; | |
47 | double scale; | |
48 | char format[32]; | |
49 | } timebase; | |
50 | ||
51 | struct { | |
52 | /* TODO */ | |
53 | } trigger; | |
54 | ||
55 | struct { | |
56 | /* TODO */ | |
57 | } la; | |
58 | ||
59 | struct { | |
60 | /* TODO */ | |
61 | } math; | |
62 | } status; | |
713be7a4 MG |
63 | char idn[128]; |
64 | }; | |
65 | ||
66 | int sendscpi(struct scope* sc, char* cmd, unsigned char *resp, int resplen); | |
67 | struct scope* initscope(void); | |
68 | void closescope(struct scope* sc); | |
69 | void claimscope(struct scope* sc); | |
70 | void releasescope(struct scope* sc); | |
10ca7ea8 | 71 | void resetscope(struct scope* sc); |
713be7a4 | 72 | char *scope_idn(struct scope *sc); |
78fb0984 MG |
73 | char *scope_get_string(struct scope *sc, char *cmd, int maxlen); |
74 | int scope_get_truth_value(struct scope *sc, char *cmd); | |
75 | int scope_get_int(struct scope *sc, char *cmd); | |
76 | double scope_get_double(struct scope *sc, char*cmd); | |
77 | int update_scope_status(struct scope *sc); |