No video, and USB trouble

123 views
Skip to first unread message

artemisbot

unread,
Oct 18, 2012, 3:39:47 PM10/18/12
to fign...@googlegroups.com
Hi all,

My son (13) has just finished building his Fignition.
All went well, including tests and first power up.

We are struggling with two things:
1) We only have LCD displays in the house and couldn't get an image on Fignition startup. We also tried feeding through a VCR with composite in and also a Pinnacle vid cap card. Still no joy. I read Cristian Arezzini's story about switching to NTSC firmware, so I thought we'd give that a go. Which led to problem 2.

2) I tried to install the Windows USBasp driver. I have followed Simon's "Add Legacy Hardware" procedure here https://groups.google.com/forum/#!topic/fignition/tSB_aJW1yVc/discussion and succeeded in installing the driver. However, the Fignition still shows up as an Unknown device and I can't get it to attach the USBasp driver to that device. It looks like Fignition is returning 0000 for Vendor and Device IDs, so I conclude that this is the reason for the failure to associate the driver to the device.

I've attached images of our board and a screenshot that shows the 0000 USB device IDs.
It would be a great help if someone could provide an equivalent screenshot that shows Fignition returning the expected IDs, which I think are: DeviceID   = "VID_16C0&PID_05DC"
Then I'd be pretty convinced that our board has a problem with its IDs.

On startup with the left button pressed, the LED does light and remain lit.
Needless to say, when I try the avrdude command line instruction, I get the "avrdude: error: could not find USB device "USBasp" with vid=0x16c0 pid=0x5dc".

I hope y'all can help us get this baby going.

Thanks!

Andy & Matty

Unknown Device.png
IMG_0016.JPG
IMG_0017.JPG

Carl Attrill

unread,
Oct 25, 2012, 3:32:52 PM10/25/12
to fign...@googlegroups.com
any luck with this yet?

I avoid my win7 PC for all of this- I have a laptop with ubuntu and avrdude compiled onto it. The WIN7 PC moans like hell when I power up the fignition to it via USB.

artemisbot

unread,
Oct 25, 2012, 4:00:26 PM10/25/12
to fign...@googlegroups.com
Hi Carl,

Thanks for reading my post.
Julz has checked over the photos and made some suggestions on dodgy looking joints.
I decided to re-flow every joint to be sure and rechecked all the connections on the test checklist - no problems.

Unfortunately still no luck. We still have no video, nor USB recognition from Windows.
If you wouldn't mind checking for me if you even get non-zero Vendor and Device IDs on your Win 7, I'd really appreciate it.
At this point, I can only assume I have a dud AVR.

Thanks again

Andy

Julian Skidmore

unread,
Oct 25, 2012, 5:41:59 PM10/25/12
to fign...@googlegroups.com
Hi Carl,

I don't have a Windows OS available, so verifying the avrdude setup with Andy would help. The AVR is known to do something when you press SW1 (LED goes on, but the behaviour doesn't sound quite right as there seems to be some delays between releasing SW1 and it going off in some circumstances). One control idea Andrew could try is if he powers it via a USB power supply (e.g. my Hauwei Android phone PSU works as does my Kindle PSU or iPod PSU).

-cheers from julz
--
                             
                  The DIY 8-bit computer from nichemachines™


NmLogoMini.jpg
FIG - black on whiteMini.jpg

Julian Skidmore

unread,
Oct 25, 2012, 5:47:41 PM10/25/12
to fign...@googlegroups.com
Hi Carl,

One other thing, Andrew's FIGnition will be an AtMega168-based one with Revision 0.9.6PAL, so the bootloader LED will stay on steadily while the button is pressed. The AtMega328 bootloader flickers during USB comms.

-cheers from julz
NmLogoMini.jpg
FIG - black on whiteMini.jpg

Carl Attrill

unread,
Oct 26, 2012, 2:44:37 AM10/26/12
to fign...@googlegroups.com
Okay, I will have a try tonight, I assume I can use Burn-o-mat and AVR dude?

Carl Attrill

unread,
Oct 26, 2012, 12:53:20 PM10/26/12
to fign...@googlegroups.com
Okay, I have got the avr working on the WIN7 pc

I managed to get the driver working and flashed the NTSC firmware over to my working FIGnition, the GUI said lovely, thanks.

I plugged it into my LCD monitor and nothing, not a sausage.

I take it to my Ubuntu Laptop to re-flash, but now the AVRdude on that returns the same errors as the First post here.

I recommend that no one flashes with WINDOWS , I need a new 168 chip, how much is one of them? 

