Adafruit Metro


#1

My Eagle eye (pun intended) has spotted the tasty Adafruit Metro going up in the shop (I know, I need a life!).

Very basic questions:

  1. it’s basically a Uno R3 design (right), so that means that the Shields made for UnoR3 are going to be compatible?

  2. do you know if there is enough clearance on the top for a mini-breadboard, to be stuck on top of the SMD. If there is, what about heat dissipation, would that be a concern, which the chip so tightly enclosed?


#2

hum, thinking about I guess there is nothing that should stop me soldering all headers from the bottom and using the PCB upside down (with ad hoc stand-offs)?

… I know, I know, but what is a man to do to kill boredom otherwise?


#3

for enquiring minds:

  1. not a chance to fit a 170 pts breadboard on top, smaller maybe (and still be clear to fit shield, hopefully)

  2. err, not a good idea to solder from the bottom, that would reverse out the shields connections.


#4

right I am getting absolutely nowhere with this one. I have it all assembled and it powers on just fine but I can’t flash it using the Arduino IDE (1.6.4 on Mac and 1.6.3 on Raspbian). I have the Adafruit Metro board and my USB serial cable selected.

On Mac the upload process stalls indefinitely and on Raspbian I get the infamous ‘not in sync’ message. I am 100% sure the connections are right since on Mac, if I press the reset button on the board the upload attempt aborts.

Even stranger, when I try to probe the SPI with avrdude as soon as I wire both MOSI and SCLK the red L starts flashing rapidly on the Metro, as if it was resetting constantly. Either way avrdude tells me there is no device.

Again, I am 100% sure my connections are right as I get the same thing whether I use the ICSP or pins 11-12-13+reset.

Anyhow, I don’t think I am being an idiot, but trawling the Adafruit site has led to no site of an answer.


#5

right, the flashing LED I think is just PB5… still makes no sense as to why it should behave that way when you hook up SPI cables. I’ll wait to hear before I probe further…


#6

Curious! I always pick up an Arduino Uno because they’re usually no hassle at all to upload code onto.

In Arduino IDE you should try selecting the Uno board and the correct com port ( is it showing up as a serial device? ) and try again.


#7

today I have just leant that you can hook up the Metro directly via USB? I thought you had to use a serial to USB?

Anyhow, it’s not picking it up as this thread seems to indicate:

https://forums.adafruit.com/viewtopic.php?f=25&t=73946&p=375002&hilit=metro#p375002

could the bootloader be bricked?


#8

oh, oh, hold on… using UNO and the Prolific PL2303 serial driver did work - but I had to press the reset button.

Is this normal? Anyhow, you’re the best!


#9

Pretty sure it’s not normal to need to press the rest button on an UNO.

But, yes, you can hook up directly via USB and I’m sure it should just show up as a regular serial port using generic drivers.

If you plug it in, do you see it in lsusb on the Mac, and in ls /dev/tty* ?


#10

no, what I see there matches what Arduino IDE lists in term of ports


#11

actually when I say it works, well, it did once, but now it’s not doing much again. When it did upload this is what avrdude output (verbose) spit out, in case there is anything useful in there:

    Using Port                    : /dev/cu.Repleo-PL2303-00001014
     Using Programmer              : arduino
     Overriding Baud Rate          : 115200
     AVR Part                      : ATmega328P
     Chip Erase delay              : 9000 us
     PAGEL                         : PD7
     BS2                           : PC2
     RESET disposition             : dedicated
     RETRY pulse                   : SCK
     serial program mode           : yes
     parallel program mode         : yes
     Timeout                       : 200
     StabDelay                     : 100
     CmdexeDelay                   : 25
     SyncLoops                     : 32
     ByteDelay                     : 0
     PollIndex                     : 3
     PollValue                     : 0x53
     Memory Detail                 :

                              Block Poll               Page                       Polled
       Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
       ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
       eeprom        65    20     4    0 no       1024    4      0  3600  3600 0xff 0xff
       flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff
       lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
       hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
       efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
       lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
       calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
       signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00

     Programmer Type : Arduino
     Description     : Arduino
     Hardware Version: 3
     Firmware Version: 4.4
     Vtarget         : 0.3 V
     Varef           : 0.3 V
     Oscillator      : 28.800 kHz
     SCK period      : 3.3 us

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f
avrdude: reading input file "/var/folders/q6/_ttsczln7qsgxsx2qfzg0dy40000gp/T/build4707864911383072670.tmp/Blink.cpp.hex"
avrdude: writing flash (1030 bytes):

