PIC 8-bit rapid prototype development boards...?

Howdy all, I recently took a class from Microchip learning to use their PIC24F 16- bit micros. I got the Explorer 16 development board and the ICD2 LE and got everything up and running with their MPLAB IDE v8.02 yadda, yadda. Everything is going very well, but I dont have any prior experience using more lowly 8-bit micros.

A friend of mine wants me to design and build a little controller unit to put inside of his remote control boat that will receive some of the servo signals from a couple of different receiver channels and be able to fire some rockets and trigger various aquatic peripherals. This seems to me like I should look to an 8 or 14 pin 8-bit solution and that a 100-pin 16-bit processor would be significant overkill (understatement).

I looked at the receiver servo signals on a scope and they are strange PWM type signals that vary in pulse width depending on what the transmitter/controller is doing (not sure if I should average them to DC and look at the DC level using an ADC or not). Anyway, it is my job to receive the various servo signals from the receiver and write a little program to have the micro control a couple of outputs to:

a) light a fuse on a bottlerocket b) send out pulses to trigger a paintball firing mechanism (fully- automatic or semi-automatic or one-shot). c) perhaps a few other tricks.

My question is this....

1) Will my new ICD2 LE work with lowly 8-pin and 14-pin PIC 8-bit micros in addition to the PIC24F 16-bit micros? 2) Although I have designed and build hundreds of my own PCBs in the past, this project doesnt really warrant a custom designed and built PCB...instead I would like to buy an "off the shelf" development board that will allow an 8-pin or 14-pin micro to be used to accept a couple of receiver servo pulse width inputs and actuate a couple of output transistor/driver circuits for US$20-40ish.

Sure I could design my own PCB, but I would like to keep my actual design time limited to a couple of hours tinkering with the code instead of spinning a PCB, specing and ordering parts, etc.

Any suggestions on quick deployment general purpose PIC development kits for such an application? I found this...

formatting link
It looks like the best so far for $30 or so with the PCB and all parts.

I also saw this, but would require more tinkering for the output stages...

formatting link
formatting link

Thx for any input. respectfully, frenchy

Reply to
frenchy
Loading thread data ...

Welcome to the world of mocrocontrollers.

Good idea.

This may help:

formatting link

There are many solutions to this problem.

The micro counting the pulse width of at least two servos pulses, at the maximum of both pulses can trigger an output to trigger the "gun"

Yes

Any vector plug board and point to point soldering.

Good luck

Please post some pics on your favorite pics site, or utube a video.

donald

Reply to
donald

You should measure the pulse width, which should be between 1000 and

2000 usec, roughly.

Yes, although you should probably stick with ones that allow you to dedicate the programming pins, so 16 or 18 pins might be more appropriate.

Best regards, Spehro Pefhany

--
"it\'s the network..."                          "The Journey is the reward"
speff@interlog.com             Info for manufacturers: http://www.trexon.com
Embedded software/hardware/analog  Info for designers:  http://www.speff.com
Reply to
Spehro Pefhany

The ICD2 should program any PIC supporting ICSP. Many low end PICs don't have in circuit debug, or only have it special packages with extra pins used on ICD adapters.

You would need to use a Microchip AC162053 adapter (about $35) to get ICD on a 16F628A design for example.

If you want to write in C the device support offered by the limited free compilers bundled with MPLAB would also be a consideration.

For a one/few off the cost difference between a low end PIC24 and a PIC16 is trivial, you can get small ones in 28 pin DIL.

Reply to
nospam

Donald wrote: > This may help:

formatting link
servos.html Frenchy responds: This did help, thank you!! We are using a Futaba set-up that looks very similar to that shown in the picture. Transmitter = Futaba FG series Receiver = FP-R7H

Donald wrote: > The micro counting the pulse width of at least two servos pulses,

Frenchy responds: When picking the micro (my first 8-bit project), if I want to count the pulse width of three servo intputs (for 3 different output functions), does that mean that I need three separate

8-bit timers? I am going to research the "counting width" method now. Thank you.

thx, frenchy

Reply to
frenchy

As I stated earlier, there are many ways to do this.

One way:

Set an interrupt to trigger on 100 uSec interrupts. At each interrupt test the three bits and count a variable up if the bit is high, zero that variable if the bit is low.

Outside the interrupt, test the three variables for a maximum value:

2mSec / 100uSec = 20.

Anything above say 18 is maximum. So two variables above 18 will set another variable, and trigger the "gun".

On the remote control, pushing two axis to the maximum for only an instant, will trigger the "gun".

Good luck

donald

Reply to
donald

Aha, I thought those adapters were just to interface with that stupid proprietary phone jack....but now I see that they are for use with devices that dont have debug functionality built-in....very strange.

Great advice! I guess since I already have the C30 compiler set-up and working, I should just get the lowest pin-count PIC24F that is supported by my compiler. I didnt realize they went down to 28-pin in a dip package. Nice. I just noticed, however, that they are all 2.0 to 3.6vdc devices. I already have a 5vdc regulator in the system that I was going to tap onto for power. I guess I can add another 3.3v regulator running off from the existing 5v regulator (not too much wasted power to drain the batteries). The input Servo pulses coming from the Futaba receiver dont matter if they go above the 3.3v rail as long as I have 10k series resistors in-line to limit the injection current. Also, the output NPN transistors dont care if their bases are driven by 3.3v as long as the emitters are tied to GND and I have resistors in the base right?

thx, frenchy

Reply to
frenchy

Donald, Thanks again for answering my elementary questions. Is there any advantage to using the input capture peripheral (Five 16-Bit Capture Inputs) when counting the length of these servo inputs? thx, frenchy

Reply to
frenchy

On Wed, 05 Mar 2008 10:02:20 -0800, frenchy wrote: ...

My first impulse would be to just use mechanical servos, like they use for the throttle and rudder, and have the arm hit a switch contact. See rec.pyrotechnics for squibs and stuff. :-)

If your unit has any simple "on-off" type channels, that would simplify things immensely. Can you post some specs on it?

Otherwise, you'll have to "decode" the pulse width; it varies from something like "very narrow" to "about 20% duty cycle" depending on the position of the joystick. Unfortunately I don't know how a receiver distinguished between channels; AFAIK they're decoded (which is which, that is) in the receiver and the pulse train is sent to the servo.

Good Luck! Rich

Reply to
Rich Grise

That is debatable. Microchip's messages are mixed, you can find them telling you series resistors to limit clamp diode current are ok for interfacing 5v to 3v and somewhere else they will tell you any clamp diode current means the device may be operating within maximum ratings but outside specification. It is not hard to imagine substrate currents affecting switching thresholds and analog functions but no one seems to have a clue about how much current might have how much affect.

PIC24F pins with no analog function are 5v tolerant, I don't know if the small parts have any pins without an analog function.

If you have well defined 5v signals from the receiver I think I would 'spend' another resistor and tap them down to 3.3 with a voltage divider.

Reply to
nospam

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.