I would also imagine that Julz should try sending a pre flashed NTSC chip and your figniton should work. There seems to be a problem with windows flashing, and now my chip has gone gaga I can't get the driver to work as it is not returning the same presence as it once did when plugging in.

Julian Skidmore

unread,
Oct 27, 2012, 5:34:46 AM10/27/12
to fign...@googlegroups.com
Hi Carl,

Hmmm, it's not looking good! Going back to the AVR that returns errors. What happens if you:

* Plug a USB cable into a mobile phone PSU (e.g. Kindle, iPhone or Android phone that uses a USB PSU).

* Hold down SW1 and plug in the USB Cable to the FIGnition with that AVR in it.

Does the LED light up? Also, I recommend doing it in that order, from experience (one experience, at Replay Expo) I have managed to corrupt an AVR by unplugging a phone PSU with the FIGnition still connected.

Do you have ANY FIGnition that still has an AVR with working firmware?

-cheers form julz
FIG - black on whiteMini.jpg
NmLogoMini.jpg

Carl Attrill

unread,
Oct 27, 2012, 6:03:33 AM10/27/12
to fign...@googlegroups.com
The kindle is detected okay as normal, so there is no issues with the usb interface, so thats cool.

I installed the WINusb driver with sw1 pressed all the time, it did once 'drive' but once it wrote the NTSC firmware over it no longer worked.

When I went back to the Linux laptop it said "avrdude: error: could not find USB device "USBasp" ( the light shines ) but the same error comes up when the sw1 is not held too.

Carl Attrill

unread,
Oct 27, 2012, 6:05:22 AM10/27/12
to fign...@googlegroups.com


oh, and I have one working FIGnition still, and that one will accept avrdude, but its not going anywhere near my WIN7 pc for now ;)

Robert Wilkinson

unread,
Oct 28, 2012, 9:24:08 AM10/28/12
to fign...@googlegroups.com
On Sat, Oct 27, 2012 at 10:34:46AM +0100, Julian Skidmore wrote:
> Hi Carl,
>
> Hmmm, it's not looking good! Going back to the AVR that returns errors.
> What happens if you:
>
> * Plug a USB cable into a mobile phone PSU (e.g. Kindle, iPhone or Android
> phone that uses a USB PSU).
>
> * Hold down SW1 and plug in the USB Cable to the FIGnition with that AVR in
> it.
>
> Does the LED light up? Also, I recommend doing it in that order, from
> experience (one experience, at Replay Expo) I have managed to corrupt an
> AVR by unplugging a phone PSU with the FIGnition still connected.

Hello

I had an almost fully-working fignition - it would not save
screens to flash so I looked at the schematic and thought the
joint around R16/R17 was dry so I removed the ICs and resoldered.

Since then the only thing that does work is that the LED lights up
with SW1 pressed. The voltage across U1 is 4.37V, across U2 and U3
is 1.76V - both are low. The only video output is slight distortion
of that I see without the fignition connected.

My initial thought was that I had damaged U1 with static since I saw
such a huge degradation in functionality.

I see
http://www.ebay.co.uk/itm/ATMega168-20PU-AVR-Microcontroller-28-pin-DIP-From-UK-SELLER-/170931967155?pt=UK_Computing_Other_Computing_Networking&hash=item27cc56d4b3
and wonder whether anyone could confirm my prognosis as the likely
cause of my non-working fignition since I would be prepared to pay
that replacement price.

Bob

Julian Skidmore

unread,
Oct 28, 2012, 2:30:38 PM10/28/12
to fign...@googlegroups.com
Hi Robert,

Well, it's good to do some problem-solving. It's possible of course that my circuit has design flaws I'm not aware of, but it's more likely that an open board is relatively vulnerable (like an uncased R-PI).

My FIGnitions undergo quite a bit of abuse with chips being removed from them and swapped around fairly regularly. For example, my normal RevE's U1 socket has a couple of snapped pin clips (you know, the metal clips, one for each pin on the socket). I'm going to have to refit and resolder new clips! I did manage to wreak my bootloader once or twice when doing bootloader or tricky firmware development and had to go back to my ISP, but I've not yet seen the problem you described.