Writing | ################################################## | 100% 0.15s

avrdude: 1030 bytes of flash written
avrdude: verifying flash memory against /var/folders/q6/_ttsczln7qsgxsx2qfzg0dy40000gp/T/build4707864911383072670.tmp/Blink.cpp.hex:
avrdude: load data flash data from input file /var/folders/q6/_ttsczln7qsgxsx2qfzg0dy40000gp/T/build4707864911383072670.tmp/Blink.cpp.hex:
avrdude: input file /var/folders/q6/_ttsczln7qsgxsx2qfzg0dy40000gp/T/build4707864911383072670.tmp/Blink.cpp.hex contains 1030 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 0.11s

avrdude: verifying …
avrdude: 1030 bytes of flash verified


#12

tried on another Mac (running 10.9 rather than 10.10) and the Pi, connected direct from USB-Metro to USB on host… not listed in lsusb either. I guess that means that the USB to serial converter is buggered?

… I wouldn’t really mind but given that I can’t upload code via RX/TX reliably where do we go from here?


#13

brw, there must have been a ‘demo program’ pre-loaded, or at least pin11 was in PWM mode out of the box as after uploading successfully (my 1 success yeah!) the Blink example (and getting the expected result) hooking up pin 11 and 13 at the same time no longer flashes the on-board R LED at a mad rate.

… still, after trying again to probe the ATmega328 via SPI and the Pi GPIO I am told there is no device to communicate with (though I can see the MOSI activity on the board, it being linked to PB5). Works a thread with my barebone ‘Shrimp’ so I’m pretty sure I am fluent enough at this point to say it’s not a pilot error…


#14

When trying over USB, have you tried a different USB cable? I’ve had dodgy cables trip me up before.

Also, if you populated the ICSP header to program over SPI, double-check the solder joints. A flaky connection will totally ruin your day.

Otherwise… it’s possible you got a duff board and we’ll replace it.


#15

I’ve tried a couple of cables as well as different means to (safely) power up the board, yes. I will go through my box though and see if any other give me more satisfaction.

Regarding ICSP my understanding is that they are breakout for 11-12-13+reset, but I’ve soldered the dedicated connector after my LED weirdness experience and same results both ways.

I am using:
avrdude -p m328p -c gpio
… I also tried:
avrdude -p atmega328p -c gpio
(after noticing that is what the Arduino IDE pass it as argument)

avrdude is at version 5.10 if that matters.


#16

Looks like you’re doing everything right! Quite surprised it’s a DOA board, since AVRs are pretty durable-

I’m gonna go grab a Metro and make sure it works. Can you bung a quick summary email to support@pimoroni.com to make sure it’s in “The System”?


#17

np… just to make matters complicated though, I have used stacking headers, not what came with the board. Not sure what that means, can you replace with the same set?


#18

The board has headers with regular height pins on them. I’m don’t think we have any stacking headers. I suspect they wouldn’t be much fun to de-solder either.

Does this mean you’ve now got a Metro Arduino Shield…?


#19

yes, pretty much so… a ‘classic style’ (2x6 on one side and 2x8 on the other)


#20

That’s basically what 1Sheeld does, it’s an AVR that sits on top of an AVR and pretends to be other things. Clever stuff!

Got a tested Metro ready on my desk.