Page 1 of 2

ACS712 component doing wrong

Posted: Sun Jul 17, 2016 8:36 pm
by Monie Jacobsen
Hi!
I have tyed to make a program with ACS712. I used Jordy´s component from here: viewtopic.php?f=58&t=12785&p=51809&hilit=acs#p51809
When I try to compile to chip, I get error code – 2.
Please, what am I doing wrong?
Files:
Acs712.fcfx
(5.75 KiB) Downloaded 713 times

Re: ACS712 component doing wrong

Posted: Sun Jul 17, 2016 9:01 pm
by kersing
Monie, could you include the error messages in your post? Providing those messages could give us a clue about the issue without having to download both the flowchart and the component... (not to mention having to boot the computer and start flowcode ;-) )

Re: ACS712 component doing wrong

Posted: Mon Jul 18, 2016 8:41 am
by Monie Jacobsen
Hello kersing

Here is Compile two Hex:
Compile to Hex.txt
(5.14 KiB) Downloaded 668 times

Re: ACS712 component doing wrong

Posted: Mon Jul 18, 2016 8:57 am
by medelec35
Hi Monie,
If you look at:

Code: Select all

ROM available:8192 words, used:8654 words (105.6%), free:-462 words (-5.-6%)
Too much code to fit in ROM, overfilled by:462 locations.
It shows there is not enough ROM so you will need to choose a target with a bigger ROM (Program Memory) size.
viewtopic.php?f=54&t=16403&p=72550#p69835
Or
only have 8bit selected

Martin

Re: ACS712 component doing wrong

Posted: Mon Jul 18, 2016 9:48 am
by Monie Jacobsen
Hi Martin.

Dont know if you had a look on my program, it is very small. Does it mean we can not use the component ACS in FC, or am what am I do wrong, please.

Monie

Re: ACS712 component doing wrong

Posted: Mon Jul 18, 2016 11:40 am
by Monie Jacobsen
See here, Arduino UNO does not work.
Input A0 for ACS712
Have attached:
Program
arduinoAamp.fcfx
(7.34 KiB) Downloaded 649 times
Compile_Messages
Compile_Messages_from_Arduino_UNO.txt
(4.71 KiB) Downloaded 633 times
Can compile but no change in the display.
The input signal into A0 changes not reading in the display.
Very much hope to help...

Re: ACS712 component doing wrong

Posted: Thu Jul 21, 2016 7:28 am
by Monie Jacobsen
Hello!
Please is nobody able to help or fix the ACX component, or is it useless, please please.

Re: ACS712 component doing wrong

Posted: Thu Jul 21, 2016 12:42 pm
by Benj
Hi Monie,

Have you been able to get in touch with Jordie to see if he can shine any light on the issue. It's his components and I don't think he published the source code so very hard to try and guess what might be going wrong.

Have you done the basics like a 1 second flasher test to confirm the micro is running and have you set up the component's properties correctly?

Re: ACS712 component doing wrong

Posted: Thu Jul 21, 2016 1:47 pm
by Monie Jacobsen
Hello Benj

Yes there has to be a 1 second flash.
I have looked up the component's properties CORRECTLY...

Re: ACS712 component doing wrong

Posted: Thu Jul 21, 2016 2:00 pm
by Monie Jacobsen
Hello Benj
Can you make a component to ACS7xx

Re: ACS712 component doing wrong

Posted: Thu Jul 21, 2016 2:19 pm
by Benj
I can do but currently there is a lot on my plate in terms of adding polish to v7 components, bug fixing and documentation.

I also don't want to tread on Jordy's toes as his component should work well. I'll see if I can get in touch with him regarding the issue.

Re: ACS712 component doing wrong

Posted: Thu Jul 21, 2016 3:11 pm
by Monie Jacobsen
Hello Benj

Thank you very much
It will be very pleased about component came to work in practice

Re: ACS712 component doing wrong

Posted: Thu Jul 21, 2016 5:05 pm
by Benj
Hello Monie,

Do you get anything appearing on the LCD?

I wonder if the problem is the LCD rather than the ACS7x component as that simply seems to be doing ADC readings and then converting the result.

If the LCD is working fine then maybe there is a problem with the getAverage ADC reading that we can investigate?

Re: ACS712 component doing wrong

Posted: Thu Jul 21, 2016 10:17 pm
by Monie Jacobsen
Hi Ben!

Thank you for help. I have no problem with the LCD. Seemed to work. The component work perfect in simulation.

