en-us_products:mpino_studio2:memory
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| en-us_products:mpino_studio2:memory [2026/09/08 22:56] – 바깥 편집 127.0.0.1 | en-us_products:mpino_studio2:memory [2026/09/14 12:24] (current) – external edit 127.0.0.1 | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ====== MPINO STUDIO 2 Phase 2 · Understand Memory ====== | ====== MPINO STUDIO 2 Phase 2 · Understand Memory ====== | ||
| - | This page explains the differences between **P, M, D, C, T, and R memory**, address notation, memory-region settings, | + | This page explains the differences between **P, M, D, C, T, and R memory**, address notation, memory-region settings, |
| - | ^ Reference board ^ Completion goal ^ | + | {{ : |
| - | | MPINO-8A4R(T)-S | Identify memory addresses and locate where they are used in a project | | + | |
| - | + | ||
| - | {{ : | + | |
| > **About screenshots: | > **About screenshots: | ||
| Line 27: | Line 24: | ||
| | '' | | '' | ||
| | '' | | '' | ||
| + | |||
| + | ==== Sharing Memory Between Arduino Code and Ladder Logic ==== | ||
| + | |||
| + | Ladder logic and Arduino code use the same storage for P, M, D, C, T, and R memory. A value written on one side can be read from the same address on the other side. | ||
| + | |||
| + | {{ : | ||
| + | |||
| + | In Arduino code, use the ladder address name directly or write it in array form. Both forms refer to the same memory. | ||
| + | |||
| + | * Ladder '' | ||
| + | * Ladder '' | ||
| + | * Ladder '' | ||
| + | |||
| + | <code cpp> | ||
| + | void loop() { | ||
| + | M0 = true; // Sets the M0 bit contact in the ladder to ON. | ||
| + | D0 = 120; // Shares the D0 integer between ladder and Arduino code. | ||
| + | R0 = 23.5f; | ||
| + | |||
| + | ladderLoop(); | ||
| + | } | ||
| + | </ | ||
| + | |||
| + | A value changed by ladder logic can be read in Arduino code after '' | ||
| + | |||
| + | > **I/O mapping caution:** The P region and C addresses mapped to board functions are synchronized with physical I/O during a ladder scan. Before sharing these regions with Arduino code, check the address and I/O direction under **Settings → Ladder Pin Map Settings**. | ||
| > **P address caution:** P addresses can be reviewed and changed in **Board Pin Editing**. Their I/O directions and physical terminals follow the definition of the board selected for the project. | > **P address caution:** P addresses can be reviewed and changed in **Board Pin Editing**. Their I/O directions and physical terminals follow the definition of the board selected for the project. | ||
| Line 38: | Line 61: | ||
| You can change the number of addresses used under **Settings → Memory Region Settings**. (Shortcut: '' | You can change the number of addresses used under **Settings → Memory Region Settings**. (Shortcut: '' | ||
| - | {{ : | + | {{ : |
| ^ Region ^ Default count ^ Default address range ^ | ^ Region ^ Default count ^ Default address range ^ | ||
| Line 68: | Line 91: | ||
| | '' | | '' | ||
| - | > **Critical check:** If you choose '' | + | > **Critical check:** If you choose '' |
| Mapped addresses vary by board and can also be changed by the user. Check them under **Settings → Ladder Pin Map Settings**. | Mapped addresses vary by board and can also be changed by the user. Check them under **Settings → Ladder Pin Map Settings**. | ||
| Line 111: | Line 134: | ||
| ===== 5. Find Memory Used by the Project ===== | ===== 5. Find Memory Used by the Project ===== | ||
| - | Select **View → Used Memory | + | Select **Settings |
| - | {{ : | + | {{ : |
| Inspecting this map before reassigning an address or reducing a memory-region size helps prevent duplicate use and out-of-range references. | Inspecting this map before reassigning an address or reducing a memory-region size helps prevent duplicate use and out-of-range references. | ||
| - | ===== 6. Time-Driven | + | ===== 6. Special-Bit Memory ===== |
| - | Special-bit memory beginning with '' | + | Special-bit memory beginning with '' |
| - | + | ||
| - | {{ : | + | |
| ^ Format ^ Operation ^ Example ^ | ^ Format ^ Operation ^ Example ^ | ||
| + | | '' | ||
| + | | '' | ||
| | '' | | '' | ||
| | '' | | '' | ||
| + | |||
| + | '' | ||
| + | |||
| + | {{ : | ||
| '' | '' | ||
| Line 131: | Line 158: | ||
| '' | '' | ||
| - | {{ : | + | {{ : |
| Follow these input rules: | Follow these input rules: | ||
| - | * The time unit is milliseconds (ms). | + | * The time unit for '' |
| * Do not use parentheses. Enter '' | * Do not use parentheses. Enter '' | ||
| - | * Use a special | + | * Use special-bit memory |
| * Do not enter it as an output-coil address. | * Do not enter it as an output-coil address. | ||
| - | * An arbitrary name such as '' | ||
| ===== Troubleshooting ===== | ===== Troubleshooting ===== | ||
| Line 146: | Line 172: | ||
| | An entered address is rejected. | Check the region letter, address range, B/W/D prefix support, and '' | | An entered address is rejected. | Check the region letter, address range, B/W/D prefix support, and '' | ||
| | Memory Region Settings cannot be saved. | Check whether estimated SRAM use exceeds total SRAM and is shown in red. | | | Memory Region Settings cannot be saved. | Check whether estimated SRAM use exceeds total SRAM and is shown in red. | | ||
| - | | An address does not appear in the Used Memory | + | | An address does not appear in Used Memory. | Select the correct region tab and ladder/code filters, enter the address, and press '' |
| | A C counter value is unexpected. | First check for overlap with the '' | | A C counter value is unexpected. | First check for overlap with the '' | ||
| - | | '' | + | | '' |
| ===== Related Documentation ===== | ===== Related Documentation ===== | ||
| + | |||
| + | * [[en-us_products: | ||
| + | |||
| + | * [[en-us_products: | ||
| + | |||
| + | * [[en-us_products: | ||
| * [[: | * [[: | ||
en-us_products/mpino_studio2/memory.1788875803.txt.gz · Last modified: by 127.0.0.1
