Sparky 2.0 error
« on: August 21, 2016, 04:04:27 am »
received sparky 2.0

when I power it up, Power LED lights solid (Green), ERR LED lights solid (Orange), Blue LED pulses

start GCS ( latest pull of Next ), click Rescue and wait for it to prompt me to plug in.  Once I plug in,

Board is recognized as a Spark 2.0 but I get "Could not enter DFU mode"

I bought it from Banggood.

f5soh

  • *****
  • 4572
    • LibrePilot
Re: Sparky 2.0 error
« Reply #1 on: August 21, 2016, 05:20:43 am »

chromvis

  • *
  • 117
Re: Sparky 2.0 error
« Reply #2 on: August 21, 2016, 05:27:02 am »
As I remember, I did not use external power, simply plug to USB after pressing RESCUE. I got two of them from Banggood at different times and they are both OK.
Power distribution is different than Revo. I am powering Revo through Power port. Second pin in PWR port of Sparky 2 has DAC output instead of Vcc. It also seems not to have power for RCVR port.

f5soh

  • *****
  • 4572
    • LibrePilot
Re: Sparky 2.0 error
« Reply #3 on: August 21, 2016, 05:37:06 am »
Quote
It also seems not to have power for RCVR port.

You can select the voltage you want on receiver port, using the small pads on back.
Banggood ones comes with both pads soldered with a 10K resistor.
Just remove all resistors and do a small solder join on pads you want.



- 5v means the receiver is powered using the +5V from Esc / output connector, like Revo.
- 3.3v means the receiver is powered using the internal regulator (useful for DSM) but still powered through the external power.
« Last Edit: August 21, 2016, 05:41:37 am by f5soh »

Re: Sparky 2.0 error
« Reply #4 on: August 21, 2016, 05:52:08 am »
I am only using USB to power it, nothing is attached to Sparky 2.0 including antennae.

I haven't selected 5v or 3.3v for recver yet either. I've just taken the board out of the shipping package and tried to get GCS to talk with it, no luck.

I will try DFU recover and report back

mookie

  • *
  • 17
Re: Sparky 2.0 error
« Reply #5 on: August 21, 2016, 11:13:18 am »
did you boot the "bu_sparky2.opfw" boot loader first and let that run?

I have changed 3 over from taulabs.

Hit rescue, then plug in board. Choose the file above downloaded from librepilot main download page at the bottom.
Let that install, then press boot. let it run for 10secs. I did this a couple of times first.
Once that is ok.
Press rescue again without the board attached and plug in. GCS will download the firmware to the board press boot and its done.

I'm using a Sparky 2 from taulabs reseller, but it should be the same.

Re: Sparky 2.0 error
« Reply #6 on: August 21, 2016, 02:54:28 pm »
I hit rescue with the board unplugged, it waits for me to plug in and identify.

I plug the board in, it sees it as a Sparky 2.0 but then GCS says unable to enter DFU mode.  I never get a chance to "Open" a file?  Where should I see this as it is not on my version of Next at this point.

did you boot the "bu_sparky2.opfw" boot loader first and let that run?

I have changed 3 over from taulabs.

Hit rescue, then plug in board. Choose the file above downloaded from librepilot main download page at the bottom.
Let that install, then press boot. let it run for 10secs. I did this a couple of times first.
Once that is ok.
Press rescue again without the board attached and plug in. GCS will download the firmware to the board press boot and its done.

I'm using a Sparky 2 from taulabs reseller, but it should be the same.

Mateusz

  • *
  • 808
Re: Sparky 2.0 error
« Reply #7 on: August 21, 2016, 03:19:46 pm »
I know you can trigger manually STM32 Bootloader (DFU compatible) by soldering SBL pads and then connect board via USB. Then you can flash ef_sparky2.bin with dfu-util. Image called (ef = entire flash) with bin extension contains boot correct bootloader and firmware, so you don't need to do anything extra. Then you remove solder from SBL pads and it should work.

Code: [Select]
dfu-util  -d  0483:df11  -c  1  -i  0  -a  0  -D  ef_sparky2.bin  -s  0x08000000