I have seen (as I've noted in this thread) a situation at Replay.com this year where I was demonstrating that the FIGnition was only running from a mobile phone PSU (behind the desk), so I pulled out the PSU from the mains while the FIGnition was still on to demonstrate, and that corrupted the FIGnition's flash. I'm not going to do that again.

My worktop is always an unvarnished wooden one. I usually remove chips using pliars, but sometimes I hold the plastic ends of the packaging of a chip (e.g. index finger at the plastic end where pins 1 and 28 are and thumb at the plastic end where pins 14 and 15 are). I have placed my development chips on the wooden surface sometimes for days while I'm doing other things and on the rare occasions (<5 in 730 kits) when I've accidentally, non-statically safely, knocked RAM/Flash chips during assembly* I replace the chips and relegate the knocked ones to development. I've not had problems with those memory chips; though I do want to do some exhaustive tests on how much abuse they can take.

I don't usually offer replacement AtMega168s; nor encourage sending boards back to be fixed, because I think it's valuable for us all to experience problem solving together and I want customers to discover resources for themselves. For example, I get my AVRs from www.rapidonline.co.uk or Farnell.co.uk and memory chips from Farnell or RS. Both Rapid and RS are happy to supply small orders for components to the public:

http://www.rapidonline.com/Electronic-Components/ATMEGA168-20pu-8-bit-Micro-16k-Dil-28-73-4276

For £2.81, slightly more expensive than the EBAY item or £2.22:

http://www.rapidonline.com/Electronic-Components/ATMEGA328-PU-AVR-8-bit-28-PDIP-73-4281

For the 32Kb version, slightly cheaper than the EBAY item.

Once you've gotten that far, it's a step closer to, say, building a FIGnition FLINT.

I hope this is at least a little helpful, I'm going to work on improving FIGnition recovery options this week though, so stay tuned!

-cheers from julz


* e.g. if I knock the pins of a chip with the metal part of my pliars or accidentally tip the chips back out of a tube onto my preparatory surface (which is currently a rectangle of uncoated corrugated cardboard), I consider that to be OK. If I clip them with the rubber part of the pliars, or a component bag, or tip chips onto a formica surface or touch the pins with the skin of my fingers; then for me that's substandard and I'll replace them with new ones from stock. Here I've described more scenarios than have happened so far, but it's helpful to anticipate.
FIG - black on whiteMini.jpg
NmLogoMini.jpg

Carl Attrill

unread,
Oct 29, 2012, 3:37:01 AM10/29/12
to fign...@googlegroups.com
Robert,
if you are getting a chip via post from Rapid- you need a minium order to get free postage, I can call in at the depot most days so can forawrard one on to a fellow figniton user at normal postage, email me if this is of use to you.

Andy Coomber

unread,
Oct 29, 2012, 4:06:44 AM10/29/12
to fign...@googlegroups.com
Hi julz

If I buy a new blank AVR as suggested in these recent posts, what's the required process and equipment to get the bootloader programmed before we can load the main firmware?

Thanks

Andy

Andy Coomber

unread,
Oct 29, 2012, 4:10:28 AM10/29/12
to fign...@googlegroups.com
Hi Carl,

Sorry you fried your Fignition whilst trying to help me out. TBH, I didn't expect you to go through with the actual programming. I was just looking for confirmation that the USB ids are properly recognised by Windows, before and after the asp driver is installed.
I'm now thinking static damage is my problem and may go ahead with buying a new chip.

Andy

Carl Attrill

unread,
Oct 29, 2012, 10:42:43 AM10/29/12
to fign...@googlegroups.com, coomber...@googlemail.com
Well I was trying to establish the WIN7 as the avr computer as I use it for everything else except AVR programming.
It seems my bootloader has disappeared or something like that, although my one is now behaving exactly like yours, i.e. black screen after burning firmware, so I would still suspect that it is more to do with avr transfer using uncle Bills OS.

The above offer on chips is open to you as well if you decide to buy via rapid electronics, I live near Colchester.

Robert Wilkinson

unread,
Nov 4, 2012, 2:09:06 PM11/4/12
to fign...@googlegroups.com
On Mon, Oct 29, 2012 at 12:37:01AM -0700, Carl Attrill wrote:
> Robert,
> if you are getting a chip via post from Rapid- you need a minium order to
> get free postage, I can call in at the depot most days so can forawrard one
> on to a fellow figniton user at normal postage, email me if this is of use
> to you.

Hi Carl

Thank you for the offer - I will not be able to look at my fignition
for a fortnight but will see when I can.

Bob

Robert Wilkinson

unread,
Nov 13, 2012, 4:37:58 PM11/13/12
to fign...@googlegroups.com
On Mon, Oct 29, 2012 at 08:06:44AM +0000, Andy Coomber wrote:
> Hi julz
>
> If I buy a new blank AVR as suggested in these recent posts, what's the required process and equipment to get the bootloader programmed before we can load the main firmware?
>
> Thanks
>
> Andy

Hello Julz

Please can I re-iterate Andy's question here since I did not see a
reply?

I naively assumed that I would be able to replace the AVR and then
the fignition would be visible as a USB device so that I could then
install the firmware (via T2E2?).

I may, however, be completely wrong in my presumption...

Bob

artemisbot

unread,
Nov 13, 2012, 4:46:09 PM11/13/12
to fign...@googlegroups.com
Hi Bob,

I've made a _little_ progress on understanding what to do.
I'm currently looking into using an Arduino as an ISP to load Julz' bootloader, following this process:
http://arduino.cc/en/Tutorial/ArduinoISP

'Other ISPs are available' as they say :-)
Try googling "AVR Programming" to read all about it.

