Page 1 of 1

I need a help with the HID descriptor

Posted: 14 Oct 2010 17:36
by Mapache
Hi, First of all congratulations to mikroElektronika team for such a wonderful program they have done. Makes things much easier for PICmicro programming. But now I'm starting to use my 18F4550 USB module I had some problems, I compiled my own program and the examples that come with the program but all is bad. They already have the USB attached library and file descriptor USBdsc already added to the project as I saw in other messages. I have not changed the original example code, I just builded it. Attached is a screen capture to this message. I want to help me with this. I would appreciate very much.
Greetings from Lima, Peru.

The screenshot:
http://img826.imageshack.us/img826/2839/sinttulocy.jpg

Re: I need a help with the HID descriptor

Posted: 15 Oct 2010 12:56
by slavisa.zlatanovic
Hi!

I couldn't reproduce the issue you're talking about.
Everything worked OK!
I'm sending you the same project (compiled with no errors).
HID Read Write Interrupt.rar
(74.29 KiB) Downloaded 322 times
Please, recompile it and get back to me with results.

Re: I need a help with the HID descriptor

Posted: 15 Oct 2010 16:46
by Mapache
Thanks to the fast answer. I compiled your example and directly compile fine, but i change to my own descriptor (made with the HID Terminal) and it fall again with the same error. I didn´t know what I´m doing bad, but I´ll try another solutions. I tried the HID Terminal posted here (with the corrections of the size of strings) but the same. If I can find the solution I´ll post here. Thanks a lot for everything

Re: I need a help with the HID descriptor

Posted: 21 Oct 2010 08:28
by Acetronics
Real Problem ... :?
0 1 mBPic.exe -DBG -pP18F85J50 -MSF -Y -DL -O11111114 -fo48 -N"C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\Examples\Internal MCU modules\P18F85J50\HID Read Write Polling\HID_Read_Write_Polling.mbppi" -SP"C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\defs\" -SP"C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\uses\P18\" -SP"C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\Examples\Internal MCU modules\P18F85J50\HID Read Write Polling\" -SP"C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\Examples\Internal MCU modules\P18F85J50\" "__Lib_Math.mcl" "__Lib_MathDouble.mcl" "__Lib_System.mcl" "__Lib_Delays.mcl" "__Lib_USB_genHID_P18FJ.mcl" "HID_Read_Write_Polling.mbas" "USBdsc.mbas"
0 154 Available RAM: 3883 [bytes], Available ROM: 32760 [bytes]
0 132 Compilation Started C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\uses\P18\__Lib_Delays.mbas
1 1015 Hint: Compiling unit "C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\uses\P18\__Lib_Delays.mbas" __Lib_Delays.mbas
171 1010 Hint: Unit "__Lib_Delays.mbas" has been recompiled __Lib_Delays.mbas
0 133 Compiled Successfully C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\uses\P18\__Lib_Delays.mbas
0 132 Compilation Started C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\Examples\Internal MCU modules\P18F85J50\HID Read Write Polling\HID_Read_Write_Polling.mbas
1 1015 Hint: Compiling unit "C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\Examples\Internal MCU modules\P18F85J50\HID Read Write Polling\HID_Read_Write_Polling.mbas" HID_Read_Write_Polling.mbas
1 1015 Hint: Compiling unit "C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\Examples\Internal MCU modules\P18F85J50\HID Read Write Polling\USBdsc.mbas" USBdsc.mbas
161 1017 Warning: Aggregate padded with zeros (8) in order to match declared size (23) USBdsc.mbas
162 1017 Warning: Aggregate padded with zeros (8) in order to match declared size (25) USBdsc.mbas
173 1018 Warning: Suspicious pointer conversion USBdsc.mbas
174 301 "="is not valid identifier USBdsc.mbas
174 304 Syntax error: Expected "end" but "^" found USBdsc.mbas
174 304 Syntax error: Expected "sub" but "const" found USBdsc.mbas
174 304 Syntax error: Expected "end" but "char" found USBdsc.mbas
174 304 Syntax error: Expected "." but "(" found USBdsc.mbas
28 307 File "USBdsc.mcl" not found HID_Read_Write_Polling.mbas
0 102 Finished (with errors): 21 oct. 2010, 09:24:12 HID_Read_Write_Polling.mbppi
just loading the GENUINE V4.15 Demo examples for HID ...

