Shop OBEX P1 Docs P2 Docs Learn Events
SimpleIDE Error — Parallax Forums

SimpleIDE Error

Hello to the community! I'm new to the forum, and I'm currently a student working with the P1 for my capstone project. I have a basic familiarity with Spin but wanted to see if C would work as well. SimpleIDE spits out the attached message with a 'Download failed: -1' error. I was hoping someone may know what this means exactly.

Also worth mentioning is that I'm not working with a dedicated evaluation board for the P1. It is set up on a breadboard with the Prop Plug. The Propeller Tool works great for Spin, but not so for SimpleIDE.

Comments

  • looks like it doesn't like your prop plug or something on com3:

    When I run it I get this message:

    Project Directory: D:/Documents/SimpleIDE/My Projects/Memory/
    
    SimpleIDE Version 1.1.2
    D:/Documents/SimpleIDE/Learn/Simple Libraries/
    D:/Documents/SimpleIDE/ Updated on: 2018-10-31
    
    propeller-elf-gcc.exe -v GCC 4.6.1 (propellergcc_v1_0_0_2408)
    propeller-elf-gcc.exe -I . -L . -I D:/Documents/SimpleIDE/Learn/Simple Libraries/Utility/libsimpletools -L D:/Documents/SimpleIDE/Learn/Simple Libraries/Utility/libsimpletools/cmm/ -I D:/Documents/SimpleIDE/Learn/Simple Libraries/TextDevices/libsimpletext -L D:/Documents/SimpleIDE/Learn/Simple Libraries/TextDevices/libsimpletext/cmm/ -I D:/Documents/SimpleIDE/Learn/Simple Libraries/Protocol/libsimplei2c -L D:/Documents/SimpleIDE/Learn/Simple Libraries/Protocol/libsimplei2c/cmm/ -o cmm/Memory.elf -Os -mcmm -m32bit-doubles -fno-exceptions -std=c99 Memory.c -lm -lsimpletools -lsimpletext -lsimplei2c -lm -lsimpletools -lsimpletext -lm -lsimpletools -lm
    propeller-load -s cmm/Memory.elf
    propeller-elf-objdump -h cmm/Memory.elf
    Done. Build Succeeded!
    
    proploader.exe -r -I C:/Program Files (x86)/SimpleIDE/bin/../propeller-gcc/propeller-load/ -b activityboard -p COM10 cmm/Memory.elf
    Opening file 'cmm/Memory.elf'
    ERROR: Propeller not found on COM10
    ERROR: Download failed: -1
    
    Opening file 'cmm/Memory.elf'
    ERROR: Propeller not found on COM10
    ERROR: Download failed: -1
    

    You see I get the Propeller not found message.

    The -1 just means an error occured.

    Mike

  • I am getting a similar error as well, with the exception that it occurs when opening the welcome file. Just went with defaults during installation, but no luck running the test program.

  • @NickMikhay ,

    This is the same issue. It's not finding your Propeller Microcontroller on that port.

    What is your setup?

    Mike

  • Using the prop demo board with prop-plug. I am sure that the hardware is ok, since there are no issues with the propeller tool and spin. Latency problem maybe, I don’t know.

    But I did notice that it is trying to communicate with the prop, because the lights on the prop-plug flash, and if you select the wrong com port it ends with no propeller found on com1 instead.

  • Which prop demo board? Could you post a photo of your setup?

    Propeller tool doesn't require the xtal/PLL to program, whereas SimpleIDE does. Do you have SPIN code actually running using the external xtal, or did you just test programming with Propeller Tool?

  • Reading back to your first post, you mention a breadboard circuit.

    Likely causes include lack of decoupling caps, or caps not in good places/long leads. Or only having power connected to one side of the P1 chip. Or having long leads/long breadboard area to the xtal.

    Sharing your board photo will likely allow us to help you solve those sorts of issues quickly.

  • No, this was Sethbrad’s post, I just commented that I was having the exact same problem. As far as the board it has all the caps and a 5mhz crystal that I got off parallax.
    I had it setup across the room with a 15’ usb cable, and I later added a usb hub and then powered with an adapter. But Spin worked all along and I written several programs and did some experimenting with synchronized delay loops, the waveforms I observed were sharp, and the vga signals were sharp when I peeked them out.

    I had a problem like this with the basic stamp years ago, and I remember tech support had me adjust the latency on the port, but I don’t remember how to do this now.

  • @NickMikhay ,

    If a spin program loads over that cable and simpleIDE does not than more than likely the problem is the reset signal timing.

    Mike

  • Here is a photo of the setup I am using.

  • you need power and ground on all connections to the P1 and decoupling caps also or you fry your PLL

    Mike

  • Why would I need something I already have?

  • could not see them, on the top so are they on the bottom?

    but fried pll could explain proptool loading and the two stage loader of simpleide not

    just making sure,

    mike

  • iseriesiseries Posts: 1,443
    edited 2022-05-17 11:09

    Here is my setup:
    P1Board

    I only use SimpleIDE to program.

    Mike

    PS: SimpleIDE will not work without the Crystal, but the SPIN programmer will.

  • LtechLtech Posts: 366
    edited 2022-05-17 16:37

    x

  • msrobotsmsrobots Posts: 3,701
    edited 2022-05-18 00:35

    well @iseries, you either are lucky or have a very robust P1 chip.

    My experience shows, not having bypass caps on crystal on all 3.3V inputs and have all connected will kill the pll and makes the P1 not able to switch out of rcslow or rcfast.

    look at the schematic of the PE kit and you might see wat I mean.

    Mike

  • I wasn’t sure about the pll, but now that I fiddled a little more, the timing seems off. I can’t get very short delays and it seems that the clkfreq is being derived from a 1mhz oscillator. This seems odd because the crystal is 5mhz. and I don’t see a 1 mhz rc mode. I wish I knew more about pll’s but I put off studying them to study MCU’s instead.

    You see, when I devide clkfreq by 1_000 to get milliseconds and multiply by 1 to get 1mS. delay and test the output pin that I am toggling, I am getting a 500 hz square wave. The crystal is 5mhz though, and furthermore, if I multiply the freq 2,4,8 times I am still getting the same 500 hz squarewave.

  • @NickMikhay ,

    What are we talking about here. SPIN or SimpleIDE. SimpleIDE has different compile modes that can mess with timing.

    If you use the LMM mode to compile your programs then you get basic assembly code and timings are correct. By default the compiler builds in the 16 multiplier so a 5Mhz crystal causes the propeller to run at 80Mhz. Now each instruction can take 4 clock cycles to execute plus access delays.

    Mike

  • C is so widespread I thought it would be easier finding drivers and thats why I installed SimpleIde, but since is the only thing working and people have suggested my pll is ruined and that I need to add more capacitors, I used spin to troubleshoot by outputting different frequency, and I saw no jitter on the power pins, was able to get the frequency to 50uS but was with a 2000 cnt delay. I think it should go lower around 400
    ‘waitcnt(cnt +=400)’

    so I thought maybe the board is fine, but delay loops require more than 381 cycles for timing loops which is strange. I thought that would be the default.

  • @NickMikhay ,

    I did some test with my setup and the C code will not work without a crystal installed. Even if the program loaded into memory the code will not run because under the covers the C code switches to xtal16 mode.

    Mike

  • NickMikhayNickMikhay Posts: 41
    edited 2022-05-20 22:41

    When I set xtal1 mode and use the time delays I appear to have crystal circuit working, I am not sure whether it can default to another mode, but if the delay loops agree with the oscillalor when using time delays without the clkfreq but numerically entering delay and observing the output to match, I would stipulate that the crystal is indeed working, also observing the power pin and the lack of jitter helps to affirm this. Using the multipliers works as well.

    The only thing which appears out of spec is that the minimum value for the delay is rather high, which is what I would like to confirm.

Sign In or Register to comment.