The bootloader hex file, I think, is the one listed on this page:
https://sites.google.com/site/libby8dev/fignition

I'll let you know how I get on.

Andy

Julian Skidmore

unread,
Nov 13, 2012, 5:01:56 PM11/13/12
to fign...@googlegroups.com

hi andy, just a quick reply for now. replacing the avr with a blank one won't work as it needs the bootloader.

i've been working on making recovery a little better. the first step is a little shield that turns the figgy into an isp - i have some firmware and a half-built shield (to be finished tomorrow)

the other option is something else i've been looking into, which i call a bitstrapper. stay tuned and keep posting, i haven't forgotten!

cheers julz

Julian Skidmore

unread,
Nov 13, 2012, 5:04:01 PM11/13/12
to fign...@googlegroups.com

hi andrew, the posted bootloader is the one for the atmega168, i don't think the other one is up yet. cheers julz

artemisbot

unread,
Nov 13, 2012, 5:59:13 PM11/13/12
to fign...@googlegroups.com
Thanks Julz

Lucky my board has a 168 then :-)

I surprised myself and managed to successfully reprogram the bootloader using two Arduino UNOs conected together as shown in the first image on this page: http://arduino.cc/en/Tutorial/ArduinoISP
My 168 from the FIGnition was in the slave board. And the ArduinoISP code was programmed into the first UNO using the Arduino IDE.
I followed the instructions in the Sparkfun tutorial http://www.sparkfun.com/tutorials/200 and the command
avrdude -P COM4-b 19200 -c avrisp -p m168 -v -e -U flash:w:FIGnitionBootloader.hex worked just fine and programmed the bootloader with no problems.

I guess this is really where you're going with your "recovery plan", but using only FIGnitions. At least we know the principle works.

The bad news? My FIGNition still isn't recognised on USB (no vendor or device code).

BTW, is there anything special I have to do to configure AVR fuses or are they embodied in your bootloader code?

I'm pretty much out of ideas now, unless I can solve my 'scope mystery or maybe start replacing C1, D3 & D4. But I've tested the Ds already I think and found no problems.

Andy

carl

unread,
Nov 14, 2012, 2:52:57 AM11/14/12
to fign...@googlegroups.com
I have two Arduino Uno_s so I would like to see if this is worthwhile too, sounds like my one still wont work If I copied your method right now.

Julian Skidmore

unread,
Nov 14, 2012, 4:20:13 AM11/14/12
to fign...@googlegroups.com
Hi Andy,

The AtMega168 needs these fuse settings:

