Ahmed Kerem Öztürk
Hello ,
I am testing OpenPLC on an STM32F103ZET6 board and I have reached a point where I believe the issue is no longer related to the ladder logic itself.
The output side appears to work correctly. I can successfully control onboard LEDs through the ladder logic, and I verified with a multimeter that the output pins change voltage correctly. PF9, for example, behaves like an active-low output and reacts as expected.
The issue is with digital inputs.
I tested several pins listed inside the PINMASK_DIN configuration, including PB10 and other valid digital input pins. I mapped them correctly as %IX0.0 and created very simple ladder programs for testing.
To simulate a physical digital input signal, I used a jumper wire ; one side connected to either 3.3V or GND, the other side connected directly to the input pin being tested.
The purpose was simply to force the GPIO input HIGH or LOW and verify whether the ladder logic reacted to the change.
However, regardless of the pin used or the ladder configuration, the input state never seems to change. The outputs continue working correctly, but the inputs do not appear to be scanned or updated by the runtime.
At this point I suspect the issue may be related to the STM32 runtime GPIO input handling, hardware layer, or board configuration rather than the ladder logic itself.
Has anyone experienced something similar with STM32F103 boards or OpenPLC input scanning before?
Reply 0 0
thiagoralves
What does your pin mapping screen look like?
Reply 0 0
Ahmed Kerem Öztürk
[203128%2F9805819%2Fmceclip0]  
 
Here is my current pin mapping configuration. I am currently testing PA8 as the digital input and PF8 as the digital output.
Reply 0 0
Ahmed Kerem Öztürk
 
I performed the exact same test on a Blue Pill STM32 board using OpenPLC.
Using the same ladder logic, the same button wiring, and the same LED test setup, the Blue Pill works correctly. When I press the button, the LED turns on, and when I release the button, the LED turns off.
However, when I use the same OpenPLC project and the same hardware test method on my STM32F103ZET6 board, the outputs work but the digital inputs do not seem to react.
Because the same logic and wiring work correctly on the Blue Pill, I suspect the issue may be related to the STM32F103ZET6 board configuration, runtime implementation, GPIO input initialization, or another source file specific to this board.
Are there any source files, hardware layer files, GPIO configuration files, or runtime modules that I should inspect to verify how the digital inputs are initialized and scanned on this board?
At this point I have tested several input pins, different ladder configurations, direct jumper connections to 3.3V and GND, and a physical push button circuit, but I have not been able to get any digital input to change state.
I am using the same STM32F103ZET6 custom board definition that successfully drives the outputs, but only the inputs appear to be non-functional.
Reply 0 0
thiagoralves
Hello,
The OpenPLC forum has a new home: Autonomy Edge https://edge.autonomylogic.com. We migrated every member, profiles, topics, categories and attachments. Please redo your post on the new forum so we can continue our conversation.
Note: If you already have an Autonomy Edge account, you can simply login with your credentials to have access to your forum profile and posts. If you don't have an Autonomy Edge account, we ask you to set a fresh password on first sign-in using the same e-mail you used on this forum.
To set a fresh password, access the link https://edge.autonomylogic.com/forgot-password and insert the e-mail address used on this forum. You will receive an e-mail on your inbox with a link to choose a new password. Once you reset your password you will be able to login on edge.autonomylogic.com using your new credentials.
Reply 0 0
Reply