Jump to content
Sign in to follow this  
Badejavu

-Idx Num Command Line Error

Recommended Posts

Hi,

 

I use Boost C for PIC18 version 7.04 with a PIC18F67K22(128K FLASH, 4K SRAM).

 

Question:

1. Is it possible to declare an array of integers with and index of over 256?

e.g unsigned short Array[340];

 

2. I used -idx 2 command in the build options, to increase the array index limit and I still get an error.

 

Error: Array index size does not match linker '-idx' option. Expected:1 byte(s), while array index size of 2 byte(s) used in File: 'C:/Users/

 

Is there a way to use array index greater than 256?

 

Thanks

Bade

Share this post


Link to post
Share on other sites

Bade,

 

The error message tells you that the Linker needs the -idx2 option as well!

 

Also, probably wise to upgrade to V7.21.

 

Regards

 

davidb

Edited by davidb

Share this post


Link to post
Share on other sites

Thanks Davidb for your time.

 

As you suggested, I have upgraded to V7.21 and also included the -idx 2 command option for both the linker and the compiler options. It initially shows success, but comes up with numerous errors shortly after, I have pasted a few of the errors:

 

success

Executing: "C:\Program Files (x86)\SourceBoost721\SourceBoost\boostlink_picmicro.exe" "C:\Users\BAdegoke\Desktop\MXproj\Main.obj" "C:\Program Files (x86)\SourceBoost\Lib\libc.pic18.lib" "C:\Program Files (x86)\SourceBoost\Lib\float.pic18.lib" "C:\Program Files (x86)\SourceBoost\Lib\eeprom.pic18.lib" -O1 -p "Pd" -t 18F67K22 -idx 2
BoostLink Optimizing Linker Version 7.21
Copyright© 2004-2013 Pavel Baranov
Copyright© 2004-2013 David Hobday
Optimisation level:1
Error: Unresolved external function:'float32_mul(float,float)'
Error: Unresolved external function:'float32_mul(float,float)'
Error: Unresolved external function:'float32_mul(float,float)'
Error: Unresolved external function:'eeprom_read(unsigned char)'
Error: Unresolved external function:'eeprom_read(unsigned char)'
Error: Unresolved external function:'__div_32_32(unsigned long,unsigned long)'
failure
Link step failed.
BUILD FAILED: Tue Feb 18 11:20:27 2014
I use the "float.pic18.lib" and "eeprom.pic18.lib" in my project and it has not shown an error related to these libraries prior to now. The -idx 2 command has caused this. Any suggestions? What do I do now ?
Thanks
Bade

 

 

 

 

 

Share this post


Link to post
Share on other sites

Bade,

 

Use the required library files from the 'SourceBoost\Lib\large' folder rather than those in the 'SourceBoost\Lib' folder.

 

Unfortunately the documentation for the use of the various library files seems to be somewhat lacking.

 

Regards

 

davidb

Share this post


Link to post
Share on other sites

Your content will need to be approved by a moderator

Guest
You are commenting as a guest. If you have an account, please sign in.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoticons maximum are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×