Gammu internals  1.38.0
GSM_Device_Functions Struct Reference

#include <gsmstate.h>

Data Fields

GSM_Error(* OpenDevice )(GSM_StateMachine *s)
 
GSM_Error(* CloseDevice )(GSM_StateMachine *s)
 
GSM_Error(* DeviceSetParity )(GSM_StateMachine *s, gboolean parity)
 
GSM_Error(* DeviceSetDtrRts )(GSM_StateMachine *s, gboolean dtr, gboolean rts)
 
GSM_Error(* DeviceSetSpeed )(GSM_StateMachine *s, int speed)
 
int(* ReadDevice )(GSM_StateMachine *s, void *buf, size_t nbytes)
 
int(* WriteDevice )(GSM_StateMachine *s, const void *buf, size_t nbytes)
 

Detailed Description

Device functions, each device has to provide these.

Definition at line 228 of file gsmstate.h.

Field Documentation

§ CloseDevice

GSM_Error(* GSM_Device_Functions::CloseDevice) (GSM_StateMachine *s)

Closes device.

Definition at line 236 of file gsmstate.h.

Referenced by GSM_CloseConnection().

§ DeviceSetDtrRts

GSM_Error(* GSM_Device_Functions::DeviceSetDtrRts) (GSM_StateMachine *s, gboolean dtr, gboolean rts)

Sets dtr (data to read) and rts (ready to send) flags.

Definition at line 244 of file gsmstate.h.

§ DeviceSetParity

GSM_Error(* GSM_Device_Functions::DeviceSetParity) (GSM_StateMachine *s, gboolean parity)

Sets parity for device.

Definition at line 240 of file gsmstate.h.

§ DeviceSetSpeed

GSM_Error(* GSM_Device_Functions::DeviceSetSpeed) (GSM_StateMachine *s, int speed)

Sets device speed.

Definition at line 248 of file gsmstate.h.

§ OpenDevice

GSM_Error(* GSM_Device_Functions::OpenDevice) (GSM_StateMachine *s)

Opens device.

Definition at line 232 of file gsmstate.h.

Referenced by GSM_OpenConnection().

§ ReadDevice

int(* GSM_Device_Functions::ReadDevice) (GSM_StateMachine *s, void *buf, size_t nbytes)

Attempts to read nbytes from device.

Definition at line 252 of file gsmstate.h.

Referenced by GSM_ReadDevice().

§ WriteDevice

int(* GSM_Device_Functions::WriteDevice) (GSM_StateMachine *s, const void *buf, size_t nbytes)

Attempts to read nbytes from device.

Definition at line 256 of file gsmstate.h.


The documentation for this struct was generated from the following file: