Author Topic: Programming and flashing firmware (ps2avr)  (Read 16415 times)

0 Members and 1 Guest are viewing this topic.

Offline WhiteFireDragon

  • Thread Starter
  • Posts: 2276
    • youtube
Programming and flashing firmware (ps2avr)
« on: Sat, 08 June 2013, 08:34:57 »
I already soldered on the main components needed, but I have no idea how to program and flash the firmware to this ps2avr. There is no idiot-proof button to press like phantom or GH60 to flash it. This uses the ATMEGA32A chip, and has ISP headers. I attached the precompiled firmware file at the bottom, but how do I flash it onto the MCU? A guide or step by step instructions would be much appreciated.

I'm the first to build this on GH, but several people just got this PCB as well, so this should help anyone else building one of these in the future.


24737-0
« Last Edit: Sat, 08 June 2013, 08:39:08 by WhiteFireDragon »

Offline Soarer

  • * Moderator
  • Posts: 1918
  • Location: UK
Re: Programming and flashing firmware (ps2avr)
« Reply #1 on: Sat, 08 June 2013, 08:45:55 »
http://www.ladyada.net/learn/avr/programmers.html ;)

If you have a Teensy knocking around, you might be able to get it to do the programming using the LUFA based code - http://www.fourwalledcubicle.com/AVRISP.php

But far simpler to just buy one  :))
« Last Edit: Sat, 08 June 2013, 08:56:23 by Soarer »

Offline alaricljs

  • I be WOT'ing all day...
  • ** Moderator Emeritus
  • Posts: 3715
  • Location: NE US
Re: Programming and flashing firmware (ps2avr)
« Reply #2 on: Sat, 08 June 2013, 09:46:59 »
Did this with the 456GT, lots of fun...

Used this guide to get the teensy setup and able to run the Arduino ISP sketch.  An important item was apparently the fuse bit settings, hopefully they provided that info? 

avrdude flags to set fuses:  -U hfuse:w:0xD7:m -U lfuse:w:0x0E:m
« Last Edit: Sat, 08 June 2013, 09:48:58 by alaricljs »
Filco w/ Imsto thick PBT
Ducky 1087XM PCB+Plate, w/ Matias "Quiet Click" spring-swapped w/ XM Greens

Offline WhiteFireDragon

  • Thread Starter
  • Posts: 2276
    • youtube
Re: Programming and flashing firmware (ps2avr)
« Reply #3 on: Sat, 08 June 2013, 15:42:03 »
^ Thanks! I'll try that out. I already have a breadboard, jumpers, and a teensy to try what you did. Although, I only have a win7 PC so is this still possible? Not going to learn other OS just to do this.

Offline pasph

  • Posts: 1059
  • Location: Italy
Re: Programming and flashing firmware (ps2avr)
« Reply #4 on: Sat, 08 June 2013, 16:03:51 »
just a question: the controller in the pcb that gon ship has a firmware pre-installed?
"There is more stupidity than hydrogen in the universe, and it has a longer shelf life"

Offline WhiteFireDragon

  • Thread Starter
  • Posts: 2276
    • youtube
Re: Programming and flashing firmware (ps2avr)
« Reply #5 on: Sat, 08 June 2013, 16:07:56 »
No, it's blank, nothing preinstalled. All components and PCB were separate, I had to solder them on the PCB. That's all done, so now I'm stuck at figuring out how to flash the firmware onto the controller.

Offline pasph

  • Posts: 1059
  • Location: Italy
Re: Programming and flashing firmware (ps2avr)
« Reply #6 on: Sat, 08 June 2013, 16:15:29 »
I think he should warn all his potential buyers about this little detail
"There is more stupidity than hydrogen in the universe, and it has a longer shelf life"

Offline Soarer

  • * Moderator
  • Posts: 1918
  • Location: UK
Re: Programming and flashing firmware (ps2avr)
« Reply #7 on: Sat, 08 June 2013, 16:17:49 »
I dunno if it was, but it could still have been programmed if you got it as a kit - it's easy enough for someone to program them while they're loose. Otherwise, what pasph said!

Hell, if all else fails remove the AVR chip and wire the Teensy in instead, for some USB goodness :p

Offline WhiteFireDragon

  • Thread Starter
  • Posts: 2276
    • youtube
