Coder Social home page Coder Social logo

Comments (21)

fedy0 avatar fedy0 commented on June 16, 2024

@beegee-tokyo
Download https://github.com/francis94c/ESP32Partitions.git and extract to ...~\Documents\Arduino\tools

You may create the "tools" folder if it does not exist then extract within it

from esp32partitions.

SensorsIot avatar SensorsIot commented on June 16, 2024

I have exactly the same issue. Both files are in the tools directory as described above. Menu shows up in Arduino IDE, but pop-up does not appear.

from esp32partitions.

johannesmaibaum avatar johannesmaibaum commented on June 16, 2024

Hi,
I have to join the little crowd of affected people as well.

Using Arduino IDE 1.8.6 on Ubuntu 18.04, and trying both the beta of your tool from your releases page (dubbed 0.0.1) and the newest available ZIP file directly from the repo (dubbed 0.0.2 from your commit message), the only response after clicking on the menu item for the Partition Manager is this Java exception:

java.io.IOException: Cannot run program "reg": error=2, Datei oder Verzeichnis nicht gefunden
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1048)
	at java.lang.Runtime.exec(Runtime.java:620)
	at java.lang.Runtime.exec(Runtime.java:450)
	at java.lang.Runtime.exec(Runtime.java:347)
	at com.espressif.partitions.ESP32Partitions.run(ESP32Partitions.java:51)
	at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311)
	at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:758)
	at java.awt.EventQueue.access$500(EventQueue.java:97)
	at java.awt.EventQueue$3.run(EventQueue.java:709)
	at java.awt.EventQueue$3.run(EventQueue.java:703)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:80)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
Caused by: java.io.IOException: error=2, Datei oder Verzeichnis nicht gefunden
	at java.lang.UNIXProcess.forkAndExec(Native Method)
	at java.lang.UNIXProcess.<init>(UNIXProcess.java:247)
	at java.lang.ProcessImpl.start(ProcessImpl.java:134)
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1029)
	... 18 more

As it stands, the tool is unusable at the moment.

from esp32partitions.

francis94c avatar francis94c commented on June 16, 2024

@johannesmaibaum The Error you are getting is due to the fact that at that point in the program, it's trying to read a key from your registry using the 'reg' program.

Unfortunately, Linux/Ubuntu does not have a registry to the best of my knowledge as i'm a windows user.

However, i can run a virtual Linux machine and try to find a fix for you.

from esp32partitions.

francis94c avatar francis94c commented on June 16, 2024

@SensorsIot What version of Python do you have installed?

from esp32partitions.

johannesmaibaum avatar johannesmaibaum commented on June 16, 2024

@francis94c Ah, sorry, didn't know that this is Windows-only so far. Got here by trying to run the EEPROM class examples from the official ESP32 Arduino core by espressif.

No, GNU/Linux has no registry in the Windows sense, but depending on what value you're trying to get from it, there might indeed be an equivalent way of acquiring that information. From a quick glance at your code (disclaimer: I'm neither a Java programmer nor a Windows registry expert), but form googling the key you are requesting inside your ESP32Partitions::run() method, I assume that you're trying to query the home directory path of the current user. In a GNU/Linux system, this info is usually provided by the environment variable HOME.

from esp32partitions.

francis94c avatar francis94c commented on June 16, 2024

Yeah, you are right @johannesmaibaum because the Arduino IDE tools folder in 'My Documents' which contains the actual python script 'esp-partition.py' that builds the UI, is relative the home path.

is the tools folder for Arduino IDE relative to the path in this Home variable?

from esp32partitions.

johannesmaibaum avatar johannesmaibaum commented on June 16, 2024

@francis94c If you install the Arduino IDE using default paths, the standard path for the tools folder would be $HOME/Arduino/tools.

from esp32partitions.

johannesmaibaum avatar johannesmaibaum commented on June 16, 2024

@francis94c By the way, I feel like hijacking this issue which wasn't GNU/Linux-related at all. Shouldn't we move this discussion to a new issue?

from esp32partitions.

francis94c avatar francis94c commented on June 16, 2024

Sure, feel free.

from esp32partitions.

SensorsIot avatar SensorsIot commented on June 16, 2024

@SensorsIot What version of Python do you have installed?