system is Win XP SP3 ...

I remember having seen something about HID wrong size in the C Pro section ... :wink:

Alain

Re: I need a help with the HID descriptor

Posted: 21 Oct 2010 08:36
by p.erasmus
This is correct Alain
mE has 2 times forgotten to load the repaired HID Tool with the compiler release !!
the OP should use the HID in the stickeyx section of the Forum to generate the descriptor file;
as the HID tool in the Compiler generates incorrect string sizes and some other issues.

Re: I need a help with the HID descriptor

Posted: 21 Oct 2010 08:57
by Acetronics
Hi,P.

The problem is ...

I did the " corrected " Download ( from the given link ) AND Built a new Desc. file ... :roll:
Still same error ...

Also found errors in the new 16F1827 examples ( all are bugging )...
0 1 mBPic.exe -DBG -pP16F1937 -MSF -Y -DL -O11111114 -fo8 -N"C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\Examples\Internal MCU modules\P16F1937\Flash in MCU\Flash_test.mbppi" -SP"C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\defs\" -SP"C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\Uses\P16_Enh\" -SP"C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\Examples\Internal MCU modules\P16F1937\Flash in MCU\" -SP"C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\Examples\Internal MCU modules\P16F1937\" "__Lib_Math.mcl" "__Lib_MathDouble.mcl" "__Lib_System.mcl" "__Lib_Delays.mcl" "__Lib_FLASH_rwe.mcl" "Flash_test.mbas"
0 154 Available RAM: 508 [bytes], Available ROM: 8192 [bytes]
0 132 Compilation Started C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\Examples\Internal MCU modules\P16F1937\Flash in MCU\Flash_test.mbas
1 1015 Hint: Compiling unit "C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\Examples\Internal MCU modules\P16F1937\Flash in MCU\Flash_test.mbas" Flash_test.mbas
85 1010 Hint: Unit "Flash_test.mbas" has been recompiled Flash_test.mbas
0 133 Compiled Successfully C:\Program Files\Mikroelektronika\mikroBasic PRO for PIC\Examples\Internal MCU modules\P16F1937\Flash in MCU\Flash_test.mbas
0 138 All files Compiled in 90 ms
0 360 Unresolved extern 'FSR' __Lib_FLASH_RWE.mpas
0 360 Unresolved extern 'INDF' __Lib_FLASH_RWE.mpas
0 360 Unresolved extern 'EEDATA' __Lib_FLASH_RWE.mpas
0 360 Unresolved extern 'EEDATA' __Lib_FLASH_RWE.mpas

0 452 Unsuccessful linking 'Flash_test.mbppi' Unsuccessful linking 'Flash_test.mbppi'
0 102 Finished (with errors): 21 oct. 2010, 09:54:58 Flash_test.mbppi
But this might be another Thread ...

Alain

Re: I need a help with the HID descriptor

Posted: 21 Oct 2010 16:09
by Acetronics
Strange ...
:?:
I reinstalled the demo ...

no more error screen. What did corrupt the installation ??? ( I did not use it since upgrading to v4.15 ...)

Alain

Re: I need a help with the HID descriptor

Posted: 22 Oct 2010 07:51
by zristic
Acetronics wrote:Strange ...
:?:
I reinstalled the demo ...

no more error screen. What did corrupt the installation ??? ( I did not use it since upgrading to v4.15 ...)

Alain
probably the search paths, you should check them if you run multiple versions of compilers.