Re: Programming and flashing firmware (ps2avr)
« Reply #8 on: Sat, 08 June 2013, 17:01:52 »
I think he should warn all his potential buyers about this little detail
I dunno if it was, but it could still have been programmed if you got it as a kit - it's easy enough for someone to program them while they're loose. Otherwise, what pasph said!

Hell, if all else fails remove the AVR chip and wire the Teensy in instead, for some USB goodness :p


It was not preprogrammed, I checked before making this thread. How do you program it when it's loose? the pins are too small, and they're also surface-mounted pins, so I can't plug it into prototyping breadboard or clamp a wire on it to flash before soldering.

I soldered one PCB, the other still has loose components. Here's also a size comparison of the pins between the atmega32A chip and teensy. How do I plug in those tiny pins somewhere to program it prior to soldering?

   
« Last Edit: Sat, 08 June 2013, 17:06:47 by WhiteFireDragon »

Offline codyeatworld

  • * Destiny Supporter
  • Posts: 944
  • Location: Bay Area, California
Re: Programming and flashing firmware (ps2avr)
« Reply #9 on: Sat, 08 June 2013, 17:04:27 »
I think he should warn all his potential buyers about this little detail

He told me my PCB will have firmware written.




Offline pasph

  • Posts: 1059
  • Location: Italy
Re: Programming and flashing firmware (ps2avr)
« Reply #10 on: Sat, 08 June 2013, 17:15:04 »
I think he should warn all his potential buyers about this little detail

He told me my PCB will have firmware written.

Maybe if you buy from him also the soldering service (at least controller + diodes) he preflash it?
"There is more stupidity than hydrogen in the universe, and it has a longer shelf life"

Offline Soarer

  • * Moderator
  • Posts: 1918
  • Location: UK
Re: Programming and flashing firmware (ps2avr)
« Reply #11 on: Sat, 08 June 2013, 17:22:12 »
How do I plug in those tiny pins somewhere to program it prior to soldering?

For you, the easiest route now is to solder it and then program it.

For someone sending out kits, it wouldn't be unreasonable for them to buy one of these (or just the socket part without PCB) and split the cost across all kits.

Offline alaricljs

  • I be WOT'ing all day...
  • ** Moderator Emeritus
  • Posts: 3715
  • Location: NE US
Re: Programming and flashing firmware (ps2avr)
« Reply #12 on: Sat, 08 June 2013, 17:37:16 »
... I only have a win7 PC so is this still possible? Not going to learn other OS just to do this.



Yes, mine is win7 x64.
Filco w/ Imsto thick PBT
Ducky 1087XM PCB+Plate, w/ Matias "Quiet Click" spring-swapped w/ XM Greens

Offline WhiteFireDragon

  • Thread Starter
  • Posts: 2276
    • youtube
Re: Programming and flashing firmware (ps2avr)
« Reply #13 on: Sat, 08 June 2013, 20:31:40 »
For someone sending out kits, it wouldn't be unreasonable for them to buy one of these (or just the socket part without PCB) and split the cost across all kits.

I considered getting one until I saw the $100 price tag that can't be seen at first. That's a relatively simple device too, it's just a breakout board. The only expensive part looks like the bracket.

I'll play around with what alaricljs linked to see if I can get this thing working.
« Last Edit: Sat, 08 June 2013, 20:36:56 by WhiteFireDragon »

Offline alaricljs

  • I be WOT'ing all day...
  • ** Moderator Emeritus
  • Posts: 3715
  • Location: NE US
Re: Programming and flashing firmware (ps2avr)
« Reply #14 on: Sat, 08 June 2013, 20:35:23 »
Made in Japan!!!!
Filco w/ Imsto thick PBT
Ducky 1087XM PCB+Plate, w/ Matias "Quiet Click" spring-swapped w/ XM Greens

Offline mkawa

  •  No Marketplace Access
  • Posts: 6562
  • (ツ)@@@. crankypants
Re: Programming and flashing firmware (ps2avr)
« Reply #15 on: Sat, 08 June 2013, 20:42:43 »
there's always soldering it down to a brown dog, then desoldering it when you're done programming :D (lolz)

ps, i really really hate the a87

to all the brilliant friends who have left us, and all the students who climb on their shoulders.

