Random doesn't work.
Posted: Thu Jul 15, 2010 3:42 pm
Hello,
I have the following question:
- the random-function doesn't work in my program
- in the attachment (random.fcf) is a loop that waits for a press of switch SW0
- while the switch is not pressed a random number is generated (variable rnd)
- when the switch is pressed the variable rnd is displayd on the lcd-display
In the Supplementary Code i have set:
#include <rand.h>
The parameters in Linker: (Compiler Options)
-ld "C:\Program Files\Matrix Multimedia\Flowcode V4\BoostC\lib" libc.pic16.lib flowcode.pic16.lib float.pic16.lib rand.pic16.lib "%f.obj" -t PIC%p -d "%d" -p "%f"
I have the E-Blocks Multiprogrammer EB-006-00-7 with Flowcode4
My processor is PIC16F877a
Can somenone help me please!!
W. Tulp
I have the following question:
- the random-function doesn't work in my program
- in the attachment (random.fcf) is a loop that waits for a press of switch SW0
- while the switch is not pressed a random number is generated (variable rnd)
- when the switch is pressed the variable rnd is displayd on the lcd-display
In the Supplementary Code i have set:
#include <rand.h>
The parameters in Linker: (Compiler Options)
-ld "C:\Program Files\Matrix Multimedia\Flowcode V4\BoostC\lib" libc.pic16.lib flowcode.pic16.lib float.pic16.lib rand.pic16.lib "%f.obj" -t PIC%p -d "%d" -p "%f"
I have the E-Blocks Multiprogrammer EB-006-00-7 with Flowcode4
My processor is PIC16F877a
Can somenone help me please!!
W. Tulp