Firmware upgrade disaster!!!

Discussions related to MegaDrum Hardware

Re: Firmware upgrade disaster!!!

Postby dmitri » Sat Jun 20, 2009 12:22 am

kurtus420 wrote:usb has been plugged in but I never switched the megadrum on.

Since you kept omitting the bit about "Connect the Digital board to a USB port to provide power for PIC18F2550" from http://www.megadrum.info/content/progra ... pic18f2550 are you sure you haven't omitted anything else?

I have tried with the megadrum on and get the on and get the same outcome. If the cable was wrong than would it not initialize ok?

It may show that it is initialized ok even if the cable is not correctly connected or wired. It's just a cable, not a proper programmer, there is nothing to initialize there. Winpic tries to do some sanity check but JDM type programmers (which the ICSP cable is) are not smart devices.
dmitri
Site Admin
 
Posts: 8709
Joined: Fri Aug 03, 2007 8:05 pm

Re: Firmware upgrade disaster!!!

Postby el-dr » Sat Jun 20, 2009 12:31 am

dmitri wrote:
el-dr wrote:It's not working here either. :twisted: Here's what Winpic read from the PIC:
dumped.hex


It shows regular garbage, which means it doesn't read the memory properly and of course won't program it properly.
You either have a problem with Winpic configuration, the ICSP cable, a serial port or you don't power up the MegaDrum board when trying to program/read PIC18F2550.


I know that the file contents is garbage, but WP reports "PIC read OK", (the Initialize cmd on the Interface tab says "Initializing PIC-programmer: Success"), I measured the cable many times and did power up the board, so the only option is that something's wrong with the Winpic config, which makes me really sick, because the help file is close to useless, as it gives no explanation of the prog's error messages.
el-dr
 
Posts: 110
Joined: Thu Apr 30, 2009 9:51 pm

Re: Firmware upgrade disaster!!!

Postby kurtus420 » Sat Jun 20, 2009 12:34 am

My assumption was that the board would recieve power if the switch wasn't turned on with the usb cord plugged in, guess that was my first mistake. Again, I have double checked the wiring and it is the same as the diagram that you provided.
I wired it like this:
If you were looking at your diagram pretend the image is of the face of the female connector and the wires come into the backside of it. I used the diagrams you gave me, and followed everything to the tee except for actually turning the power switch on, could this have fried the mcu, should I get a new one or will I likley fail the way I am right now?

dmitri wrote:
kurtus420 wrote:usb has been plugged in but I never switched the megadrum on.

Since you kept omitting the bit about "Connect the Digital board to a USB port to provide power for PIC18F2550" from http://www.megadrum.info/content/progra ... pic18f2550 are you sure you haven't omitted anything else?

I have tried with the megadrum on and get the on and get the same outcome. If the cable was wrong than would it not initialize ok?

It may show that it is initialized ok even if the cable is not correctly connected or wired. It's just a cable, not a proper programmer, there is nothing to initialize there. Winpic tries to do some sanity check but JDM type programmers (which the ICSP cable is) are not smart devices.
56 input Megadrum644, Tama Iron Cobra, Taye, Sonor, Roland, Yamaha, Gibraltar, Tascam.
kurtus420
 
Posts: 222
Joined: Tue May 26, 2009 12:51 am
Location: Nanaimo, Vancouver Island, Canada

Re: Firmware upgrade disaster!!!

Postby kurtus420 » Sat Jun 20, 2009 12:39 am

another note, I plugged megadrum into a different usb port on my laptop and it cycles but it is now installing 2 drivers
one say usb composite device
one says megadrum usb midi
they say installed correctly but it keeps cycling in and out
56 input Megadrum644, Tama Iron Cobra, Taye, Sonor, Roland, Yamaha, Gibraltar, Tascam.
kurtus420
 
Posts: 222
Joined: Tue May 26, 2009 12:51 am
Location: Nanaimo, Vancouver Island, Canada

Re: Firmware upgrade disaster!!!

Postby dmitri » Sat Jun 20, 2009 12:47 am

kurtus420 wrote:My assumption was that the board would recieve power if the switch wasn't turned on with the usb cord plugged in, guess that was my first mistake. Again, I have double checked the wiring and it is the same as the diagram that you provided.
I wired it like this:
If you were looking at your diagram pretend the image is of the face of the female connector and the wires come into the backside of it. I used the diagrams you gave me, and followed everything to the tee except for actually turning the power switch on, could this have fried the mcu, should I get a new one or will I likley fail the way I am right now?

By itself it wouldn't fry the PIC. The fact that PC detects it says it is still OK. I can only suggest to double/triple check the cable, the ICSP cable wiring, the ICSP cable resistors, continuity, shorts, reinstall Winpic and follow http://www.megadrum.info/content/progra ... pic18f2550 for programming PIC18F2550. If after this it fails and you're absolutely sure you did everything right, then you have a very unlikely case where only programming pins in PIC18F2550 have failed and you will need to buy another one.
dmitri
Site Admin
 
Posts: 8709
Joined: Fri Aug 03, 2007 8:05 pm

Re: Firmware upgrade disaster!!!

Postby dmitri » Sat Jun 20, 2009 12:50 am

el-dr wrote:I know that the file contents is garbage, but WP reports "PIC read OK"

It will happily say this even if the PIC is not in the socket. As I said, the JDM type programmers (and the ICSP cable is) are not very smart devices.
dmitri
Site Admin
 