Offline hasu

  • Posts: 3472
  • Location: Tokyo, Japan
  • @tmk
    • tmk keyboard firmware project
Re: Programming and flashing firmware (ps2avr)
« Reply #16 on: Sat, 08 June 2013, 22:20:52 »
Made in Japan!!!!

ha, at least Made in Japan usually works as spec they insist :)

This cheap breakout PCB will work instead.
Just push down the chip during programming, without soldering.
http://www.adafruit.com/products/1162

Offline SmallFry

  • ** Moderator Emeritus
  • Posts: 3887
  • Location: Wisconsin, USA
  • Leaving 6/15; returning 6/22 or so.
Re: Programming and flashing firmware (ps2avr)
« Reply #17 on: Sat, 08 June 2013, 22:22:31 »
You could also pickup a cheap ISP programmer. I don't know why that wouldn't work.

Offline ItsBc

  • Posts: 90
  • Location: Irvine, California
  • BARACOOT
    • Portfolio
Re: Programming and flashing firmware (ps2avr)
« Reply #18 on: Wed, 12 June 2013, 00:04:19 »
The pcb that I sent to WFD was from zenuty by the way, not GON. I don't know if GON's chips are flashed or not. Just wanted to clear that up.

Offline zenuty

  • Posts: 577
  • Location: South of Korea
  • WTS : Duck, Pla, Acrylic 3 Pokers
Re: Programming and flashing firmware (ps2avr)
« Reply #19 on: Wed, 12 June 2013, 00:44:02 »
LINE ID : zenuty
Skype ID : zenuty
www.facebook.com/zenuty

Offline The_Beast

  • * Maker
  • Posts: 3964
  • Location: Wisconsin
  • I like wood ಠ_๏
Re: Programming and flashing firmware (ps2avr)
« Reply #20 on: Sun, 30 June 2013, 01:25:16 »
So any step by step guides?


My A.87 is just sitting here waiting to be programmed....
Vendor Status: Sadly, not taking any orders/pre-orders at this time

Vendor Quick Links: | Vendor Forum | Hardwood Wrist Rests | Hardwood 60% Cases | Customer Gallery | Giveaway |

Offline emptythecache

  • Posts: 629
  • out.
Re: Programming and flashing firmware (ps2avr)
« Reply #21 on: Wed, 03 July 2013, 05:38:14 »
I don't know if this is relevant to this topic, but how different is this task for the usb a.87 pcb? Is there a guide/firmware around anywhere for that?

Offline domoaligato

  • * Exquisite Elder
  • Posts: 1672
  • Location: USA
  • All your base are belong to us!
    • All your base are belong to us!

Offline alaricljs

  • I be WOT'ing all day...
  • ** Moderator Emeritus
  • Posts: 3715
  • Location: NE US
Re: Programming and flashing firmware (ps2avr)
« Reply #23 on: Tue, 09 July 2013, 07:47:14 »
Basically A87 ps2avr Firmware is completed.

http://ps2avr.sourceforge.net/

firmware_MX_mini_ps2avr_V02.zip : FrimWare V0.2
http://www.kbdmania.net/xe/?module=file&act=procFileDownload&file_srl=6229615&sid=0f631ab9a759002c03b090f387b1fe87

So an A87 is the same as an MX mini?  If this statement is true, then here's the directions:

DIY ISP

Install arduino software, load up the ISP sketch onto your teensy.

C:\arduino-1.0.3\hardware\tools\avr\bin>avrdude.exe -p m32 -c arduino -P com3 -U hfuse:w:0xD0:m -U lfuse:w:0xCF:m -C c:\arduino-1.0.3\hardware\tools\avr\etc\avrdude.conf

C:\arduino-1.0.3\hardware\tools\avr\bin>avrdude.exe -p m32 -c arduino -P com3 -C c:\arduino-1.0.3\hardware\tools\avr\etc\avrdude.conf -U flash:w:firmare.hex:a



Filco w/ Imsto thick PBT
Ducky 1087XM PCB+Plate, w/ Matias "Quiet Click" spring-swapped w/ XM Greens

Offline domoaligato

  • * Exquisite Elder
  • Posts: 1672
  • Location: USA
  • All your base are belong to us!
    • All your base are belong to us!
