shuttleVFD: Add support for devices with USB VID 0x1308 again. This was lost
when support for newer devices was added.
This commit is contained in:
@@ -23,6 +23,7 @@ v.0.5dev (ongoing development)
|
|||||||
* server core: New network input buffering
|
* server core: New network input buffering
|
||||||
* hd44780: Extended subdriver API and performance improvement for lcd2usb
|
* hd44780: Extended subdriver API and performance improvement for lcd2usb
|
||||||
* hd44780: Add KOI8-R character mapping (Yura Scheglyuk)
|
* hd44780: Add KOI8-R character mapping (Yura Scheglyuk)
|
||||||
|
* shuttleVFD: Add support for devices with USB VID 0x1308 again
|
||||||
|
|
||||||
v0.5.3
|
v0.5.3
|
||||||
+ lcdexec: notification when called program finishes
|
+ lcdexec: notification when called program finishes
|
||||||
|
|||||||
@@ -4,17 +4,17 @@
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
* Copyright (C) 2007 Thien Vu
|
* Copyright (C) 2007 Thien Vu
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
* the Free Software Foundation; either version 2 of the License, or
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
* any later version.
|
* any later version.
|
||||||
*
|
*
|
||||||
* This program is distributed in the hope that it will be useful,
|
* This program is distributed in the hope that it will be useful,
|
||||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
* GNU General Public License for more details.
|
* GNU General Public License for more details.
|
||||||
*
|
*
|
||||||
* You should have received a copy of the GNU General Public License
|
* You should have received a copy of the GNU General Public License
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
|
||||||
@@ -139,7 +139,8 @@ MODULE_EXPORT int shuttleVFD_init(Driver *drvthis)
|
|||||||
for (bus = usb_get_busses(); bus != NULL; bus = bus->next) {
|
for (bus = usb_get_busses(); bus != NULL; bus = bus->next) {
|
||||||
struct usb_device *dev;
|
struct usb_device *dev;
|
||||||
for (dev = bus->devices; dev != NULL; dev = dev->next) {
|
for (dev = bus->devices; dev != NULL; dev = dev->next) {
|
||||||
if (dev->descriptor.idVendor == SHUTTLE_VFD_VENDOR_ID &&
|
if ((dev->descriptor.idVendor == SHUTTLE_VFD_VENDOR_ID1 ||
|
||||||
|
dev->descriptor.idVendor == SHUTTLE_VFD_VENDOR_ID2) &&
|
||||||
(dev->descriptor.idProduct == SHUTTLE_VFD_PRODUCT_ID1 ||
|
(dev->descriptor.idProduct == SHUTTLE_VFD_PRODUCT_ID1 ||
|
||||||
dev->descriptor.idProduct == SHUTTLE_VFD_PRODUCT_ID2)) {
|
dev->descriptor.idProduct == SHUTTLE_VFD_PRODUCT_ID2)) {
|
||||||
p->dev = usb_open(dev);
|
p->dev = usb_open(dev);
|
||||||
@@ -154,7 +155,7 @@ MODULE_EXPORT int shuttleVFD_init(Driver *drvthis)
|
|||||||
if (claim_rc < 0) {
|
if (claim_rc < 0) {
|
||||||
report(RPT_ERR,
|
report(RPT_ERR,
|
||||||
"%s: unable to claim interface: %s",
|
"%s: unable to claim interface: %s",
|
||||||
drvthis->name, strerror(claim_rc));
|
drvthis->name, strerror(claim_rc));
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -274,19 +275,19 @@ MODULE_EXPORT void shuttleVFD_flush(Driver *drvthis)
|
|||||||
packet[0] = 0x11;
|
packet[0] = 0x11;
|
||||||
packet[1] = 0x02;
|
packet[1] = 0x02;
|
||||||
send_packet(drvthis, packet);
|
send_packet(drvthis, packet);
|
||||||
|
|
||||||
// write framebuf[0-6]
|
// write framebuf[0-6]
|
||||||
memset(packet, '\0', SHUTTLE_VFD_PACKET_SIZE);
|
memset(packet, '\0', SHUTTLE_VFD_PACKET_SIZE);
|
||||||
packet[0] = 0x97;
|
packet[0] = 0x97;
|
||||||
strncpy(&packet[1], &p->framebuf[0], 7);
|
strncpy(&packet[1], &p->framebuf[0], 7);
|
||||||
send_packet(drvthis, packet);
|
send_packet(drvthis, packet);
|
||||||
|
|
||||||
// write framebuf[7-13]
|
// write framebuf[7-13]
|
||||||
memset(packet, '\0', SHUTTLE_VFD_PACKET_SIZE);
|
memset(packet, '\0', SHUTTLE_VFD_PACKET_SIZE);
|
||||||
packet[0] = 0x97;
|
packet[0] = 0x97;
|
||||||
strncpy(&packet[1], &p->framebuf[7], 7);
|
strncpy(&packet[1], &p->framebuf[7], 7);
|
||||||
send_packet(drvthis, packet);
|
send_packet(drvthis, packet);
|
||||||
|
|
||||||
// write framebuf[14-20]
|
// write framebuf[14-20]
|
||||||
memset(packet, '\0', SHUTTLE_VFD_PACKET_SIZE);
|
memset(packet, '\0', SHUTTLE_VFD_PACKET_SIZE);
|
||||||
packet[0] = 0x96;
|
packet[0] = 0x96;
|
||||||
|
|||||||
@@ -56,7 +56,8 @@ MODULE_EXPORT int shuttleVFD_cellheight(Driver *drvthis);
|
|||||||
#define SHUTTLE_VFD_CELLHEIGHT 8
|
#define SHUTTLE_VFD_CELLHEIGHT 8
|
||||||
|
|
||||||
// VFD USB properties
|
// VFD USB properties
|
||||||
#define SHUTTLE_VFD_VENDOR_ID 0x051c
|
#define SHUTTLE_VFD_VENDOR_ID1 0x1308
|
||||||
|
#define SHUTTLE_VFD_VENDOR_ID2 0x051c
|
||||||
#define SHUTTLE_VFD_PRODUCT_ID1 0x0003
|
#define SHUTTLE_VFD_PRODUCT_ID1 0x0003
|
||||||
// IR-receiver included in this model
|
// IR-receiver included in this model
|
||||||
#define SHUTTLE_VFD_PRODUCT_ID2 0x0005
|
#define SHUTTLE_VFD_PRODUCT_ID2 0x0005
|
||||||
|
|||||||
Reference in New Issue
Block a user