Fuse Low=0xd7 = CKDIV=1, CKOUT=1 (unprog'd), SUT1:SUT0=01, CKSEL=7 (Full Swing External Crystal)
Fuse High=0xd6 = External Reset Enabled + External DebugWIRE Disabled + Enable Serial Program and Data Downloading (i.e. via SPI) + Watchdog off + EEPROM not preserved + Brownout=6.
Fuse Extended=0xf8 = BootSz=2Kb, BOOTRST=0x3800 ( byte address, 0x1C00 word addr).

The AtMega328 fuses are set with the following settings:

Fuse Low= 0xd7 CKDIV=1, CKOUT=1 (unprog'd), SUT1:SUT0=01, CKSEL=7 (Full Swing External Crystal)
Fuse High= 0xd2 (RSTDISBL:DWEN:!SPIEN:WDTON:EESAVE:BootSz=1Kw)
Fuse Extended= 0xff (BOD7)

-cheers from julz
FIG - black on whiteMini.jpg
NmLogoMini.jpg

artemisbot

unread,
Nov 14, 2012, 8:00:19 AM11/14/12
to fign...@googlegroups.com
Thanks Julz

How can I check and/ or modify these settings please?
I have now confirmed that there is clean-looking USB traffic incoming.
No idea if the bootloader is responding yet though.

Could you confirm that the bootloader code alone supports USB, without the rest of the firmware being present?
I assume it's bit-bashed in code, right?

I'll upload some scope pics of USB traffic and crystal behaviour later.

Andy

Julian Skidmore

unread,
Nov 14, 2012, 9:17:57 AM11/14/12
to fign...@googlegroups.com
Hi Andy,


How can I check and/ or modify these settings please?

The settings are modified by your ISP tool. This means that if you, say use the Arduino as an ISP then there will be options to set the fuses (from avrdude) or if the target firmware is embedded in the arduino firmware (yes, there's an arduino ISP technique which involves embedding hex data in an arduino sketch and the sketch reads the hex data); then there should be a means of embedding the fuse settings too.
 
I have now confirmed that there is clean-looking USB traffic incoming.

Cool!
 
No idea if the bootloader is responding yet though.

Could you confirm that the bootloader code alone supports USB, without the rest of the firmware being present?
I assume it's bit-bashed in code, right?

Yes, it's just the V-USB usbasp bootloader with the Jumper set to SW1 and the LED set when in the bootloader (on the AtMega328 version it inverts for every 32 packets loaded):

http://www.obdev.at/products/vusb/index.html

-cheers from julz

 
I'll upload some scope pics of USB traffic and crystal behaviour later.

Thanks.

-cheers from julz
 
FIG - black on whiteMini.jpg
NmLogoMini.jpg

artemisbot

unread,
Nov 14, 2012, 5:03:01 PM11/14/12
to fign...@googlegroups.com
SUCCESSSSSS!!

I used avrdude to check the fuse settings on my 168 using:
avrdude -P COM4 -b 19200 -c avrisp -p m168 -n -U hfuse:r:high.txt:i -U lfuse:r:low.txt:i -U efuse:r:ext.txt:i

Result:
Low: 0xFF 
High: 0xDD
Ext: 0x00

Wrong! Must have got lost somewhere along the way. 

I reprogrammed them to the correct values specified by Julz:
avrdude -P COM4 -b 19200 -c avrisp -p m168 -U lfuse:w:0xD7:m -U hfuse:w:0xD6:m -U efuse:w:0xF8:m
Low: 0xD7 
High: 0xD6
Ext: 0xF8

This failed on efuse, always reading back 0x00. 
Then I read this somewhere: "Bits 3 to 7 of efuse will always read 0 - they are not used."
So, I concluded that 0xF8 (1111 1000) is the same as 0x00 (0000 0000)" and decided to test my USB again.

Installed the 168 back in my FIGnition and connected to Windows PC, held down SW1 and USBasp driver was found and installed.
Next I programmed the NTSC firmware using avrdude:
avrdude -c usbasp -p m168 -u -U flash:w:FirmwareRev0_9_7NTSC.hex

Hooked up to my mini LCD screen and everything works.
See photo for proof :-)

Thanks for helping, everyone.

I now have 'da knowledge' on FIGnition bootloader and fuse programming using two Arduinos, and how to program firmware from a Windows PC, so if anyone needs help with this, I _might_ be able to assist.

Andy
FIGnition.jpg

Julian Skidmore

unread,
Nov 14, 2012, 5:05:26 PM11/14/12
to fign...@googlegroups.com
Hi Andy,

WELL DONE!!!!!!!!!!!!!!!! Many Congratulations!!!!!

:-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-) :-)

-cheers from julz
NmLogoMini.jpg
FIG - black on whiteMini.jpg

carl

unread,
Nov 14, 2012, 5:08:31 PM11/14/12
to fign...@googlegroups.com
well done, now to use one of those arduinos for a keyboard ;)
Hopefully my 168 chip will follow soon.

artemisbot

unread,
Nov 14, 2012, 5:18:58 PM11/14/12
to fign...@googlegroups.com
Hi Carl

If you decide to go the Arduino route, there are a couple of points to note.
The 10uF cap, I decided, needs to go between Reset and GND on the slave Arduino board, that has the target AVR installed.
See attached photo for my wiring of this.
Also, you should only follow up to and including step 5 of the instructions on this page:
Then, switch to avrdude on the command line and do this:
avrdude -P COM4 -b 19200 -c avrisp -p m168 -v -e -U flash:w:FIGnitionBootloader.hex

HTH

Andy
cap.jpg
Reply all
Reply to author
Forward
0 new messages