Re: Programming and flashing firmware (ps2avr)
« Reply #24 on: Tue, 09 July 2013, 11:24:06 »
from what I have been reading you flash all ps2avr based boards the same.
A.87 ps2avr
MX-mini ps2avr
thumb

they just require different hex files.

Offline Sifo

  • Alter
  • * Exquisite Elder
  • Posts: 7487
  • Location: #GOLDSPRINGS, #LEGITBALLIN
  • Illustrious
Re: Programming and flashing firmware (ps2avr)
« Reply #25 on: Wed, 17 July 2013, 23:50:31 »
EDIT: well... wrong thread
« Last Edit: Wed, 17 July 2013, 23:52:09 by Sifo »
I love Elzy

Offline WhiteFireDragon

  • Thread Starter
  • Posts: 2276
    • youtube
Re: Programming and flashing firmware (ps2avr)
« Reply #26 on: Thu, 18 July 2013, 00:11:55 »
Ok I'm going to turn my teensy into an ISP programmer. Can someone verify my connections are correct to flash?


 

Offline ItsBc

  • Posts: 90
  • Location: Irvine, California
  • BARACOOT
    • Portfolio
Re: Programming and flashing firmware (ps2avr)
« Reply #27 on: Fri, 19 July 2013, 05:28:01 »
zenuty said he sold this PCB to 20 other people on GH, and they had no problems.  :mad:
where are these 20 other people, did they get their firmware flashed; how?

Offline Soarer

  • * Moderator
  • Posts: 1918
  • Location: UK
Re: Programming and flashing firmware (ps2avr)
« Reply #28 on: Fri, 19 July 2013, 06:00:37 »
Ok I'm going to turn my teensy into an ISP programmer. Can someone verify my connections are correct to flash?

I don't know, but it looks reasonable!
« Last Edit: Fri, 19 July 2013, 06:09:13 by Soarer »

Offline Kayliss

  • Posts: 143
  • Location: Australia
Re: Programming and flashing firmware (ps2avr)
« Reply #29 on: Fri, 19 July 2013, 07:40:53 »
zenuty said he sold this PCB to 20 other people on GH, and they had no problems.  :mad:
where are these 20 other people, did they get their firmware flashed; how?


USBtinyISP  :-* I built mine from Zenuty a few months ago.

Offline GON

  • * Maker
  • Posts: 211
  • Location: S. Korea
  • Skype ID : GonsKeyboardWorks
    • GONsKeyboardWorks
Re: Programming and flashing firmware (ps2avr)
« Reply #30 on: Fri, 19 July 2013, 09:47:44 »
No, it's blank, nothing preinstalled. All components and PCB were separate, I had to solder them on the PCB. That's all done, so now I'm stuck at figuring out how to flash the firmware onto the controller.

just a question: the controller in the pcb that gon ship has a firmware pre-installed?

I think he should warn all his potential buyers about this little detail

PS2AVR's are designed by 괴수가면 of KBDMania.
He preflashed all the chips before he sells them.
I'm not sure what the problem is....

This is why I don't sell PCBs without soldering controller and writing firmware.
So, for my buyers this kind of problem will not happen.

BTW, I think the easiest way I can help WFD is to sell a completely flashed Atmega32A chip.
(Last time at some post, I told this... the problem is shipping. $24 for EMS taking 5-7 days.)
Even though I have made/assembled/tuned HUNDREDs of keyboards for others, I myself don't have a full-tuned Custom Keyboard now.
So Ironical!

Offline alaricljs

  • I be WOT'ing all day...
  • ** Moderator Emeritus
  • Posts: 3715
  • Location: NE US
Re: Programming and flashing firmware (ps2avr)
« Reply #31 on: Fri, 19 July 2013, 09:57:38 »
Flashing is the easy part, it's getting the right firmware hex that seems to be the problem.
Filco w/ Imsto thick PBT
Ducky 1087XM PCB+Plate, w/ Matias "Quiet Click" spring-swapped w/ XM Greens

Offline GON

  • * Maker
  • Posts: 211
  • Location: S. Korea
  • Skype ID : GonsKeyboardWorks
    • GONsKeyboardWorks
Re: Programming and flashing firmware (ps2avr)
« Reply #32 on: Fri, 19 July 2013, 10:11:29 »
This is the latest bootloader and firmware for PS2AVR's.