Concerning the ADC I dont know. I would be glad if you could help, or tell me what I could do, test or investigate.

Best regard
Monie.

Re: ACS712 component doing wrong

Posted: Mon Jul 25, 2016 12:31 pm
by Benj
Hi Monie,

A quick test would be to use a standard ADC component and use the GetAverageByte or GetAverageInt functions to take a reading of the ADC voltage. Then pass this value to the display.

If everything worked well then you should get a number on your display. If there is a problem then the GetAverage function may cause a hardware lockup which we will need to investigate.

Re: ACS712 component doing wrong

Posted: Mon Jul 25, 2016 8:11 pm
by Monie Jacobsen
Hi Ben!

I try to made a program according your request. It work well in simulation as in real world.

So what can we now do :?:

Thank´s

Monie...

Re: ACS712 component doing wrong

Posted: Sat Jul 30, 2016 5:09 pm
by jgu1
Hello Monie!

Have you figuring out of something concerning the ACSxx component. I have also tested it. It work fine in simulation, but error when compiling. I am also very interested in this component. :D it would be easy to make an ammeter with this component.

Best regard

Jorgen.

Re: ACS712 component doing wrong

Posted: Tue Aug 02, 2016 3:39 pm
by Monie Jacobsen
Hello!

Unfortunately not. Obviously nobody can. I also try PM to Jordy, but it is not possible to send him a PM.

Monie. :?

Re: ACS712 component doing wrong

Posted: Tue Aug 02, 2016 5:17 pm
by Benj
Hello,

I have spoken with Jordy and he was going to dig through his code and try to find the source to send to me. I haven't heard back from him yet about this.

One thing you could try is to look in the C code produced by the component and try to replicate the code in a macro. Hopefully it shouldn't be too hard but if your still having problems then I'll get it on the list and try to make this an inbuilt officially supported component.

Re: ACS712 component doing wrong

Posted: Wed Aug 03, 2016 12:50 pm
by Monie Jacobsen
Hello Benj
Is that how you think as an attachment?
I did not ouput to the display
ArdinoUnoACS7xx-Test.fcfx
(33.06 KiB) Downloaded 570 times
But is it something you could use?
Or can fix coderne to so I can test ACS7xx???

Re: ACS712 component doing wrong

Posted: Mon Aug 15, 2016 6:29 am
by Monie Jacobsen
Hello Benj!

Please, something new concerning the ACS component.

Re: ACS712 component doing wrong

Posted: Tue Aug 16, 2016 11:42 am
by Benj
Hi Monie,

I've just tried the program on an Arduino Uno using v6, replacing the I2C LCD with a standard LCD and used a potentiometer to simulate the analogue input and everything seems to be working fine.

The number is changing nicely from 5,59 to -5,59.
arduinoAamp-1.fcfx
(6.08 KiB) Downloaded 521 times
Looks to me like the component is working correctly but maybe something in your circuit is having a problem?

Re: ACS712 component doing wrong

Posted: Fri Aug 19, 2016 6:43 am
by Monie Jacobsen
Hello Benj!

It seemed to work on Arduino. But on a pic16fxx I still get the compilemessage “ ROM available:8192 words, used:8248 words (100.6%), free:-56 words (0.-6%)” ??
So I wonder, how much rom does it use when I use a Arduino and am I also almost on the limit usage and why does it use so much space in a Pic??

Se here example with PIC16F876...
Compiler messages:
compiler messages.txt
(404 Bytes) Downloaded 421 times
PIC16F876AampASC7.fcfx
(6.11 KiB) Downloaded 479 times
Conflict of channel choices.
ACS7XX1 channel A2
Potentiometer channel A0
By regulating ACS7XX1 follows both Potentiometer with
Code:
ArduinoAampI2C-Channel.fcfx
(8.07 KiB) Downloaded 489 times
Please are you able to make a component for the ACSxx. I am far to do it. Please.

Re: ACS712 component doing wrong

Posted: Fri Aug 26, 2016 6:18 am
by jgu1
Hi Monie!

I dare to ask, do you managed to get it run :?:

I still not. I get the same result as you. It is a shame it not do, because it is a really good idea. Wish I was able to create a new, but unfortunetely not :(

Br

Jorgen

Re: ACS712 component doing wrong

Posted: Tue Aug 30, 2016 7:31 am
by Monie Jacobsen
Hello
Sorry no, I can´t find the bug, I am not able to fix it, and it seem nobody else can. Sad.