quickdev16.h 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. /*
  2. quickdev16.h - Quickdev16 support for uCON64
  3. Copyright (c) 2009 david@optixx.org
  4. This program is free software; you can redistribute it and/or modify
  5. it under the terms of the GNU General Public License as published by
  6. the Free Software Foundation; either version 2 of the License, or
  7. (at your option) any later version.
  8. This program is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. GNU General Public License for more details.
  12. You should have received a copy of the GNU General Public License
  13. along with this program; if not, write to the Free Software
  14. Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  15. */
  16. #ifndef SNESRAM_H
  17. #define SNESRAM_H
  18. #define USB_UPLOAD_INIT 0
  19. #define USB_UPLOAD_ADDR 1
  20. #define USB_DOWNLOAD_INIT 2
  21. #define USB_DOWNLOAD_ADDR 3
  22. #define USB_CRC 4
  23. #define USB_CRC_ADDR 5
  24. #define USB_BULK_UPLOAD_INIT 6
  25. #define USB_BULK_UPLOAD_ADDR 7
  26. #define USB_BULK_UPLOAD_NEXT 8
  27. #define USB_BULK_UPLOAD_END 9
  28. #define USB_MODE_SNES 10
  29. #define USB_MODE_AVR 11
  30. #define USB_AVR_RESET 12
  31. /* -------------------------- Device Description --------------------------- */
  32. #define USB_CFG_VENDOR_ID 0xc0, 0x16
  33. /* USB vendor ID for the device, low byte first. If you have registered your
  34. * own Vendor ID, define it here. Otherwise you use one of obdev's free shared
  35. * VID/PID pairs. Be sure to read USBID-License.txt for rules!
  36. */
  37. #define USB_CFG_DEVICE_ID 0xdd, 0x05
  38. /* This is the ID of the product, low byte first. It is interpreted in the
  39. * scope of the vendor ID. If you have registered your own VID with usb.org
  40. * or if you have licensed a PID from somebody else, define it here. Otherwise
  41. * you use obdev's free shared VID/PID pair. Be sure to read the rules in
  42. * USBID-License.txt!
  43. */
  44. #define USB_CFG_DEVICE_VERSION 0x00, 0x01
  45. /* Version number of the device: Minor number first, then major number.
  46. */
  47. #define USB_CFG_VENDOR_NAME 'o', 'p', 't', 'i', 'x', 'x', '.', 'o', 'r', 'g'
  48. #define USB_CFG_VENDOR_NAME_LEN 10
  49. /* These two values define the vendor name returned by the USB device. The name
  50. * must be given as a list of characters under single quotes. The characters
  51. * are interpreted as Unicode (UTF-16) entities.
  52. * If you don't want a vendor name string, undefine these macros.
  53. * ALWAYS define a vendor name containing your Internet domain name if you use
  54. * obdev's free shared VID/PID pair. See the file USBID-License.txt for
  55. * details.
  56. */
  57. #define USB_CFG_DEVICE_NAME 'Q', 'U', 'I', 'C', 'K', 'D', 'E', 'V', '1', '6'
  58. #define USB_CFG_DEVICE_NAME_LEN 10
  59. /* Same as above for the device name. If you don't want a device name, undefine
  60. * the macros. See the file USBID-License.txt before you assign a name if you
  61. * use a shared VID/PID.
  62. */
  63. extern const st_getopt2_t quickdev16_usage[];
  64. #ifdef USE_USB
  65. extern int quickdev16_write_rom (const char *filename);
  66. #endif
  67. #endif // SNESRAM_H