PS2AVRs now support bootloader that lets users upograde the firmware without an ISP loader, and USB/PS2 combo.

Now the firmware is being tested but almost complete.
Even though I have made/assembled/tuned HUNDREDs of keyboards for others, I myself don't have a full-tuned Custom Keyboard now.
So Ironical!

Offline alaricljs

  • I be WOT'ing all day...
  • ** Moderator Emeritus
  • Posts: 3715
  • Location: NE US
Re: Programming and flashing firmware (ps2avr)
« Reply #33 on: Fri, 19 July 2013, 10:18:25 »
Will that work on a PCB that didn't originally have the USB design, such as a 456GT?  I did notice a slight component difference.
Filco w/ Imsto thick PBT
Ducky 1087XM PCB+Plate, w/ Matias "Quiet Click" spring-swapped w/ XM Greens

Offline boost

  • BOSTMOBILE
  • * Elevated Elder
  • Posts: 3300
  • NY Giants!!!
Re: Programming and flashing firmware (ps2avr)
« Reply #34 on: Fri, 19 July 2013, 10:18:51 »
Got this thing...

"Aerodynamics are for people who can't build engines."

-Enzo Ferrari

Offline WhiteFireDragon

  • Thread Starter
  • Posts: 2276
    • youtube
Re: Programming and flashing firmware (ps2avr)
« Reply #35 on: Sat, 20 July 2013, 02:56:56 »
where are these 20 other people, did they get their firmware flashed; how?

I know a handful are watching this thread, waiting for a dumbed down guide  ;)


He preflashed all the chips before he sells them.
I'm not sure what the problem is....

I have a few of these PCBs from zenuty. As far as I know, the loose atmega chips are completely blank with nothing on them. If they're supposedly flashed, what is on there? Just a bootloader, or the final working firmware? The board is soldered already, and computer does not detect controller once plugged in.

Offline GON

  • * Maker
  • Posts: 211
  • Location: S. Korea
  • Skype ID : GonsKeyboardWorks
    • GONsKeyboardWorks
Re: Programming and flashing firmware (ps2avr)
« Reply #36 on: Sun, 21 July 2013, 03:20:52 »
where are these 20 other people, did they get their firmware flashed; how?

I know a handful are watching this thread, waiting for a dumbed down guide  ;)


He preflashed all the chips before he sells them.
I'm not sure what the problem is....

I have a few of these PCBs from zenuty. As far as I know, the loose atmega chips are completely blank with nothing on them. If they're supposedly flashed, what is on there? Just a bootloader, or the final working firmware? The board is soldered already, and computer does not detect controller once plugged in.



Most of those who bought PS2AVR PCBs would have had no problem with the PCB.
Just soldering the parts and connecting to PS/2 port is all that needed. The chip is already preflashed with firmware.


Did you connect the PCB to PS/2 port?
PS2AVR was designed to work with PS/2 connection.
(Of course, it works with USB with PS2AVR-EXT module and the latest firmware.)

Some of the PC M/Bs with a PS/2 combo port have compatibility issue with PS2AVR, 356 and 456 kbds.
In fact, my MSI B75-ITX M/B also has that problem.
(I myself didn't know it before making purchase. I will never buy a M/B with a PS/2 combo port again.)
So I connect my PS2AVR kbd through a PS2 hub in genovation 682.

PS2AVR - PS2 Hub - PS/2 Port of my PC

I haven't seen any PS2AVR PCBs with a blank MCU so far...
(I've soldered at least 30 PS2AVR PCBs...)
And never heard that in KBDmania, either.



**Important**
PS/2 itself does NOT support Plug and Play.
You should connect the KBD before you turn on the computer.
(Of course, if you have a PS/2 Hub, that supports Plug and Play.)

If you are to buy Korean custom PCBs and not fully experienced, plz ask the seller soldering and firmware upgrading.
Even in case the seller cannot do it, he can easily find skillful experts in Korea.

In Korean KBD market, who soldered/assembled the PCB/KBD is a very important factor when deciding a purchase.
« Last Edit: Sun, 21 July 2013, 04:34:32 by GON »
Even though I have made/assembled/tuned HUNDREDs of keyboards for others, I myself don't have a full-tuned Custom Keyboard now.
So Ironical!