Better documentation + examples
This commit is contained in:
186
uml/classes.html
Normal file
186
uml/classes.html
Normal file
@@ -0,0 +1,186 @@
|
||||
<html>
|
||||
<body>
|
||||
<script src="https://cdn.jsdelivr.net/npm/mermaid/dist/mermaid.min.js"></script>
|
||||
<div class="mermaid">
|
||||
|
||||
classDiagram
|
||||
class CommMethod {
|
||||
name
|
||||
}
|
||||
class DG2052 {
|
||||
comm
|
||||
port : str
|
||||
rm
|
||||
get_output_impedance(channel: Literal[1, 2]) float
|
||||
get_output_load(channel: Literal[1, 2]) float
|
||||
get_output_signal(channel: Literal[1, 2]) str
|
||||
get_output_state(channel: Literal[1, 2]) str
|
||||
get_output_volt_limits(channel: Literal[1, 2]) tuple[float, float]
|
||||
is_output_on(channel: Literal[1, 2]) bool
|
||||
set_dc(channel: Literal[1, 2], offset: float)
|
||||
set_frequency(channel: Literal[1, 2], freq)
|
||||
set_output(channel: Literal[1, 2], state: bool)
|
||||
set_ramp(channel: Literal[1, 2], freq: float, amp: float, offset: float, phase: int)
|
||||
set_sine_wave(channel: Literal[1, 2], freq: float, amp: float, offset: float, phase: int)
|
||||
set_square_wave(channel: Literal[1, 2], freq: float, amp: float, offset: float, phase: int)
|
||||
set_sweep(channel: Literal[1, 2], amp: float, offset: float, phase: int, signal_type: SweepSignalType, htime_start: float, htime_stop: float, freq_start: float, freq_stop: float, marker: bool, freq_marker: float, rtime: float, time: float, spacing: SweepSpacing, step: int, trigger_slope: SweepTriggerSlope, trigger_source: SweepTriggerSource)
|
||||
toggle_output(channel: Literal[1, 2])
|
||||
trigger_sweep(channel: Literal[1, 2])
|
||||
whoami() str
|
||||
}
|
||||
class LAN {
|
||||
name
|
||||
value
|
||||
}
|
||||
class LibraryPath {
|
||||
arch
|
||||
found_by : str
|
||||
path : str
|
||||
}
|
||||
class OutputChannel {
|
||||
name
|
||||
}
|
||||
class ResourceManager {
|
||||
last_status
|
||||
session
|
||||
visalib
|
||||
close() None
|
||||
ignore_warning() ContextManager
|
||||
list_opened_resources() List['Resource']
|
||||
list_resources(query: str) Tuple[str, ...]
|
||||
list_resources_info(query: str) Dict[str, ResourceInfo]
|
||||
open_bare_resource(resource_name: str, access_mode: constants.AccessModes, open_timeout: int) Tuple[VISASession, StatusCode]
|
||||
open_resource(resource_name: str, access_mode: constants.AccessModes, open_timeout: int, resource_pyclass: Optional[Type['Resource']]) 'Resource'
|
||||
register_resource_class(interface_type: constants.InterfaceType, resource_class: str, python_class: Type['Resource']) None
|
||||
resource_info(resource_name: str, extended: bool) ResourceInfo
|
||||
}
|
||||
class StatusCode {
|
||||
name
|
||||
}
|
||||
class SweepSignalType {
|
||||
name
|
||||
}
|
||||
class SweepSpacing {
|
||||
name
|
||||
}
|
||||
class SweepTriggerSlope {
|
||||
name
|
||||
}
|
||||
class SweepTriggerSource {
|
||||
name
|
||||
}
|
||||
class USB {
|
||||
name
|
||||
value
|
||||
}
|
||||
class UndefinedCommunicationMethodError {
|
||||
}
|
||||
class UndefinedValueError {
|
||||
}
|
||||
class ValueOutOfBoundsError {
|
||||
}
|
||||
class VisaLibraryBase {
|
||||
handlers : DefaultDict[VISASession, List[Tuple[VISAHandler, Any, Any, Any]]]
|
||||
issue_warning_on : Set[StatusCode]
|
||||
last_status
|
||||
library_path
|
||||
resource_manager : Optional['ResourceManager']
|
||||
assert_interrupt_signal(session: VISASession, mode: constants.AssertSignalInterrupt, status_id: int)* StatusCode
|
||||
assert_trigger(session: VISASession, protocol: constants.TriggerProtocol)* StatusCode
|
||||
assert_utility_signal(session: VISASession, line: constants.UtilityBusSignal)* StatusCode
|
||||
buffer_read(session: VISASession, count: int)* Tuple[bytes, StatusCode]
|
||||
buffer_write(session: VISASession, data: bytes)* Tuple[int, StatusCode]
|
||||
clear(session: VISASession)* StatusCode
|
||||
close(session: Union[VISASession, VISAEventContext, VISARMSession])* StatusCode
|
||||
disable_event(session: VISASession, event_type: constants.EventType, mechanism: constants.EventMechanism)* StatusCode
|
||||
discard_events(session: VISASession, event_type: constants.EventType, mechanism: constants.EventMechanism)* StatusCode
|
||||
enable_event(session: VISASession, event_type: constants.EventType, mechanism: constants.EventMechanism, context: None)* StatusCode
|
||||
flush(session: VISASession, mask: constants.BufferOperation)* StatusCode
|
||||
get_attribute(session: Union[VISASession, VISAEventContext, VISARMSession], attribute: Union[constants.ResourceAttribute, constants.EventAttribute])* Tuple[Any, StatusCode]
|
||||
get_buffer_from_id(job_id: VISAJobID)* Optional[SupportsBytes]
|
||||
get_debug_info() DebugInfo
|
||||
get_last_status_in_session(session: Union[VISASession, VISARMSession]) StatusCode
|
||||
get_library_paths() Iterable[LibraryPath]
|
||||
gpib_command(session: VISASession, data: bytes)* Tuple[int, StatusCode]
|
||||
gpib_control_atn(session: VISASession, mode: constants.ATNLineOperation)* StatusCode
|
||||
gpib_control_ren(session: VISASession, mode: constants.RENLineOperation)* StatusCode
|
||||
gpib_pass_control(session: VISASession, primary_address: int, secondary_address: int)* StatusCode
|
||||
gpib_send_ifc(session: VISASession)* StatusCode
|
||||
handle_return_value(session: Optional[Union[VISAEventContext, VISARMSession, VISASession]], status_code: int) StatusCode
|
||||
ignore_warning(session: Union[VISASession, VISARMSession]) Iterator
|
||||
in_16(session: VISASession, space: constants.AddressSpace, offset: int, extended: bool)* Tuple[int, StatusCode]
|
||||
in_32(session: VISASession, space: constants.AddressSpace, offset: int, extended: bool)* Tuple[int, StatusCode]
|
||||
in_64(session: VISASession, space: constants.AddressSpace, offset: int, extended: bool)* Tuple[int, StatusCode]
|
||||
in_8(session: VISASession, space: constants.AddressSpace, offset: int, extended: bool)* Tuple[int, StatusCode]
|
||||
install_handler(session: VISASession, event_type: constants.EventType, handler: VISAHandler, user_handle: Any)* Tuple[VISAHandler, Any, Any, StatusCode]
|
||||
install_visa_handler(session: VISASession, event_type: constants.EventType, handler: VISAHandler, user_handle: Any) Any
|
||||
list_resources(session: VISARMSession, query: str)* Tuple[str, ...]
|
||||
lock(session: VISASession, lock_type: constants.Lock, timeout: int, requested_key: Optional[str])* Tuple[str, StatusCode]
|
||||
map_address(session: VISASession, map_space: constants.AddressSpace, map_base: int, map_size: int, access: Literal[False], suggested: Optional[int])* Tuple[int, StatusCode]
|
||||
map_trigger(session: VISASession, trigger_source: constants.InputTriggerLine, trigger_destination: constants.OutputTriggerLine, mode: None)* StatusCode
|
||||
memory_allocation(session: VISASession, size: int, extended: bool)* Tuple[int, StatusCode]
|
||||
memory_free(session: VISASession, offset: int, extended: bool)* StatusCode
|
||||
move(session: VISASession, source_space: constants.AddressSpace, source_offset: int, source_width: constants.DataWidth, destination_space: constants.AddressSpace, destination_offset: int, destination_width: constants.DataWidth, length: int)* StatusCode
|
||||
move_asynchronously(session: VISASession, source_space: constants.AddressSpace, source_offset: int, source_width: constants.DataWidth, destination_space: constants.AddressSpace, destination_offset: int, destination_width: constants.DataWidth, length: int)* Tuple[VISAJobID, StatusCode]
|
||||
move_in(session: VISASession, space: constants.AddressSpace, offset: int, length: int, width: Union[Literal[8, 16, 32, 64], constants.DataWidth], extended: bool) Tuple[List[int], StatusCode]
|
||||
move_in_16(session: VISASession, space: constants.AddressSpace, offset: int, length: int, extended: bool)* Tuple[List[int], StatusCode]
|
||||
move_in_32(session: VISASession, space: constants.AddressSpace, offset: int, length: int, extended: bool)* Tuple[List]
|
||||
move_in_64(session: VISASession, space: constants.AddressSpace, offset: int, length: int, extended: bool)* Tuple[List[int], StatusCode]
|
||||
move_in_8(session: VISASession, space: constants.AddressSpace, offset: int, length: int, extended: bool)* Tuple[List[int], StatusCode]
|
||||
move_out(session: VISASession, space: constants.AddressSpace, offset: int, length: int, data: Iterable[int], width: Union[Literal[8, 16, 32, 64], constants.DataWidth], extended: bool) StatusCode
|
||||
move_out_16(session: VISASession, space: constants.AddressSpace, offset: int, length: int, data: Iterable[int], extended: bool)* StatusCode
|
||||
move_out_32(session: VISASession, space: constants.AddressSpace, offset: int, length: int, data: Iterable[int], extended: bool)* StatusCode
|
||||
move_out_64(session: VISASession, space: constants.AddressSpace, offset: int, length: int, data: Iterable[int], extended: bool)* StatusCode
|
||||
move_out_8(session: VISASession, space: constants.AddressSpace, offset: int, length: int, data: Iterable[int], extended: bool)* StatusCode
|
||||
open(session: VISARMSession, resource_name: str, access_mode: constants.AccessModes, open_timeout: int)* Tuple[VISASession, StatusCode]
|
||||
open_default_resource_manager()* Tuple[VISARMSession, StatusCode]
|
||||
out_16(session: VISASession, space: constants.AddressSpace, offset: int, data: int, extended: bool)* StatusCode
|
||||
out_32(session: VISASession, space: constants.AddressSpace, offset: int, data: Iterable[int], extended: bool)* StatusCode
|
||||
out_64(session: VISASession, space: constants.AddressSpace, offset: int, data: Iterable[int], extended: bool)* StatusCode
|
||||
out_8(session: VISASession, space: constants.AddressSpace, offset: int, data: int, extended: bool)* StatusCode
|
||||
parse_resource(session: VISARMSession, resource_name: str) Tuple[ResourceInfo, StatusCode]
|
||||
parse_resource_extended(session: VISARMSession, resource_name: str) Tuple[ResourceInfo, StatusCode]
|
||||
peek(session: VISASession, address: VISAMemoryAddress, width: Union[Literal[8, 16, 32, 64], constants.DataWidth]) Tuple[int, StatusCode]
|
||||
peek_16(session: VISASession, address: VISAMemoryAddress)* Tuple[int, StatusCode]
|
||||
peek_32(session: VISASession, address: VISAMemoryAddress)* Tuple[int, StatusCode]
|
||||
peek_64(session: VISASession, address: VISAMemoryAddress)* Tuple[int, StatusCode]
|
||||
peek_8(session: VISASession, address: VISAMemoryAddress)* Tuple[int, StatusCode]
|
||||
poke(session: VISASession, address: VISAMemoryAddress, width: Union[Literal[8, 16, 32, 64], constants.DataWidth], data: int) StatusCode
|
||||
poke_16(session: VISASession, address: VISAMemoryAddress, data: int)* StatusCode
|
||||
poke_32(session: VISASession, address: VISAMemoryAddress, data: int)* StatusCode
|
||||
poke_64(session: VISASession, address: VISAMemoryAddress, data: int)* StatusCode
|
||||
poke_8(session: VISASession, address: VISAMemoryAddress, data: int)* StatusCode
|
||||
read(session: VISASession, count: int)* Tuple[bytes, StatusCode]
|
||||
read_asynchronously(session: VISASession, count: int)* Tuple[SupportsBytes, VISAJobID, StatusCode]
|
||||
read_memory(session: VISASession, space: constants.AddressSpace, offset: int, width: Union[Literal[8, 16, 32, 64], constants.DataWidth], extended: bool) Tuple[int, StatusCode]
|
||||
read_stb(session: VISASession)* Tuple[int, StatusCode]
|
||||
read_to_file(session: VISASession, filename: str, count: int)* Tuple[int, StatusCode]
|
||||
set_attribute(session: VISASession, attribute: constants.ResourceAttribute, attribute_state: Any)* StatusCode
|
||||
set_buffer(session: VISASession, mask: constants.BufferType, size: int)* StatusCode
|
||||
status_description(session: VISASession, status: StatusCode)* Tuple[str, StatusCode]
|
||||
terminate(session: VISASession, degree: None, job_id: VISAJobID)* StatusCode
|
||||
uninstall_all_visa_handlers(session: Optional[VISASession]) None
|
||||
uninstall_handler(session: VISASession, event_type: constants.EventType, handler: VISAHandler, user_handle: Any)* StatusCode
|
||||
uninstall_visa_handler(session: VISASession, event_type: constants.EventType, handler: VISAHandler, user_handle: Any) None
|
||||
unlock(session: VISASession)* StatusCode
|
||||
unmap_address(session: VISASession)* StatusCode
|
||||
unmap_trigger(session: VISASession, trigger_source: constants.InputTriggerLine, trigger_destination: constants.OutputTriggerLine)* StatusCode
|
||||
usb_control_in(session: VISASession, request_type_bitmap_field: int, request_id: int, request_value: int, index: int, length: int)* Tuple[bytes, StatusCode]
|
||||
usb_control_out(session: VISASession, request_type_bitmap_field: int, request_id: int, request_value: int, index: int, data: bytes)* StatusCode
|
||||
vxi_command_query(session: VISASession, mode: constants.VXICommands, command: int)* Tuple[int, StatusCode]
|
||||
wait_on_event(session: VISASession, in_event_type: constants.EventType, timeout: int)* Tuple[constants.EventType, VISAEventContext, StatusCode]
|
||||
write(session: VISASession, data: bytes)* Tuple[int, StatusCode]
|
||||
write_asynchronously(session: VISASession, data: bytes)* Tuple[VISAJobID, StatusCode]
|
||||
write_from_file(session: VISASession, filename: str, count: int)* Tuple[int, StatusCode]
|
||||
write_memory(session: VISASession, space: constants.AddressSpace, offset: int, data: int, width: Union[Literal[8, 16, 32, 64], constants.DataWidth], extended: bool) StatusCode
|
||||
}
|
||||
LAN --* DG2052 : comm
|
||||
USB --* DG2052 : comm
|
||||
StatusCode --* VisaLibraryBase : _last_status
|
||||
ResourceManager --* DG2052 : rm
|
||||
VisaLibraryBase --* ResourceManager : visalib
|
||||
LibraryPath --* VisaLibraryBase : library_path
|
||||
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
54
uml/packages.html
Normal file
54
uml/packages.html
Normal file
@@ -0,0 +1,54 @@
|
||||
<html>
|
||||
<body>
|
||||
<script src="https://cdn.jsdelivr.net/npm/mermaid/dist/mermaid.min.js"></script>
|
||||
<div class="mermaid">
|
||||
|
||||
classDiagram
|
||||
class fn_gen {
|
||||
}
|
||||
class common {
|
||||
}
|
||||
class dg2052 {
|
||||
}
|
||||
class enums {
|
||||
}
|
||||
class comm_method {
|
||||
}
|
||||
class output_channel {
|
||||
}
|
||||
class sweep_signal_type {
|
||||
}
|
||||
class sweep_spacing {
|
||||
}
|
||||
class sweep_trigger_slope {
|
||||
}
|
||||
class sweep_trigger_source {
|
||||
}
|
||||
class errors {
|
||||
}
|
||||
class undefined_communication_method_error {
|
||||
}
|
||||
class undefined_value_error {
|
||||
}
|
||||
class value_out_of_bounds_error {
|
||||
}
|
||||
fn_gen --> dg2052
|
||||
fn_gen --> enums
|
||||
fn_gen --> errors
|
||||
common --> errors
|
||||
dg2052 --> common
|
||||
dg2052 --> enums
|
||||
dg2052 --> errors
|
||||
enums --> comm_method
|
||||
enums --> output_channel
|
||||
enums --> sweep_signal_type
|
||||
enums --> sweep_spacing
|
||||
enums --> sweep_trigger_slope
|
||||
enums --> sweep_trigger_source
|
||||
errors --> undefined_communication_method_error
|
||||
errors --> undefined_value_error
|
||||
errors --> value_out_of_bounds_error
|
||||
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user