Pulsin with Flowcode on a PIC

For questions and comments on programming in general. And for any items that don't fit into the forums below.

Moderators: Benj, Mods

Post Reply
mb02155
Posts: 14
Joined: Thu Sep 02, 2010 11:49 pm

Pulsin with Flowcode on a PIC

Post by mb02155 »

Hello,

I am trying to figure out how to do the equivelant of a pulsin (PICBasic or the Basic Stamp) using Flowcode. Can anyone point me in the right direction?

Thanks,
Marty

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: Pulsin with Flowcode on a PIC

Post by Benj »

Hello,

What exactly does pulsein do?

I would assume if it is getting the logic level of a pin then you can do this by using the input icon in single bit mode.

Otherwise if the function is a wait until high or wait until low then you can do this by using a switch component and using the component macros "waituntilx".

mb02155
Posts: 14
Joined: Thu Sep 02, 2010 11:49 pm

Re: Pulsin with Flowcode on a PIC

Post by mb02155 »

Ben,

Basically pulsin mesauress serial pulse width.

What we need to be able to do is read the pulse width or frequency of a sensor.

Here is a link to an example sensor:
http://www.parallax.com/Store/Sensors/C ... fault.aspx

Page 130 on the link below describes the pulsin function in PICBasic pro:
http://melabs.com/downloads/pbpm108.pdf

Thanks,
Marty

medelec35
Matrix Staff
Posts: 9521
Joined: Sat May 05, 2007 2:27 pm
Location: Northamptonshire, UK
Has thanked: 2585 times
Been thanked: 3815 times

Re: Pulsin with Flowcode on a PIC

Post by medelec35 »

Hello Marty
For a start you could try here:
http://www.matrixmultimedia.com/mmforum ... 70&p=20174
and follow the links since a similar question was asked.
Martin

Post Reply