Open k6lcm opened 4 months ago
That looks like a hardware issue, please detail how everything's hooked up.
Thanks for responding. Here is the schematic and board layout I am using. It does seem to send some kind of two-way communication with the board as I see data on both TX and RX pins using a scope. But the project itself is not working and I am, of course, suspicious of the error as the culprit.
Are you showing all the traces on that board? The Propeller has two power inputs, they both need to be connected, otherwise it won't work right.
Yeah, the second VDD/VSS pair shows as unconnected in the schematic, too. Fix that first, then try again.
Thanks for replying with the suggestion. I checked and there was continuity between those pins already and voltage across them but to be sure, I wired up bodge wires as shown in red. The same issue persists, however. I have quadruple checked the solder joints, too. This is my first propeller project so maybe I have a bad Prop Plug? Not sure. Any other thoughts?
There's also a pull-up missing on SCL. I think they're both needed.
Does it work when you just load the program to RAM instead of trying to program the EEPROM?
The program does not work in RAM either. What value resistor should I stick on pin 6/SCL? 10k to VCC?
Same as SDA, 10k should be fine.
But if it doesn't run in RAM either, there's some deeper issue, likely bad clock source.
I see there's an LED, can you run a simple blink program?
CON
_clkmode = rcfast
PUB main
DIRA[16] := 1
repeat
OUTA[16] := 1
waitcnt(cnt+5_000_000)
OUTA[16] := 0
waitcnt(cnt+5_000_000)
If that works (with internal oscillator, which is also used during download), try setting _clkmode = xtal1
(crystal direct) and then _clkmode = xtal1 + pll16x
(crystal+PLL)
Ok, checked the crystal with the scope and I am not seeing anything so that is suspect. I just ordered a few more 5MHz crystals. Will swap those in when they arrive and report back.
The crytal isn't supposed to do anything before it gets enabled by software. Please do test loading a program with the different clock modes as detailed above.
Ah, got it. Your code works (with the addition of setting the frequency using _xinfreq = 5_000_000). The LED is blinking with RCFAST, XTAL and XTAL+PLL. Also, 5MHz clock signal is present on the scope now, as you suspected.
The EEPROM is being written as the program remains persistent after power cycle. So I am at a loss as to why flexprop EEPROM verification is failing and still throwing the message:
Verifying EEPROM
ERROR: EEPROM verify failed
ERROR: Download failed
To clarify: You can program the EEPROM fine with a small program but it still errors out in the console, large-er program doesn't work. Correct?
Actually, flashing the EEPROM with both the larger project and the smaller LED Blink programs all show the "download failed" error.
Sounds like the beginning of the download works, but then it gets corrupted. Try passing -D loader=rom
to proploader.
Hmm. I changed Commands > Configure Commands > Flash Command to:
"%D/bin/proploader.mac" -k -D loader=rom baud-rate=%r %P "%B" -e
No change.
Well that's puzzling. Can you try with the official Propeller Tool on winblows?
On both Windows 11 and macOS the PropellerIDE throws the same error:
The external program 'bstc' has failed to start.
Verify the executable is in the system path and try again.
Since the official program never seemed to be released in anything more advanced than alpha (v 0.38.5 is the latest version) and has not been updated since 2015, I switched to using flexprop.
No, I mean Propeller Tool, this one. https://www.parallax.com/package/propeller-tool-software-for-windows-spin-assembly-2/ Windows only.
(Though idk wtf is even wrong with propIDE there that it can't launch bstc)
Update?
Haven't had a chance to fiddle with Propeller Tool yet. Will report when I have new data.
Using the current 6.9.10 and 6.9.9 versions, I am getting the following in the terminal when attempting to flash a P8X32A-D40.
I have tried running proploader.mac from the macOS command line and I am getting the same issue so I am also creating an issue in the parallaxinc/PropLoader project but that appears to be abandoned since 2020.