Jump to content

Steven

EstablishedMember
  • Content Count

    12
  • Joined

  • Last visited

Community Reputation

0 Neutral

About Steven

  • Rank
    Newbrie
  1. Thanks for the help. I think im going to attempt software SPI until i can figure out how to correctly setup the hardware spi as it is more efficient to use the hardware SPI. I have looked at different examples and most have a basic structure of a for loop and switching the right pins at the correct time. I was told that you have to read the data after the send even if your not going to do anything with it but from what I can tell the software SPI does not do this or at leaste im not seeing where it reads in the data. Also most statements take a variable say inputdata.7 im not sure exactly what this does?
  2. Does anyone know where I can get a good spi library or at leaste where to start with building a library? I have a PIC 16F88 and it does support hardware SPI but since I have moved to this compiler I have been unable to find one. My only other option is using software spi but the compiler seems to be having an issue with uns8 which i think is a data type that is used. Any help would be great.
  3. After much reading I think i have a better grasp of the concept. Thanks for the help. Also does the sourceBoost compiler have a spi.h header for the spi on the 16F pic's?
  4. I think i may have discovered my own solution by using the set_bit and clear_bit functions. Does the boost C compiler have a spi.h header file for using the hardware spi on the 16f pics?
  5. Header file #define nrf24l01_CE_IOREGISTER PORTB #define nrf24l01_CE_PINMASK 0x01 C file nrf24l01_CE_IOREGISTER &= ~nrf24l01_CE_PINMASK; I’m receiving the following compiler error: c(510): error: left operand must be l-value c(510:9): error: failed to generate expression I understand that this is because im trying to assign a value to a constant. Is there anyway around this???
  6. Steven

    Mplab Ide Error

    My code just seems to be working now I have absolutely no Idea why?
  7. Steven

    Mplab Ide Error

    It seems the error I got from your code came from a breech in the limitations so I commented out the #include <icd2.h> and the build was successful. The two projects look identical any Ideas on what could be different? Also I noticed your project doesn't include the libc.pic16.lib file is this necessary as stated in the documentation?
  8. Steven

    Mplab Ide Error

    Im still recieving the same error with the code you provided. Sorry about the #include in the wrong place I got in a hurry and posted before I caught the error. However the problem remains only the error I get with your code doesnt have the Couldn't find function/label by name:main. This is after a fresh install of MPLAB and source Boost. I attached the compiler output to this post. Also Im able to locate the test.cof file in the directory but its size is 0 KB.
  9. Steven

    Mplab Ide Error

    It turns out I didn't include an important Library and now my error has changed to the followning(after including the libray) Clean: Deleting intermediary and output files. Clean: Deleted file "C:\TestBoost\test1.HEX". Clean: Done. Executing: "C:\Program Files\SourceBoost\boostlink.pic.exe" "C:\Program Files\SourceBoost\Lib\libc.pic16.lib" -O1 -p "test1" -t 16F88 -ld "C:\Program Files\SourceBoost\Lib" BoostLink Optimizing Linker Version 6.91 http://www.sourceboost.com Copyright© 2004-2008 Pavel Baranov Copyright© 2004-2008 David Hobday Optimisation level:1 Couldn't find function/label by name:main failure BUILD SUCCEEDED: Fri Jan 16 11:57:09 2009 NEW CODE: #include <system.h> void main(){ #include <icd2.h> while( 1 ) { set_bit( portb, 0 ); // connect the led to port B, // bit 0 this is RB0 or pin33 // the led will turn on delay_ms( 250 ); clear_bit( portb, 0 ); // the led will turn off delay_ms( 250 ); // just wait for ¼ of a second } }
  10. Steven

    Mplab Ide Error

    Executing: "C:\Program Files\SourceBoost\boostlink.pic.exe" -O1 -p "test1" -t 16F88 -ld "C:\Program Files\SourceBoost\Lib" BoostLink Optimizing Linker Version 6.91 http://www.sourceboost.com Copyright© 2004-2008 Pavel Baranov Copyright© 2004-2008 David Hobday Optimisation level:1 Internal Error: Data Type not found id:0xF0000001: failure BUILD SUCCEEDED: Fri Jan 16 11:07:02 2009 I did a clean install of MPLAB and Source BOOST Here is my code: #include <system.h> void main( void ) { while( 1 ) { set_bit( portb, 0 ); // connect the led to port B, // bit 0 this is RB0 or pin33 // the led will turn on delay_ms( 250 ); // just wait for ¼ of a second clear_bit( portb, 0 ); // the led will turn off delay_ms( 250 ); // just wait for ¼ of a second } } Also here are my Project Paths Include Search Path C:\Program Files\SourceBoost\include Library Search Path C:\Program Files\SourceBoost\Lib The other Paths are BLANK. Thanks for the help.
  11. Steven

    Mplab Ide Error

    I will copy the output tonight when I get home. It seems as though the build is successful Its only one file with like 5 lines of code pretty much a blink test code document. I was wondering if I had something linked up incorrectly?
  12. I am new to sourceBoost and I installed Boost C and chose to integrate it with MPLAB IDE 8.10 I believe I have all the libraries and compiler hooked up correctly but I get this error Failed to load C:\test.COF and then it finishes... failure BUILD SUCCEEDED: Thu Jan 15 20:25:33 2009 Any Ideas?
×
×
  • Create New...