3.6. But maybe also 2.7 from an earlier project. I am a Python beginner :-(

from esp32partitions.

francis94c avatar francis94c commented on June 16, 2024

@SensorsIot Do you see a file esp-partition.py in C:\Users\{User Name}\Documents\Arduino\tools\ESP32Partitions\tool ?

If you do, open a terminal in that directory and run python esp-partition.py.

Let me know what happens.

from esp32partitions.

SensorsIot avatar SensorsIot commented on June 16, 2024

The ESP Partition tool appears in a pop-up. I extended the two app partitions to 0x1f0000 and the spiffs was reduced to 0xf000. After pressing "generate" the error message "An Arduino ESP32 path was not set" appears.

from esp32partitions.

fedy0 avatar fedy0 commented on June 16, 2024

@SensorsIot

Hi Sir Andreas Spiess,
I'm glad you later tried it out.

You are almost there. Just set the path ONLY ONCE by starting your arduino IDE navigating to Tools >> ESP32 Partition Manager >> Espressif (@menu bar) >> Preferences

Then set the arduino-esp32 path and dump path to (this is my own case)
C:\arduino-1.8.5\hardware\espressif\esp32
and
C:\arduino-1.8.5\hardware\espressif\esp32\tools\partitions
respectively.

If your arduino-esp32 installation was done through arduino board manager then your arduino-esp32 core would be in somewhere
C:\User(Your PC name)\AppData\Local\Arduino15\packages\esp32
and dump path
C:\User(Your PC name)\AppData\Local\Arduino15\packages\esp32\tools\partitions

Please note that this setup is done only ONCE.

I hope to see it in your wonderful reviews @your YouTube channel.

With love for open source from,
@francis94c & @fedy0

from esp32partitions.

arminsalcin avatar arminsalcin commented on June 16, 2024

I don't know is this helpful for anyone but instead of making your partitions you can use implemented in core from there , so instead EEPROMClass NAMES("eeprom0", 0x1000); write EEPROMClass NAMES("eeprom", 0x1000); , and it will work for example named "eeprom_class"

from esp32partitions.

amontero0611 avatar amontero0611 commented on June 16, 2024

@SensorsIot Do you see a file esp-partition.py in C:\Users\{User Name}\Documents\Arduino\tools\ESP32Partitions\tool ?

If you do, open a terminal in that directory and run python esp-partition.py.

Let me know what happens.
I got an error when trying to execute esp-partittion.py:
python esp-partition.py
File "esp-partition.py", line 498
buff = sorted(self.ui_map.iteritems(), key=lambda(k, v): (v, k))
SyntaxError: invalid syntax

I have no experience in python, and need to use this tool. Can you please help?

from esp32partitions.

amontero0611 avatar amontero0611 commented on June 16, 2024

@SensorsIot Do you see a file esp-partition.py in C:\Users\{User Name}\Documents\Arduino\tools\ESP32Partitions\tool ?
If you do, open a terminal in that directory and run python esp-partition.py.
Let me know what happens.
I got an error when trying to execute esp-partittion.py:
python esp-partition.py
File "esp-partition.py", line 498
buff = sorted(self.ui_map.iteritems(), key=lambda(k, v): (v, k))
SyntaxError: invalid syntax

I have no experience in python, and need to use this tool. Can you please help?

Solved using python 2.7

from esp32partitions.

francis94c avatar francis94c commented on June 16, 2024

The script was written using python 2.7

from esp32partitions.

Adrianotiger avatar Adrianotiger commented on June 16, 2024

Is there a way to write the same sorted function for python3 in the same code?
I rewrote it for both (python 2 and 3):
#2

But I commented out the sorted function as I am not able to write it with "if PY=2 sorted(…), else sorted(...)"

from esp32partitions.

drmpf avatar drmpf commented on June 16, 2024

You are almost there. Just set the path ONLY ONCE by starting your arduino IDE navigating to Tools >> ESP32 Partition Manager >> Espressif (@menu bar) >> Preferences

If your arduino-esp32 installation was done through arduino board manager then your arduino-esp32 core would be in somewhere
C:\User(Your PC name)\AppData\Local\Arduino15\packages\esp32
and dump path
C:\User(Your PC name)\AppData\Local\Arduino15\packages\esp32\tools\partitions

Please note that this setup is done only ONCE.

Two changes I made to get this working
i) on windows you MUST have the display font set to Normal(100%). If you set it larger 125% or 150% you cannot access the button on the right of the path fields
ii) the paths for window Arduino15 board manager install are actually
C:\Users<username>\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.2
for the Arduino ESP32 path and
C:\Users<username>\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.2\tools\partitions
for the dump path
for version 1.0.2 release

from esp32partitions.

sabado avatar sabado commented on June 16, 2024

@johannesmaibaum The Error you are getting is due to the fact that at that point in the program, it's trying to read a key from your registry using the 'reg' program.

Unfortunately, Linux/Ubuntu does not have a registry to the best of my knowledge as i'm a windows user.

However, i can run a virtual Linux machine and try to find a fix for you.

Installed in ubuntu, getting the same error when click in the Tools -> ESP32 Partition Manager

from esp32partitions.

Related Issues (8)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.