Jump to content

tom 2007

  • Posts

  • Joined

  • Last visited

Contact Methods

  • MSN

Profile Information

  • Gender

tom 2007's Achievements


Regular (2/6)



  1. Already tried that yesterday through build->clean and didn't solve the problem but today I deleted the files from the "Release" folder manually, then I did a recompile and it worked! Some source code files are in a sub directory in my project dir and it seems the IDE doesn't remove the .obj files for the .c that are in the subdirectory when you do build -> clean. Thanks for the help Tom
  2. Hi, I have installed Sourceboost 7.42 and ran preg.exe as administrator, entered my name and license key, clicked OK and it says: However when I click the build button in the IDE the linker always complains: What can be wrong? OS is Windows 10 64bit
  3. Says 7.12 on that page? Is that normal? Edit: nevermind it's updated now
  4. Yes I've noticed some of those things too. It took a while before I found the problem was in the compiler and not my code In the assembler it looks like this: SETF main_1_test MOVLW 0x20 MOVWF main_1_test+D'1' SETF main_1_test2 ;0x20FF = 8447 is loaded into test directly MOVLW 0x3F MOVWF main_1_test2+D'1' MOVF main_1_test2, W CPFSEQ main_1_test BRA label1 MOVF main_1_test2+D'1', W CPFSEQ main_1_test+D'1'
  5. Hello, Today I noticed some (what I think) strange behavior of the | operator: #define TEST_1 1 #define TEST_2 2 #define TEST_4 4 #define TEST_8 8 #define TEST_16 16 #define TEST_32 32 #define TEST_64 64 #define TEST_128 128 #define TEST_256 256 #define TEST_512 512 #define TEST_1024 1024 #define TEST_2048 2048 #define TEST_4096 4096 #define TEST_8192 8192 void main(){ unsigned int test; unsigned int test2; test = TEST_1 | TEST_2 | TEST_4 | TEST_8 | TEST_16 | TEST_32 | TEST_64 | TEST_128 | TEST_256 | TEST_512 | TEST_1024 | TEST_2048 | TEST_4096 | TEST_8192; test2 = TEST_1 + TEST_2 + TEST_4 + TEST_8 + TEST_16 + TEST_32 + TEST_64 + TEST_128 + TEST_256 + TEST_512 + TEST_1024 + TEST_2048 + TEST_4096 + TEST_8192; //test = 8447 //test2 = 16383 if (test == test2){ //... } } when splitting the test = TEST1 ... line to: test = TEST_1 | TEST_2 | TEST_4 | TEST_8 | TEST_16 | TEST_32; test = test | TEST_64 | TEST_128 | TEST_256 | TEST_512; test = test | TEST_1024 | TEST_2048 | TEST_4096 | TEST_8192; then test becomes equal to 16383 ... Compiler: boostc 7.12 (same problem under 7.10)
  6. ok i'll add a _ in the project directory
  7. How do I change that? The IDE will look for the postbuild.bat file in the project directory and execute. I don't see a way to tell the IDE to add double quotes.
  8. I've placed the postbuild.bat in the project directory but after linking i get:
  9. Is there a way to turn off the generation of the .tree file? I have a large project and the .tree file is +/- 800MB in size and this takes about 10min. to refresh in the IDE after a build . I don't use the call tree window that much so it would save a lot of time if there was a way to tell to the linker not to generate this file. Tom
  10. network_in_configmode() is a function that will check if an IP address was received from the DHCP server. Please connect your ENC28J60 to your router with an ethernet cable. If everything is configured properly your PIC should be able to get an IP address from the router (unless there is still something else wrong). If you don't know what DHCP,... is it's probably time you start to learn how TCP, UDP, IP, DHCP, HTTP, DNS,... work. http://en.wikipedia.org/wiki/Dynamic_Host_Configuration_Protocol
  11. When the timer overflows (0xFFFF + 1 -> 0x0000) the pic will automatically stop and go to the interrupt() function. Then it will execute the code in it (increment time elapsed etc...). After that it will return to what it was doing before the timer overflow or other interrupt (ADC, INT0,...).
  12. I think it could be a problem with your code in your interrupt routine. Can you check whats inside void interrupt(){}? Maybe the pic is stuck in this (try adding code that makes a led blink when it enters the interrupt). The rtc.c will enable the interrupt from some timer that is used for remembering the time. Did you try putting rcsta1.CREN=0 ? To disable the receiver. Another option is to start a new project with ONLY the sp.h/sp.c and try messing with that. If the len parameter is bigger than the size of the buffer it will continue to read from the buffer. It will end up somewhere in the ram memory where stuff from other variables is stored that's why it says ory.
  13. You can try to disable receive mode if you think it's causing problems (it's not used in sp.h / sp.c): rcsta.CREN=0; //receive disable If you want to read a received character use: unsigned char data; data = rcreg1; To check if data is waiting in the rcreg you can use pir1.RC1IF.
  14. What happens when you use the serial_send_data(unsigned char * data, unsigned char len) function: serial_send_data("SPI & SRAM INIT OK, Performing memory test\r\n",44 ) //where 44 is the number of characters in the string. Check if this will block the pic (if it does it must be a problem with the while (txsta.TRMT==0); or the "for loop" inside the serial_send_data() function).
  • Create New...