1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-06 22:51:41 +00:00
freebsd-ports/graphics/dc20pack/files/patch-aa
Chris Piazza 0b530eecbb Import of dc20pack.
Dc20pack can control a Kodak DC20/25 digital camera via the embedded
serial port.  Pictures are initially downloaded in the camera's native format
but can be converted to targa format.

Note that I did not test this personally as I don't own a DC20/25 :).
The submitter says that it works, though.

PR:		12909
Submitted by:	Maurice Castro <maurice@serc.rmit.edu.au>
1999-09-09 01:43:30 +00:00

45 lines
1.3 KiB
Plaintext

*** dc20_hif.c.orig Sun Aug 1 13:55:41 1999
--- dc20_hif.c Sun Aug 1 13:57:21 1999
***************
*** 15,21 ****
unsigned char sts_res= 0, sts_bat= 0;
unsigned char sts_pic_cnt= 0, sts_pic_rem= 0;
unsigned char dc_type= 0x25;
! unsigned char com_dev[128]= "/dev/ttyS0";
/* LOCAL VARIABLES ****************************************/
--- 15,21 ----
unsigned char sts_res= 0, sts_bat= 0;
unsigned char sts_pic_cnt= 0, sts_pic_rem= 0;
unsigned char dc_type= 0x25;
! unsigned char com_dev[128]= "/dev/cuaa0";
/* LOCAL VARIABLES ****************************************/
***************
*** 146,156 ****
{
switch (com_nr)
{
! case 1: strcpy(com_dev, "/dev/ttyS0") ; break;
! case 2: strcpy(com_dev, "/dev/ttyS1") ; break;
! case 3: strcpy(com_dev, "/dev/ttyS2") ; break;
! case 4: strcpy(com_dev, "/dev/ttyS3") ; break;
! default: strcpy(com_dev, "/dev/ttyS0") ; break;
}
if ((com_hdl = open(com_dev, O_RDWR)) == -1)
--- 146,156 ----
{
switch (com_nr)
{
! case 1: strcpy(com_dev, "/dev/cuaa0") ; break;
! case 2: strcpy(com_dev, "/dev/cuaa1") ; break;
! case 3: strcpy(com_dev, "/dev/cuaa2") ; break;
! case 4: strcpy(com_dev, "/dev/cuaa3") ; break;
! default: strcpy(com_dev, "/dev/cuaa0") ; break;
}
if ((com_hdl = open(com_dev, O_RDWR)) == -1)