If you have not looked at AND REJECTED the instant interupts that is made by DT (DT´s instant interupts) you should really look into that now.
It is a way to solve all problems without even knowing how to spell to ASM.
/me
If you have not looked at AND REJECTED the instant interupts that is made by DT (DT´s instant interupts) you should really look into that now.
It is a way to solve all problems without even knowing how to spell to ASM.
/me
Hi, Jumper
DT Basic Interrupts are wayyy too slow, here ... and overall their execution time is not predictable for timing corrections ...
so, no joy nor !
You do have to deal with ASM ... or write the program in pure PBP, without any interrupts ...
Alain
PS: and do not forget DT Bas ints consume a lot of RAM ...
@ BB
I alredy built a 4 channels fail-safe in pure PBP ... 4 Channels to read and 4 channels to output ... so, your project looks quite doable.Does this mean there's another way of doing this without interrupts?
Bear in mind that I need to expand this to running two servos at once.
Writing a neat timechart ... of course.
Last edited by Acetronics2; - 25th March 2010 at 10:33.
************************************************** ***********************
Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
************************************************** ***********************
IF there is the word "Problem" in your question ...
certainly the answer is " RTFM " or " RTFDataSheet " !!!
*****************************************
alright Ace, I give in, you've got me in dispair with this project, I'll look for a totally different way.
Is this something you've released that I can learn from or even adapt?I alredy built a 4 channels fail-safe in pure PBP ... 4 Channels to read and 4 channels to output ... so, your project looks quite doable.
Writing a neat timechart ... of course.
If I can't see the code, can you give me some hints about the way forward?
I don't mind all the time charts in the world, but what's it for?
I'll stop bothering you now, time for bed.
Either way, thanks for the help, it's good to know when the idea you've got is impossible, that way you can move on; even if it is disheartening. Sniff...
I'll check out DT's interrupts anyway - always learning.
Ok BB
First of all ...
explain with clear words what your device has to do :
from which inputs (w/ details ) to which outputs ( w/details ) ...
50% of the work is here ...
Alain
PS: and stop thinking " C " ... you must think " Basic " now ! ( ROFL)
************************************************** ***********************
Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
************************************************** ***********************
IF there is the word "Problem" in your question ...
certainly the answer is " RTFM " or " RTFDataSheet " !!!
*****************************************
Too Slow???
For a Servo??? Get real.
I've run 16 servo's simultaneously with DT_INTS.
Timing not predictable??? What???
It's extremely predictable. What are you talking about?
oooo, ~50 bytes to have super easy interrupts, yeah too much RAM.PS: and do not forget DT Bas ints consume a lot of RAM ...
Don't listen to Alain.Originally Posted by bison_bloke
He's just being obstinate.
DT
Does this mean there's code out there that I can directly adapt?I've run 16 servo's simultaneously with DT_INTS.
Where would I find this?
I have two inputs: start/stop button and a 'selector switch' which I already have working with that if statement you see above.explain with clear words what your device has to do :
from which inputs (w/ details ) to which outputs ( w/details ) ...
I have three outputs: two servos that I need to 'bounce' independently of each other. I need them to simulate the somewhat random movements that a passenger in a car would experience whilst driving. The third input is for vibration, this is just an unbalanced DC motor - np.
I also want to run a countdown timer so that it gets turned of after 20mins.
So now that my project is exactly half done50% of the work is here ..., which way do I head?
Well, that program is extensive ... each channel has it's own Center Trim, Gain and 10-bit positions, with stored programmed movements.
Never released it. Because I'd have to support it.
But since you don't seem to mind ON INTERRUPT ... there's a sample at meLabs for the LAB-X1 board.
It drives 2 servos using interrupts.
Has buttons, an LCD ... sounds just like what you wanted.
servosx.bas
http://melabs.com/resources/samples.htm
<br>
DT
Hi, BB
Just missing : is both servos position given by a unique " selector pot " ( 6 positions , if I have correctly understood ) , so both servos receive same driving pulse ???
Alain
For the Heading ...
I'd propose you a " system clock " @ 50 Hz ... with a timer interrupt ( very, very simple kind of interrupt ). And as 20 mins = 60000 " ticks " @ 50 Hz ... it's done
If you think to it, tasks are done in a linear way and the whole sequence is repeated @ 50 Hz ...
so, just let me an hour to open the '690 Datasheet ( never worked with this chip to the day ) ...
Last edited by Acetronics2; - 26th March 2010 at 08:28.
************************************************** ***********************
Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
************************************************** ***********************
IF there is the word "Problem" in your question ...
certainly the answer is " RTFM " or " RTFDataSheet " !!!
*****************************************
Both servos will run on different signals. There will be no pots involved.
The user selects a 'program' from the selector switch, hit's start, and a predefined program controls everything from there. The servos will almost always be in different positions to each other.
Hi,
Have a look to your PMs ... and enjoy
@ Darrel : Do not look at it ... you won't like at all ...
Alain
************************************************** ***********************
Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
************************************************** ***********************
IF there is the word "Problem" in your question ...
certainly the answer is " RTFM " or " RTFDataSheet " !!!
*****************************************
Bookmarks