File converted from an earlier Flowcode is running on V9 with the help from @medelec35 (thank you) The converted file is working for me - A few hickupps, mainly for the analog inputs. I used to have a number in the program looking for <1500. Now that code only works with <500.
I think I have concluded that the FC9 thinks that the pic18f2553 is an 8 bit analog - It's actually 12 bits (4096)
I'm trapping the DC voltage and running an eeprom save routine below a certain value - My sample voltage is developed from the 17VDC power using a potential divider, bringing me to around 4V. When the DC analog is around 2.5V I presume the power is going away, and I run the eeprom save routing which saves all my values for next power up - Works great.
I checked the voltage on the AN input and the routine runs at 2.5V which should equate to around 2000 counts. It thinks that 500 counts is around 2.5V.
I have attached the converted file (FC5 to FC9) - The macro in question is called "AC_Monitor" which saves eeprom values if the analog value is below critical number.
Did you want to take a quick look at that?
Analog resolution?
-
- Posts: 133
- http://meble-kuchenne.info.pl
- Joined: Fri Dec 04, 2020 2:29 pm
- Has thanked: 26 times
- Been thanked: 7 times
Analog resolution?
- Attachments
-
- FLOWCODE 5 Dracular BUZZ WC100218-1910_v9.fcfx
- (323.2 KiB) Downloaded 317 times
-
- Matrix Staff
- Posts: 1924
- Joined: Mon Dec 07, 2020 10:06 am
- Has thanked: 501 times
- Been thanked: 684 times
Re: Analog resolution?
Hello,
Looking at the code it looks like we may have been defaulting to 10-bit ADC mode on that device.
I've pushed an update which hopefully should solve the problem for you.
Looking at the code it looks like we may have been defaulting to 10-bit ADC mode on that device.
I've pushed an update which hopefully should solve the problem for you.
Regards Ben Rowland - MatrixTSL
Flowcode Online Code Viewer (Beta) - Flowcode Product Page - Flowcode Help Wiki - My YouTube Channel
Flowcode Online Code Viewer (Beta) - Flowcode Product Page - Flowcode Help Wiki - My YouTube Channel