Base sketch won't upload

The more technical aspects of Spirit, and carry-over discussion from Kickstarter updates.
Bastian
Posts: 21
Joined: Sun Oct 22, 2017 5:30 pm
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Base sketch won't upload

Postby Bastian » Sat Feb 10, 2018 6:35 pm

Hi,

I idownloaded CDM21216_Setup.exe from the site and installed the usb driver.
Halas, when I try to upload the Spirit_BaseSketch_PiControl_Rev01.ino, I get the notorious averdude stk500_recv() error:
----------------------------------------------------------------------------------------------------------------------
Arduino: 1.6.9 (Windows 10), Board:"Arduino/Genuino Uno"
De schets gebruikt 7.714 bytes (23%) programma-opslagruimte. Maximum is 32.256 bytes.
Globale variabelen gebruiken 469 bytes (22%) van het dynamisch geheugen. Resteren 1.579 bytes voor lokale variabelen. Maximum is 2.048 bytes.
avrdude: Version 6.0.1, compiled on Apr 15 2015 at 19:59:58
Using Port : COM4
Using Programmer : arduino
Overriding Baud Rate : 115200
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0xc3
avrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0xc3
avrdude done. Thank you.
-----------------------------------------------------------------------------------------------------------------------------
It’s the first time since assembly that I tried to upload a sketch (I was waiting for the PI-interface).

As mentioned in other posts and the Ringo & Wink pages, I surely tried the Pro/pro-mini versions 8Mhz and 16 Mhz and a lot of the other Arduino configurations, but all with the same result. And of course several re-installs of the usb driver.

‘ Years ago’ ;-) I could solve this issue by using another Arduino as programmer. I don’t know how I could manage this on the Spirit board (just a USB connector).
Does anyone know a workaround?
Last edited by Bastian on Sat Feb 10, 2018 9:48 pm, edited 1 time in total.

gpvillamil
Posts: 75
Joined: Fri Jan 26, 2018 5:03 pm
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Re: Base sketch won't upload

Postby gpvillamil » Sat Feb 10, 2018 9:47 pm

Set the board type to “Arduino Pro or Pro Mini” and the processor type to “ATMega328p 3.3v 8mhz”

Bastian
Posts: 21
Joined: Sun Oct 22, 2017 5:30 pm
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Re: Base sketch won't upload

Postby Bastian » Sat Feb 10, 2018 10:51 pm

ThnX for your answer. this question just contains some output of the "UNO-trial" I tried the other boards and processors extensively, every time reinstalling the driver as well. Tried a newer version of the driver (CDM21228). Halas nothing works. I'll wait for some time for answers and probably dismantle the Pi and leave the rest of SPirit for what it is for me. ;-(

gpvillamil
Posts: 75
Joined: Fri Jan 26, 2018 5:03 pm
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Re: Base sketch won't upload

Postby gpvillamil » Sun Feb 11, 2018 12:34 am

Update to Arduino 1.8.5

Bastian
Posts: 21
Joined: Sun Oct 22, 2017 5:30 pm
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Re: Base sketch won't upload

Postby Bastian » Sun Feb 11, 2018 8:17 pm

Good suggestion to upgrade the ide: it comes with the adafruit usb driver. But unfortunately: ik keep getting the uploader error: avrdude: stk500_recv(): programmer is not responding, avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x96.

I think I now tried all possible combinations of boards, drivers and ide's (I usualy work with Visual Studio). I know how to burn a sketch using another Arduino as programmer, but there are no pins on the spirit board to connect it to. The demo sketch produces strange I2C values (see other problems) and won't work with spirit_core.py, So it feels as a dead end street. Any suggestion is more than welcome!

gpvillamil
Posts: 75
Joined: Fri Jan 26, 2018 5:03 pm
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Re: Base sketch won't upload

Postby gpvillamil » Sun Feb 11, 2018 9:03 pm

Did you also select processor type, not just board?

Arduino pro w atmega328p 3.3v is working for me w MacOs, Windows and Linux.

User avatar
esba1ley
Posts: 58
Joined: Sun Jan 01, 2017 2:15 am
Location: Pasadena, CA
Contact:

Re: Base sketch won't upload

Postby esba1ley » Sun Feb 11, 2018 9:07 pm

Bastian:

See this thread:

viewtopic.php?f=18&t=7897

But the bottom line is I got it work with the Arduino IDE, with these settings in the pull-down menus:

Board: "Arduino Pro or Pro Mini"
Processor: "ATMega328 (3.3V, 8Hz)"
Programmer: "ArduinoISP"

Are you using avrdude outside of the IDE? I can sleuth down what the settings should be for that command line tool...
----------
Erik S. Bailey
Entry, Descent, and Landing Aerospace Engineer
Maker, and Musician
SpiritRover Kickstarter Backer #460

Bastian
Posts: 21
Joined: Sun Oct 22, 2017 5:30 pm
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Re: Base sketch won't upload

Postby Bastian » Sun Feb 11, 2018 9:47 pm

Yep I used exactly those params. I also tried Arduino duemilanove as board for this board has a special usb virtual usb programmer. Out of pure boredom I also tried every other arduino board/processor combination. Useless of course, but just to exclude possibilities. Years ago the small Dagu boards also used a virtual usb and produced the same error. Then using a second arduino as programmer was the only way to get some sketch loaded.

Without the ability to load a sketch I'm stuck with the buggy I2C behaviour. Reducing the I2C speed to 100K didn't work (btw: 400K and 1M didn't work as well). Every python script that requests info from the sensors (lightsense, rangefinder, voltage) gets FF (i.e.: [255,255,255,255,255] Length of the list depends on the request and I2C speed)

I'll set spirit aside for a while now. ALthough cute, at this point for me it's a rather restricted toy with bugs. I'll spend my scarse free time on one of my other hobby projects: a sort of rover with a rocker-bogie dispension, location and mapping based on Lidar Lite pointcloud, IMU data and openCV deep learning object tracking.

User avatar
esba1ley
Posts: 58
Joined: Sun Jan 01, 2017 2:15 am
Location: Pasadena, CA
Contact:

Re: Base sketch won't upload

Postby esba1ley » Sun Feb 11, 2018 10:18 pm

That's really odd... I've programmed many AVR uCs, and avrdude usually works, provided that the fuses didn't get horked up somehow. (Then you HAVE to do an ISP connection, or worse, a dedicated chip programmer).

Just so we can be sure we're not missing something that seems obvious to you, but isn't to us, what is your specific setup? Is it possible that by loading another non-Arduino driver for USB that you've mucked something up on the Windows side? Admittedly, I'm not a Windows expert (Linux and MacOS only spoken here...) but I defer to those who are.

Can anyone else help out Bastian here?
----------
Erik S. Bailey
Entry, Descent, and Landing Aerospace Engineer
Maker, and Musician
SpiritRover Kickstarter Backer #460

gpvillamil
Posts: 75
Joined: Fri Jan 26, 2018 5:03 pm
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Re: Base sketch won't upload

Postby gpvillamil » Mon Feb 12, 2018 1:25 am

Yeah, what Erik says.

Try removing any non-Arduino drivers, and do a clean install of the Arduino IDE. Verify that you are using the correct COM port. (Open the Device Manager, plug in the the rover, and see which COM port appears.)


[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Who is online

Users browsing this forum: No registered users and 28 guests