Open midicdj1000 opened 1 year ago
Just a note to say the python upload worked for basic.py after I changed the monitor port to windows com3.
Picoprobe is only used for developing the Pi Pico software. It's OK to not have a device driver for 6502 development. It's also OK to not have a device driver if you're using USB/IP.
EhBASIC doesn't have a maintainer right now. It needs to be updated for the SDK which has arguments for selecting the serial port.
I don't think anyone is using the SDK under Windows right now. If they are, they haven't shared any documentation.
Congratulations on the successful build.
I made some progress on the vscode and the errno.h error was because it couldn't find the cc65 include files and I am not show how to fix that so I just copied them into the project include. Next problem is Unresolved external 'mappederrno' referenced and Unresolved external 'seterrno' referenced in:
then not sure how to connect it via the terminal.
[main] Building folder: picotest1-main [build] Starting build [proc] Executing command: "C:\Program Files\CMake\bin\cmake.EXE" --build c:/pico6502/picotest1-main/build --config Debug --target all -j 18 -- [build] [ 48%] Built target rp6502 [build] [ 51%] [32m[1mLinking C executable hello[0m [build] Unresolved external '___mappederrno' referenced in: [build] C:/pico6502/picotest1-main/rp6502-sdk/src/write.s(254) [build] C:/pico6502/picotest1-main/rp6502-sdk/src/write.s(118) [build] C:/pico6502/picotest1-main/rp6502-sdk/src/read.s(282) [build] C:/pico6502/picotest1-main/rp6502-sdk/src/read.s(102) [build] C:/pico6502/picotest1-main/rp6502-sdk/src/open.s(134) [build] C:/pico6502/picotest1-main/rp6502-sdk/src/lseek.s(205) [build] C:/pico6502/picotest1-main/rp6502-sdk/src/lseek.s(110) [build] C:/pico6502/picotest1-main/rp6502-sdk/src/close.s(60) [build] Unresolved external '___seterrno' referenced in: [build] C:/pico6502/picotest1-main/rp6502-sdk/src/open.s(55) [build] ld65: Error: 2 unresolved external(s) found - cannot create output file [build] make[2]: *** [CMakeFiles/hello.dir/build.make:276: hello] Error 1 [build] make[1]: *** [CMakeFiles/Makefile2:100: CMakeFiles/hello.dir/all] Error 2 [build] make: *** [Makefile:91: all] Error 2 [build] Build finished with exit code 2
what does $ git submodule update --init do ? That is the only part I have not run
I am still suck with these errors [build] Unresolved external '___mappederrno' referenced in: [build] C:/pico6502/picotest1-main/rp6502-sdk/src/write.s(254) [build] C:/pico6502/picotest1-main/rp6502-sdk/src/write.s(118) [build] C:/pico6502/picotest1-main/rp6502-sdk/src/read.s(282) [build] C:/pico6502/picotest1-main/rp6502-sdk/src/read.s(102) [build] C:/pico6502/picotest1-main/rp6502-sdk/src/open.s(134) [build] C:/pico6502/picotest1-main/rp6502-sdk/src/lseek.s(205) [build] C:/pico6502/picotest1-main/rp6502-sdk/src/lseek.s(110) [build] C:/pico6502/picotest1-main/rp6502-sdk/src/close.s(60)
[build] Unresolved external '___seterrno' referenced in: [build] C:/pico6502/picotest1-main/rp6502-sdk/src/open.s(55)
from write.s if (ax < 0) return _mappederrno(RIA_ERRNO_LO);
from errno.h
/ define the name with just one underscore for backwards compatibility /
so it my problem still related to the cc65 librarys ?
Yes, a lot of these errors look like problems finding the CC65 includes. https://github.com/picocomputer/rp6502-sdk/blob/882173aefd62373d2a39e6b38f2720e2eae3b40b/CMakeLists.txt#L8-L12
Was trying to help and got an environment under windows working. but I was getting a linker error, not sure if something has changed with CC65. but I had to edit the oserror.s as the linker was looking for _osmaperrno where what it had was: osmaperrno
notice the 2 _ rather then the 3 the compiler and errno.inc was asking for .global ___osmaperrno
So much for stability and backwards compatibility of 20 year old software. https://github.com/cc65/cc65/commit/5d390489a8f754abfd032af858b6ed5686553187
After adding this to the cmakelists.txt if(DEFINED ENV{CC65_INCLUDE}) set(CC65_INCLUDE $ENV{CC65_INCLUDE}) else() set(CC65_INCLUDE "c:\pico6502\cc65\include") endif()
this one worked [build] [ 3%] [32mBuilding ASM object rp6502-sdk/CMakeFiles/rp6502.dir/src/crt0.s.obj[0m
this one has the Errol when it uses my local project C:/pico6502/picotest1-main/rp6502-sdk/src/write.s(254)
it compiled ok until it tried to link build] [ 92%] [32mBuilding C object CMakeFiles/hello.dir/rp6502-sdk/src/write.c.obj[0m [build] [ 96%] [32mBuilding C object CMakeFiles/hello.dir/rp6502-sdk/src/randomize.c.obj[0m [build] [100%] [32m[1mLinking C executable hello[0m [build] Unresolved external '___mappederrno' referenced in: [build] C:/pico6502/picotest1-main/rp6502-sdk/src/write.s(254)
could cygwin64 have anything to so with it ? CMAKE_ADDR2LINE:FILEPATH=C:/cygwin64/bin/addr2line.exe
with helps from @thegouldfish and @rumbledethumps I have the hello world compiled and uploaded.
Next is trying to document everything.
Looking at both versions of the online docs (sigh) it seems like the Windows installer may (or may have in the past) set the CC65_HOME environment variable. If it doesn't, or you need CC65 somewhere else like drive D:, then setting this environment variable is much better then editing the SDK CMakeLists.txt.
It's also possible to configure this in VSCode settings.json instead of your OS environment:
"cmake.configureEnvironment": {
"CC65_HOME": "D:/CC65"
},
Thanks, I have setup a VM with windows and have recorded a setup that worked start to end.
I have a video showing how I setup VScode
HI, I just built my picocomputer and I am trying to setup on windows with vs code. when I press F7 this is my output
[main] Building folder: picotest1-main [build] Starting build [proc] Executing command: "C:\Program Files\CMake\bin\cmake.exe" --build c:/pico6502/picotest1-main/build --config Debug --target all -j 18 -- [build] [ 3%] [32mBuilding ASM object rp6502-sdk/CMakeFiles/rp6502.dir/src/crt0.s.obj[0m [build] [ 7%] [32mBuilding C object rp6502-sdk/CMakeFiles/rp6502.dir/src/close.c.obj[0m [build] [ 11%] [32mBuilding ASM object rp6502-sdk/CMakeFiles/rp6502.dir/src/initenv.s.obj[0m [build] [ 14%] [32mBuilding C object rp6502-sdk/CMakeFiles/rp6502.dir/src/lseek.c.obj[0m [build] [ 18%] [32mBuilding ASM object rp6502-sdk/CMakeFiles/rp6502.dir/src/mainargs.s.obj[0m [build] [ 22%] [32mBuilding C object rp6502-sdk/CMakeFiles/rp6502.dir/src/open.c.obj[0m [build] [ 25%] [32mBuilding ASM object rp6502-sdk/CMakeFiles/rp6502.dir/src/oserrlist.s.obj[0m [build] C:/pico6502/picotest1-main/rp6502-sdk/src/lseek.c(11): Error: Include file 'errno.h' not found [build] 2 errors and 0 warnings generated. [build] C:/pico6502/picotest1-main/rp6502-sdk/src/lseek.c(25): Error: Call to undeclared function '_mappederrno' [build] make[2]: *** [rp6502-sdk/CMakeFiles/rp6502.dir/build.make:127: rp6502-sdk/CMakeFiles/rp6502.dir/src/lseek.c.obj] Error 1 [build] make[2]: *** Waiting for unfinished jobs.... [build] [ 29%] [32mBuilding ASM object rp6502-sdk/CMakeFiles/rp6502.dir/src/oserror.s.obj[0m [build] [ 33%] [32mBuilding C object rp6502-sdk/CMakeFiles/rp6502.dir/src/read.c.obj[0m [build] [ 37%] [32mBuilding C object rp6502-sdk/CMakeFiles/rp6502.dir/src/randomize.c.obj[0m [build] C:/pico6502/picotest1-main/rp6502-sdk/src/read.c(2): Error: Include file 'errno.h' not found [build] C:/pico6502/picotest1-main/rp6502-sdk/src/read.c(17): Error: Call to undeclared function '_mappederrno' [build] 2 errors and 0 warnings generated. [build] make[2]: *** [rp6502-sdk/CMakeFiles/rp6502.dir/build.make:192: rp6502-sdk/CMakeFiles/rp6502.dir/src/read.c.obj] Error 1 [build] make[1]: *** [CMakeFiles/Makefile2:126: rp6502-sdk/CMakeFiles/rp6502.dir/all] Error 2 [build] make: *** [Makefile:91: all] Error 2 [build] Build finished with exit code 2
I have made sure my project has the correct files in rp6502-sdk new install of cc65 I am a casual programmer and don't use vscode all that much, but I did use cc65 for the c64.
also not sure what to do with the pyserial and my device manager has a issue with the device