Hi, I have a program for the MIAC (Flowcode v 4.5) which reads an analogue value and uses it in a Timer. Read in 0-12V, approx 0-240.
Divide by 10 = 0-24. This value is used in a Delay function to give a delay of 0 to 24 seconds. I've done this before on Pic's and it works well.
Works great is simulation but not on the Miac. Fixed delays work fine so the problem is with the analogue input.
I've put a Macro Test at the start to make debugging simpler.
Any help gratefully received.
Dave.
Miac analogue input problem
-
- Matrix Staff
- Posts: 9521
- Joined: Sat May 05, 2007 2:27 pm
- Location: Northamptonshire, UK
- Has thanked: 2585 times
- Been thanked: 3815 times
Re: Miac analogue input problem
Hi Dave,
You need to add the Miac component to your control panel, then use the Miac components for reading ADC channels.
You don't use standard ADC components (if you do then the result will always be 0), so they will require deleting from your panel.
Best advice is to read the Miac programming operating guide, and look at Miac Examples.
Take a look here for the guide:
http://www.matrixmultimedia.com/miac.php
I posted a Miac voltmeter here:
http://www.matrixmultimedia.com/mmforum ... 256#p18126
You can then see how ADC component within Miac is used.
If your still stuck then please let us know.
You need to add the Miac component to your control panel, then use the Miac components for reading ADC channels.
You don't use standard ADC components (if you do then the result will always be 0), so they will require deleting from your panel.
Best advice is to read the Miac programming operating guide, and look at Miac Examples.
Take a look here for the guide:
http://www.matrixmultimedia.com/miac.php
I posted a Miac voltmeter here:
http://www.matrixmultimedia.com/mmforum ... 256#p18126
You can then see how ADC component within Miac is used.
If your still stuck then please let us know.
Martin
-
- Matrix Staff
- Posts: 9521
- Joined: Sat May 05, 2007 2:27 pm
- Location: Northamptonshire, UK
- Has thanked: 2585 times
- Been thanked: 3815 times