Posts: 8709
Joined: Fri Aug 03, 2007 8:05 pm

Re: Firmware upgrade disaster!!!

Postby kurtus420 » Sat Jun 20, 2009 1:21 am

so I added the pulldown resistor to pin 3 and 6 and it stopped cycling and is now recognized as megadrum midi usb again.
Tried it with midi mapper and sonar 7 with no problems sending midi. I will double check things again. I have ordered 2 more 18f2550 from a supplier that I deal with at work at a very cheap price so I will try these in a week. In the mean while I'm going to try this again using an xp machine to see if I can reprogram this pic.
56 input Megadrum644, Tama Iron Cobra, Taye, Sonor, Roland, Yamaha, Gibraltar, Tascam.
kurtus420
 
Posts: 222
Joined: Tue May 26, 2009 12:51 am
Location: Nanaimo, Vancouver Island, Canada

Re: Firmware upgrade disaster!!!

Postby kurtus420 » Sat Jun 20, 2009 1:27 am

I have check continuity on the cable and I get continuity buzz on the cables that don't have resistors the ones with resistors are reading 10k ohms, wiring seems ok. I'll try a different computer. Is there a way I can disconnect pic18f2550 from the pcb board without actually removing it from the socket like by adding a switch and updating via the midi to usb cable and then using usb to power and send midi after updates are complete.

dmitri wrote:
kurtus420 wrote:My assumption was that the board would recieve power if the switch wasn't turned on with the usb cord plugged in, guess that was my first mistake. Again, I have double checked the wiring and it is the same as the diagram that you provided.
I wired it like this:
If you were looking at your diagram pretend the image is of the face of the female connector and the wires come into the backside of it. I used the diagrams you gave me, and followed everything to the tee except for actually turning the power switch on, could this have fried the mcu, should I get a new one or will I likley fail the way I am right now?

By itself it wouldn't fry the PIC. The fact that PC detects it says it is still OK. I can only suggest to double/triple check the cable, the ICSP cable wiring, the ICSP cable resistors, continuity, shorts, reinstall Winpic and follow http://www.megadrum.info/content/progra ... pic18f2550 for programming PIC18F2550. If after this it fails and you're absolutely sure you did everything right, then you have a very unlikely case where only programming pins in PIC18F2550 have failed and you will need to buy another one.
56 input Megadrum644, Tama Iron Cobra, Taye, Sonor, Roland, Yamaha, Gibraltar, Tascam.
kurtus420
 
Posts: 222
Joined: Tue May 26, 2009 12:51 am
Location: Nanaimo, Vancouver Island, Canada

Re: Firmware upgrade disaster!!!

Postby dmitri » Sat Jun 20, 2009 9:33 am

kurtus420 wrote:I have check continuity on the cable and I get continuity buzz on the cables that don't have resistors the ones with resistors are reading 10k ohms, wiring seems ok. I'll try a different computer. Is there a way I can disconnect pic18f2550 from the pcb board without actually removing it from the socket like by adding a switch and updating via the midi to usb cable and then using usb to power and send midi after updates are complete.

You will need to disconnect pins 17 and 18 of PIC18F2550.
dmitri
Site Admin
 
Posts: 8709
Joined: Fri Aug 03, 2007 8:05 pm

Re: Firmware upgrade disaster!!!

Postby el-dr » Sat Jun 20, 2009 7:20 pm

kurtus420,

forget about messing around with winpic settings and checking the cable again and again. I got fed up with this and set up the oldest machines I found in the house: one with Win98, one with WinME installed. Followed the instructions and it was done in 1 minute. Then I connected MD to the new machine, it recognized it as a new device (this indicated to me that the firmware was successful). Then the resistor came and that was it.

Actually not: I noticed when experimenting with WinPIC on XP that if I selected PIC18F2550 on the device tab, the message window had a warning:
"Couldn't find "devices\PIC18F2550.dev", please borrow/copy from MPLAB !"

I installed MPLAB and here's the missing dev file. It can be copied anywhere and you can set its location in the MPLAB DEV-file-directory folder.
PIC18F2550.zip

--------------------------------------

However, this was only a momentary state of happiness, because I discovered that the MD doesn't transmit Note On messages via USB. According to MIDI-OX, when I hit the piezo, it transmits tons of Program Changes, Pitch Bend and some Note Off messages, but not a single Note On.

When I open MCT, all messages indicate that data can be sent and received with no errors between MCT and MD, but actually nothing works. What make it even more confusing, the MIDI LED lights up when I transmit sg from MCT, which shows that the connection is present.

When I use the standard MIDI Out, MD transmits Note On, Note Off and FC as expected.

I updated the PIC with the pic18f2550usb_12MHz.hex file, the resistor between pins 3-6 at the PIC ICSP is 33kOhm, the MCU is Atmega 644 @ 20MHz, firmware is 20090617.
Here's the firmware that I read back from the PIC after the update:
dumpeda.hex


Honestly, I'm not having much fun at all. :x
You do not have the required permissions to view the files attached to this post.
Last edited by el-dr on Sat Jun 20, 2009 8:58 pm, edited 1 time in total.
el-dr
 
Posts: 110
Joined: Thu Apr 30, 2009 9:51 pm

PreviousNext

Return to MegaDrum Hardware

Who is online

Users browsing this forum: Bing [Bot], Google [Bot] and 60 guests

cron