Home
Prox / RFID
Verichips
Ladder Logic
[interfacing] †
Tube Joints
Key Code From Photo
SolveSpace (3d CAD)
SketchFlat (2d CAD)
Photographs
Miscellany
Resume / Consulting
Contact Me

LDmicro Forum - wrong voltage level output of atmega8 on runninglights.

(you are viewing a thread; or go back to list of threads)

wrong voltage level output of atmega8 on runninglights. (by 80proof)
this program i used has the same ports output.but when i pressed the button2 the output voltage is not the same,but technically the output voltage should be the same.
Wed Dec 28 2011, 00:23:55, download attachment 12LEDrunning-lights.ld
double coil (by yanger)
My English is very poor. Your program double-wire, output will not normal.
Wed Dec 28 2011, 00:45:04
(no subject) (by MGP)
You may not use 2 outputs (relais) with the same name, Yout1..12

See link for an example

http://cq.cx/ladder-forum.pl?action=viewthread&parent=859
Wed Dec 28 2011, 03:42:33
(no subject) (by 80proof)
sir yanger, what do you mean double wire? i need to control 12 output LED, whats wrong on my program? sir MGP has good program above there.but i want to control my program using two push buttons. for CCW and CW movement of the running LED lights. not an ADC.
Thu Dec 29 2011, 18:09:02
(no subject) (by Jonathan Westhues)
You have two output coils on each of Yout1 to Yout12. This is incorrect, since the output pin can only have one state. There's multiple ways that you could fix the problem; the simplest one is probably to replace your CTC counter (that counts only up) with a counter that counts either up or down, and keep only the first set of output coils. You could make your up/down counter with CTU and CTD counter instructions, or you could make it using an OSR rising-edge trigger and normal arithmetic operations.

LDmicro is working as correctly as possible under the circumstances. Although, it's a bug that you don't get a warning for this error.
Fri Dec 30 2011, 03:49:16
(no subject) (by yanger)
Hello.
I'm sorry I will only Chinese, it is difficult to explain in English.
The attachment is I improved.
Thu Jan 5 2012, 01:20:10, download attachment 12LEDrunning-lights_YANGER.ld
Post a reply to this comment:
Your Name:
Your Email:
Subject:
(no HTML tags; use plain text, and hit Enter for a line break)
Attached file (if you want, 5 MB max):