2

私はAm-1808を持っており、ここで説明されているように、sd カードではなく USB から起動する必要があります。以前は Davinci-PSP-SDK-03.21.00.4 を使用していましたが、この PSP の uboot は USB をサポートしていません (uboot メニューで「help」と入力してこれを確認しましたが、「usb」コマンドが使用できませんでした) )。そこで、u-bootメニューに「usb」コマンドがあるdenxツリーからu-bootをダウンロードし、Tiの従業員が提案したように、da850evm.hにusb構成を追加しました。構成は次のとおりです。

/*
 * USB configuration
 */
#define CONFIG_USB_DA8XX        /* Platform hookup to MUSB controller */
#define CONFIG_MUSB_UDC

#ifdef CONFIG_USB_DA8XX

#ifdef CONFIG_MUSB_HCD          /* include support for usb host */
#define CONFIG_CMD_USB          /* include support for usb cmd */

#define CONFIG_USB_STORAGE      /* MSC class support */
#define CONFIG_CMD_STORAGE      /* inclue support for usb-storage cmd */
#define CONFIG_CMD_FAT          /* inclue support for FAT/storage */
#define CONFIG_DOS_PARTITION    /* inclue support for FAT/storage */

#ifdef CONFIG_USB_KEYBOARD      /* HID class support */
#define CONFIG_SYS_USB_EVENT_POLL
#define CONFIG_PREBOOT "usb start"
#endif /* CONFIG_USB_KEYBOARD */

#endif /* CONFIG_MUSB_HCD */

#ifdef CONFIG_MUSB_UDC
/* USB device configuration */
#define CONFIG_USB_DEVICE               1
#define CONFIG_USB_TTY                  1
#define CONFIG_SYS_CONSOLE_IS_IN_ENV    1
/* Change these to suit your needs */
#define CONFIG_USBD_VENDORID            0x0451
#define CONFIG_USBD_PRODUCTID           0x5678
#define CONFIG_USBD_MANUFACTURER        "Texas Instruments"
#define CONFIG_USBD_PRODUCT_NAME        "DA830EVM"
#endif /* CONFIG_MUSB_UDC */

#endif /* CONFIG_USB_DA8XX */

コンパイルすると、次のエラーが発生します。

usbtty.c:126: error: 'EP0_MAX_PACKET_SIZE' undeclared here (not in a function)
usbtty.c:219: error: 'UDC_INT_ENDPOINT' undeclared here (not in a function)
usbtty.c:222: error: 'UDC_INT_PACKET_SIZE' undeclared here (not in a function)
usbtty.c:245: error: 'UDC_OUT_ENDPOINT' undeclared here (not in a function)
usbtty.c:249: error: 'UDC_BULK_PACKET_SIZE' undeclared here (not in a function)
usbtty.c:256: error: 'UDC_IN_ENDPOINT' undeclared here (not in a function)
usbtty.c:328: error: 'UDC_OUT_PACKET_SIZE' undeclared here (not in a function)
usbtty.c:338: error: 'UDC_IN_PACKET_SIZE' undeclared here (not in a function)
usbtty.c: In function 'usbtty_tstc':
usbtty.c:399: warning: implicit declaration of function 'udc_unset_nak'
usbtty.c: In function 'usbtty_getc':
usbtty.c:424: warning: implicit declaration of function 'udc_set_nak'
usbtty.c: In function 'drv_usbtty_init':
usbtty.c:553: warning: implicit declaration of function 'udc_init'
usbtty.c:560: warning: implicit declaration of function 'udc_startup_events'
usbtty.c:561: warning: implicit declaration of function 'udc_connect'
usbtty.c: In function 'usbtty_init_instances':
usbtty.c:683: warning: implicit declaration of function 'udc_setup_ep'
usbtty.c: In function 'write_buffer':
usbtty.c:846: warning: implicit declaration of function 'udc_endpoint_write'
usbtty.c: In function 'usbtty_poll':
usbtty.c:989: warning: implicit declaration of function 'udc_irq'
make[1]: *** [usbtty.o] Error 1
make[1]: Leaving directory `/home/user/Desktop/Uboot_Screwed/u-boot-    omapl1/drivers/serial'
make: *** [drivers/serial/libserial.a] Error 2

これらのエラーを取り除く方法を教えていただければ、[Google で検索しましたが、有用なものは見つかりませんでした] または、「usb」コマンドを持つ Am-1808 の u-boot のリンクを教えてください。 u-boot メニューでサポートされています。

アップデート:

auselenが指摘したように、da850evm.hでCONFIG_USB_TTYを定義しました。以前のエラーを解決できるようになりましたが、新しいエラーが発生しています。ターミナルの出力は次のとおりです。

drivers/serial/libserial.a(usbtty.o): In function `write_buffer':
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:846: undefined     reference to `udc_endpoint_write'
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:890: undefined reference to `udc_endpoint_write'
 drivers/serial/libserial.a(usbtty.o): In function `usbtty_poll':
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:989: undefined         reference to `udc_irq'
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:999: undefined reference to `udc_irq'
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:1009: undefined reference to `udc_irq'
drivers/serial/libserial.a(usbtty.o): In function `usbtty_init_endpoints':
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:727: undefined reference to `udc_setup_ep'
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:727: undefined reference to `udc_setup_ep'
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:727: undefined reference to `udc_setup_ep'
drivers/serial/libserial.a(usbtty.o): In function `drv_usbtty_init':
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:553: undefined reference to `udc_init'
drivers/serial/libserial.a(usbtty.o): In function `usbtty_init_instances':
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:683: undefined     reference to `udc_setup_ep'
drivers/serial/libserial.a(usbtty.o): In function `drv_usbtty_init':
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:560: undefined     reference to `udc_startup_events'
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:561: undefined     reference to `udc_connect'
drivers/serial/libserial.a(usbtty.o): In function `usbtty_tstc':
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:399: undefined     reference to `udc_unset_nak'
drivers/serial/libserial.a(usbtty.o): In function `usbtty_getc':
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:419: undefined     reference to `udc_unset_nak'
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/drivers/serial/usbtty.c:424: undefined reference to `udc_set_nak'
lib_arm/libarm.a(bootm.o): In function `do_bootm_linux':
/home/user/Desktop/Uboot_Screwed/u-boot-omapl1/lib_arm/bootm.c:122: undefined reference     to `udc_disconnect'

どうすれば修正できますか?

ありがとう

よろしく

うさま

4

1 に答える 1

1

を定義/有効にする必要があるようCONFIG_USB_TTYです。

于 2012-11-08T12:10:21.850 に答える