choice of pic

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 4.
To post in this forum you must have a registered copy of Flowcode 4 or higher. To sign up for this forum topic please use the "Online Resources" link in the Flowcode Help Menu.

Moderator: Benj

Post Reply
frankmortensen
Posts: 24
Joined: Wed Feb 17, 2010 12:27 pm
Location: Danmark Fyn
Been thanked: 1 time

choice of pic

Post by frankmortensen »

How can I know which pic I can use with various components of the flow code, I will use the component servo and I know that it works with a pic16f877 but not with a 16f88.
how can I tell which features a pic to be had (timer PWM, etc.) to work with a component

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: choice of pic

Post by Benj »

Hello

Ok here is a list of hardware peripherals used by the components. Please note that this is PIC based only.

Servo - Timer2 + 2 CCP modules
PWM - Timer1
Webserver / TCP - I2C master
ADC - ADC hardware
SPI_Legacy / CAN / CAN2 - SPI
IrDA / RFID / Bluetooth / Zigbee / GPS - UART
USB components - USB hardware
EEPROM - EEPROM hardware

The other components are generally bit banged or provide a hardware option eg RS232, FAT and I2C.

RS232 - UART
FAT - SPI
I2C - I2C Master

The only other restriction is the Speech component which will only compile on an 18F device.

User avatar
rene
Posts: 56
Joined: Sun Sep 13, 2009 11:27 am
Location: Dordrecht - Nederland
Has thanked: 5 times
Been thanked: 2 times

Re: choice of pic

Post by rene »

Hello,

I'm only a beginner with PICmicro.
My english is not very well, but If I understand correctly.
Should it succeed with a 16F628 to a servo to drive?
Because it has 3 timers.

Yet am I unable to use a servo with a 628
Why?
Where am I wrong?

Rene

Sean
Valued Contributor
Valued Contributor
Posts: 548
Joined: Tue Jun 26, 2007 11:23 am
Has thanked: 6 times
Been thanked: 44 times

Re: choice of pic

Post by Sean »

Hello Rene,

The servo component requires a 16-bit timer (TMR1) with two CCP (capture compare pwm) modules attached. The code uses the two CCP modules in 'compare' mode to generate two interrupts.

One CCP module generates an interrupt every 2.5ms to trigger the start of each channel pulse ( 8 channels * 2.5ms = 20ms cycle time). Unused channels still have a 2.5ms time slot allocated to maintain the 20ms cycle time.

The other CCP module is supplied with the pulse width value for each channel in sequence.

Devices like the F88, F628 etc, have a 16-bit timer, but only have one CCP module (one PWM channel) and can not generate all the required timing signals.

The F877 contains the two CCP modules required, as do many newer devices.

Post Reply