However it would be better if you could figure out why in your case flashing from opfw file does not work. Windows blocking device ? I have no clue to be honest. What OS are you running on ? Is it Windows, Linux ? or something in VM ?

Re: Sparky 2.0 error
« Reply #8 on: August 21, 2016, 04:05:49 pm »
I read the DFU recovery and will do that later today/tomorrow but I am really interested in what is wrong with the board.

I am running Ubuntu Linux, dev environment so i can keep up on 'Next'.  Did a git pull yesterday, rebuilt everything and unwrapped the Sparky 2.0 to try out.  All of my other FC are working fine.

I can't find any info on the LED status, only if ERR blinks, not if it is solid in color.  Blue LED is blinking which makes me believe the boot loader is working yet GCS can't put it into DFU mode to recover.

i will short the SDL pads but wanted to try and figure out the problem first, any thoughts from anyone are appreciated.

Ben

I know you can trigger manually STM32 Bootloader (DFU compatible) by soldering SBL pads and then connect board via USB. Then you can flash ef_sparky2.bin with dfu-util. Image called (ef = entire flash) with bin extension contains boot correct bootloader and firmware, so you don't need to do anything extra. Then you remove solder from SBL pads and it should work.

Code: [Select]
dfu-util  -d  0483:df11  -c  1  -i  0  -a  0  -D  ef_sparky2.bin  -s  0x08000000

However it would be better if you could figure out why in your case flashing from opfw file does not work. Windows blocking device ? I have no clue to be honest. What OS are you running on ? Is it Windows, Linux ? or something in VM ?

Re: Sparky 2.0 error
« Reply #9 on: August 21, 2016, 08:10:55 pm »
It sounds like you know what you are doing, and what you describe should work fine.

I haven't flashed a new Sparky2 in a while, but I did 3 and I even put one back to TL BL and retested several times.  I suppose there could be a bug in the current next.  I should probably put a Sparky2 back to TL BL and make sure the "new board procedure" still works like it used to.

The "new board procedure" you are doing doesn't need a good app firmware, just a good bootloader.  You might have a bad bootloader (seller sent you a board that someone else flashed and returned).  There may be a solder blob that needs removing somewhere.  You may have a bad board.  :(

Is your Linux running on bare metal or in a VM?  I haven't tried it from a VM.

I would try a different computer and a different USB cable.
« Last Edit: August 21, 2016, 08:31:26 pm by TheOtherCliff »

Re: Sparky 2.0 error
« Reply #10 on: August 22, 2016, 02:03:41 am »
Linux is bare metal.

I would try another computer but I don't have a build of 'Next' for windows, my environment is only setup to build 'Next' for linux.  I would be happy to try another build if someone can make a windows 'Next' build available.

Do you have any idea what the solid ERR light indicates with the blinking Blue LED?

It sounds like you know what you are doing, and what you describe should work fine.

I haven't flashed a new Sparky2 in a while, but I did 3 and I even put one back to TL BL and retested several times.  I suppose there could be a bug in the current next.  I should probably put a Sparky2 back to TL BL and make sure the "new board procedure" still works like it used to.

The "new board procedure" you are doing doesn't need a good app firmware, just a good bootloader.  You might have a bad bootloader (seller sent you a board that someone else flashed and returned).  There may be a solder blob that needs removing somewhere.  You may have a bad board.  :(

Is your Linux running on bare metal or in a VM?  I haven't tried it from a VM.

I would try a different computer and a different USB cable.

hwh

  • *
  • 1018
Re: Sparky 2.0 error
« Reply #11 on: August 22, 2016, 02:18:18 am »
...if someone can make a windows 'Next' build available...
Another user is compiling and posting them in another thread.  He updates the link in the first post as he compiles new versions so that's the latest one he has available.  https://forum.librepilot.org/index.php?topic=1910.0

f5soh

  • *****
  • 4572
    • LibrePilot
Re: Sparky 2.0 error
« Reply #12 on: August 22, 2016, 02:24:45 am »
If you are using Linux, try this :
Code: [Select]
make dfuutil_install
make ef_sparky2_dfu

At some point connect the board with SBL pads soldered and remove solder join before restarting board later.