Microchip-MPLAB-Harmony / usb

Harmony 3 USB library
https://onlinedocs.microchip.com/v2/keyword-lookup?keyword=MH3_usb&redirect=true
Other
12 stars 7 forks source link

USB Host Hub Generated Code Doesn't Build #4

Open nitz opened 4 years ago

nitz commented 4 years ago

Please disregard the first edit of this ticket, as I was barking up the completely wrong tree. Following the USB Host tutorial, I'm able to build after generating code from Harmony. However, upon heading back into the configurator, and enabling hub support, the generated code fails to build, with undefined symbols. (Output below)

As well, adding a HID client driver, and enabling mouse and keyboard driver checkboxes causes build errors too. (This seems to be because the number of TPL entries is a read-only field in the configurator, based on the number of client drivers I have. Trying to enable both HID Keyboard and HID mouse adds two entries, which will cause the array to always be 1 larger than it's sized for. Playing around with it, I was actually able to get the entry number to go to 0, despite still having a client, so the generated code was always bad until I removed and re-added the Host Layer component) I can open a separate issue for that, if it's not just the case of me doing something wrong! 🙂

My build output looks like:

CLEAN SUCCESSFUL (total time: 11ms)
make -f nbproject/Makefile-default.mk SUBPROJECTS= .build-conf
make[1]: Entering directory 'Y:/Users/cmd/Hardware/UsbTest/UsbHostTest/firmware/UsbHostTest.X'
make  -f nbproject/Makefile-default.mk dist/default/production/UsbHostTest.X.production.hex
make[2]: Entering directory 'Y:/Users/cmd/Hardware/UsbTest/UsbHostTest/firmware/UsbHostTest.X'
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/1171490990/usb_host_init_data.o.d" -o build/default/production/_ext/1171490990/usb_host_init_data.o ../src/config/default/usb_host_init_data.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/308758920/usb_host.o.d" -o build/default/production/_ext/308758920/usb_host.o ../src/config/default/usb/src/usb_host.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/308758920/usb_host_hub.o.d" -o build/default/production/_ext/308758920/usb_host_hub.o ../src/config/default/usb/src/usb_host_hub.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/1434821282/bsp.o.d" -o build/default/production/_ext/1434821282/bsp.o ../src/config/default/bsp/bsp.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/308758920/usb_host_msd.o.d" -o build/default/production/_ext/308758920/usb_host_msd.o ../src/config/default/usb/src/usb_host_msd.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/308758920/usb_host_scsi.o.d" -o build/default/production/_ext/308758920/usb_host_scsi.o ../src/config/default/usb/src/usb_host_scsi.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/60181895/plib_tmr2.o.d" -o build/default/production/_ext/60181895/plib_tmr2.o ../src/config/default/peripheral/tmr/plib_tmr2.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/1269487135/sys_fs.o.d" -o build/default/production/_ext/1269487135/sys_fs.o ../src/config/default/system/fs/src/sys_fs.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/1269487135/sys_fs_media_manager.o.d" -o build/default/production/_ext/1269487135/sys_fs_media_manager.o ../src/config/default/system/fs/src/sys_fs_media_manager.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/1269487135/sys_fs_fat_interface.o.d" -o build/default/production/_ext/1269487135/sys_fs_fat_interface.o ../src/config/default/system/fs/src/sys_fs_fat_interface.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/411819097/ff.o.d" -o build/default/production/_ext/411819097/ff.o ../src/config/default/system/fs/fat_fs/file_system/ff.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/411819097/ffunicode.o.d" -o build/default/production/_ext/411819097/ffunicode.o ../src/config/default/system/fs/fat_fs/file_system/ffunicode.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/565198302/diskio.o.d" -o build/default/production/_ext/565198302/diskio.o ../src/config/default/system/fs/fat_fs/hardware_access/diskio.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/1171490990/initialization.o.d" -o build/default/production/_ext/1171490990/initialization.o ../src/config/default/initialization.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/1360937237/main.o.d" -o build/default/production/_ext/1360937237/main.o ../src/main.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/1171490990/interrupts.o.d" -o build/default/production/_ext/1171490990/interrupts.o ../src/config/default/interrupts.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/1171490990/exceptions.o.d" -o build/default/production/_ext/1171490990/exceptions.o ../src/config/default/exceptions.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/163028504/xc32_monitor.o.d" -o build/default/production/_ext/163028504/xc32_monitor.o ../src/config/default/stdio/xc32_monitor.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/60165520/plib_clk.o.d" -o build/default/production/_ext/60165520/plib_clk.o ../src/config/default/peripheral/clk/plib_clk.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/2128569739/drv_usbfs.o.d" -o build/default/production/_ext/2128569739/drv_usbfs.o ../src/config/default/driver/usb/usbfs/src/drv_usbfs.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/1865254177/plib_gpio.o.d" -o build/default/production/_ext/1865254177/plib_gpio.o ../src/config/default/peripheral/gpio/plib_gpio.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/2128569739/drv_usbfs_host.o.d" -o build/default/production/_ext/2128569739/drv_usbfs_host.o ../src/config/default/driver/usb/usbfs/src/drv_usbfs_host.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/1865200349/plib_evic.o.d" -o build/default/production/_ext/1865200349/plib_evic.o ../src/config/default/peripheral/evic/plib_evic.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/1360937237/app.o.d" -o build/default/production/_ext/1360937237/app.o ../src/app.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/1171490990/tasks.o.d" -o build/default/production/_ext/1171490990/tasks.o ../src/config/default/tasks.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/101884895/sys_time.o.d" -o build/default/production/_ext/101884895/sys_time.o ../src/config/default/system/time/src/sys_time.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  
"C:\Program Files\Microchip\xc32\v2.41\bin\xc32-gcc.exe"    -g -x c -c -mprocessor=32MX470F512L  -ffunction-sections -O1 -I"../src/config/default/system/fs/fat_fs/file_system" -I"../src/config/default/system/fs/fat_fs/hardware_access" -I"../src" -I"../src/config/default" -I"../src/packs/PIC32MX470F512L_DFP" -Werror -Wall -MMD -MF "build/default/production/_ext/1881668453/sys_int.o.d" -o build/default/production/_ext/1881668453/sys_int.o ../src/config/default/system/int/src/sys_int.c    -DXPRJ_default=default  -no-legacy-libc    -mdfp="C:/Program Files (x86)/Microchip/MPLABX/v5.40/packs/Microchip/PIC32MX_DFP/1.3.231"  

In file included from ../src/config/default/definitions.h:53:0,
                 from ../src/config/default/usb_host_init_data.c:39:
../src/config/default/usb/usb_host_hub.h:76:21: error: unknown type name 'USB_HOST_CLIENT_DRIVER'
 /*DOM-IGNORE-BEGIN*/extern USB_HOST_CLIENT_DRIVER gUSBHostHUBClientDriver; /*DOM-IGNORE-END*/
                     ^
In file included from ../src/config/default/definitions.h:53:0,
                 from ../src/main.c:28:
../src/config/default/usb/usb_host_hub.h:76:21: error: unknown type name 'USB_HOST_CLIENT_DRIVER'
 /*DOM-IGNORE-BEGIN*/extern USB_HOST_CLIENT_DRIVER gUSBHostHUBClientDriver; /*DOM-IGNORE-END*/
                     ^
In file included from ../src/config/default/definitions.h:53:0,
                 from ../src/config/default/initialization.c:47:
../src/config/default/usb/usb_host_hub.h:76:21: error: unknown type name 'USB_HOST_CLIENT_DRIVER'
 /*DOM-IGNORE-BEGIN*/extern USB_HOST_CLIENT_DRIVER gUSBHostHUBClientDriver; /*DOM-IGNORE-END*/
                     ^
nbproject/Makefile-default.mk:301: recipe for target 'build/default/production/_ext/1171490990/usb_host_init_data.o' failed
nbproject/Makefile-default.mk:392: recipe for target 'build/default/production/_ext/1360937237/main.o' failed
make[2]: *** [build/default/production/_ext/1171490990/usb_host_init_data.o] Error 255
make[2]: *** Waiting for unfinished jobs....
In file included from ../src/config/default/usb/src/usb_host_hub.c:54:0:
../src/config/default/usb/src/usb_host_hub_local.h:243:5: error: unknown type name 'SYS_TMR_HANDLE'
     SYS_TMR_HANDLE timerHandle;
     ^
../src/config/default/usb/src/usb_host_hub.c: In function '_USB_HOST_HUB_DeviceAssign':
../src/config/default/usb/src/usb_host_hub.c:309:37: error: 'SYS_TMR_HANDLE_INVALID' undeclared (first use in this function)
             portInfo->timerHandle = SYS_TMR_HANDLE_INVALID;
                                     ^
../src/config/default/usb/src/usb_host_hub.c:309:37: note: each undeclared identifier is reported only once for each function it appears in
../src/config/default/usb/src/usb_host_hub.c: In function '_USB_HOST_HUB_PortTasks':
../src/config/default/usb/src/usb_host_hub.c:1092:13: error: pointer targets in passing argument 2 of 'SYS_TIME_DelayMS' differ in signedness [-Werror=pointer-sign]
             SYS_TIME_DelayMS(2 * hubInstance->hubDescriptor.bPwrOn2PwrGood , &portInfo->timerHandle  );
             ^
In file included from ../src/config/default/definitions.h:72:0,
                 from ../src/config/default/driver/usb/drv_usb_external_dependencies.h:48,
                 from ../src/config/default/usb/src/usb_host_hub_local.h:53,
                 from ../src/config/default/usb/src/usb_host_hub.c:54:
../src/config/default/system/time/sys_time.h:494:17: note: expected 'SYS_TIME_HANDLE *' but argument is of type 'int *'
 SYS_TIME_RESULT SYS_TIME_DelayMS ( uint32_t ms, SYS_TIME_HANDLE* handle );
                 ^
../src/config/default/usb/src/usb_host_hub.c:1093:17: error: 'SYS_TMR_HANDLE_INVALID' undeclared (first use in this function)
             if( SYS_TMR_HANDLE_INVALID != portInfo->timerHandle )
                 ^
make[2]: *** [build/default/production/_ext/1360937237/main.o] Error 255
nbproject/Makefile-default.mk:315: recipe for target 'build/default/production/_ext/308758920/usb_host_hub.o' failed
nbproject/Makefile-default.mk:399: recipe for target 'build/default/production/_ext/1171490990/initialization.o' failed
cc1.exe: all warnings being treated as errors
make[2]: *** [build/default/production/_ext/308758920/usb_host_hub.o] Error 255
In file included from ../src/config/default/definitions.h:53:0,
                 from ../src/config/default/tasks.c:54:
../src/config/default/usb/usb_host_hub.h:76:21: error: unknown type name 'USB_HOST_CLIENT_DRIVER'
 /*DOM-IGNORE-BEGIN*/extern USB_HOST_CLIENT_DRIVER gUSBHostHUBClientDriver; /*DOM-IGNORE-END*/
                     ^
In file included from ../src/config/default/definitions.h:53:0,
                 from ../src/config/default/interrupts.c:53:
../src/config/default/usb/usb_host_hub.h:76:21: error: unknown type name 'USB_HOST_CLIENT_DRIVER'
 /*DOM-IGNORE-BEGIN*/extern USB_HOST_CLIENT_DRIVER gUSBHostHUBClientDriver; /*DOM-IGNORE-END*/
                     ^
make[2]: *** [build/default/production/_ext/1171490990/initialization.o] Error 255
In file included from ../src/config/default/definitions.h:53:0,
                 from ../src/config/default/exceptions.c:50:
../src/config/default/usb/usb_host_hub.h:76:21: error: unknown type name 'USB_HOST_CLIENT_DRIVER'
 /*DOM-IGNORE-BEGIN*/extern USB_HOST_CLIENT_DRIVER gUSBHostHUBClientDriver; /*DOM-IGNORE-END*/
                     ^
In file included from ../src/config/default/definitions.h:53:0,
                 from ../src/config/default/driver/usb/drv_usb_external_dependencies.h:48,
                 from ../src/config/default/driver/usb/usbfs/src/drv_usbfs_local.h:57,
                 from ../src/config/default/driver/usb/usbfs/src/drv_usbfs.c:53:
../src/config/default/usb/usb_host_hub.h:76:21: error: unknown type name 'USB_HOST_CLIENT_DRIVER'
 /*DOM-IGNORE-BEGIN*/extern USB_HOST_CLIENT_DRIVER gUSBHostHUBClientDriver; /*DOM-IGNORE-END*/
                     ^
nbproject/Makefile-default.mk:476: recipe for target 'build/default/production/_ext/1171490990/tasks.o' failed
nbproject/Makefile-default.mk:406: recipe for target 'build/default/production/_ext/1171490990/interrupts.o' failed
make[2]: *** [build/default/production/_ext/1171490990/tasks.o] Error 255
make[2]: *** [build/default/production/_ext/1171490990/interrupts.o] Error 255
nbproject/Makefile-default.mk:413: recipe for target 'build/default/production/_ext/1171490990/exceptions.o' failed
nbproject/Makefile-default.mk:448: recipe for target 'build/default/production/_ext/2128569739/drv_usbfs.o' failed
make[2]: *** [build/default/production/_ext/1171490990/exceptions.o] Error 255
make[2]: *** [build/default/production/_ext/2128569739/drv_usbfs.o] Error 255
make[2]: Leaving directory 'Y:/Users/cmd/Hardware/UsbTest/UsbHostTest/firmware/UsbHostTest.X'
nbproject/Makefile-default.mk:91: recipe for target '.build-conf' failed
make[1]: Leaving directory 'Y:/Users/cmd/Hardware/UsbTest/UsbHostTest/firmware/UsbHostTest.X'
nbproject/Makefile-impl.mk:39: recipe for target '.build-impl' failed
make[1]: *** [.build-conf] Error 2
make: *** [.build-impl] Error 2

BUILD FAILED (exit value 2, total time: 1s)
sunil-fernandes commented 4 years ago

Hello

Good to know that the you got the USB tutorial working for you. About the latest, are you trying to create an application that support a keyboard device and mouse device through a hub?

Sunil

nitz commented 4 years ago

Hi Sunil!

That is in fact my goal. Eventually I plan to support a range of device types including MSD and CDCs, but targeting a mouse and keyboard through a hub (Since they share descriptor types and would just need different drivers) seemed like a good first step.

I’ve got the feeling that I’m certainly missing something, but can’t seem to find exactly what I’ve not provided to make the code generation happy. (Plus, the “help” window of the MHC has been blank since I’ve installed it, so I’m driving blind a bit with what I can’t find googling.)

sunil-fernandes commented 4 years ago

Please standby. I will revert shortly on this.

nitz commented 4 years ago

Will do, I'm in no rush. Thanks for taking a look at it, Sunil!

nitz commented 4 years ago

Hi @sunil-fernandes -- Just checking if you'd had a chance to look at this. Thanks again!