This is a simple example demonstrating how to enumerate and connect to a ScripTouch device.
#include <stdio.h>
int main() {
if(device != NULL) {
} else {
return 1;
}
} else {
printf("No devices found!\n");
return 2;
}
} else {
return 3;
}
}
This file contains the headers for the core of the Scriptel ScripTouch ProScript library.
void scriptel_init(void)
This function should be called prior to using any other library functions.
unsigned int scriptel_count_device_list(scriptel_device *list)
This function counts the number of devices in a given device list.
unsigned char * scriptel_get_device_uuid(scriptel_device *device)
This function returns the UUID of a device as a byte array.
scriptel_error_code scriptel_list_devices(scriptel_device **start)
This function takes a pointer and will attempt to enumerate any attached ScripTouch devices.
scriptel_error_code scriptel_close_device(scriptel_device *device)
This function attempts to close a local device that was previously opened.
scriptel_error_code scriptel_open_device(scriptel_device *device)
This function attempts to open a local device returned by scriptel_list_devices().
char * scriptel_get_last_error(void)
This function gets the last error message generated by the library.
void scriptel_free_device_list(scriptel_device *device_list)
This function crawls a scriptel_device list and attempts to free any library managed memory associate...
@ SCRIPTEL_CODE_SUCCESS
This code indicates that the function did succeed.
Definition: scriptel-proscript.h:96
void scriptel_print_device_uuid(unsigned char *uuid)
This function prints a UUID byte array to standard out.
This structure represents a physically attached Scriptel ScripTouch device.
Definition: scriptel-proscript.h:284
char * path
The path to the device.
Definition: scriptel-proscript.h:290
char * model
The textual name of the device as returned by the operating system's HID driver.
Definition: scriptel-proscript.h:305
char * manufacturer
The textual name of the manufacturer as returned by the operating system's HID driver.
Definition: scriptel-proscript.h:310