Offline

Hey all,

Thanks for having me here, this is my first post.

I'm having problems with my Arduino. I'm not really good at explaining so I uploaded a video:

http://www.youtube.com/watch?v=1xdaAmE3LhE

Also, here are some pics:

I used the Sparkfun MIDI board by the way. I'm 99% sure the wires are not making contact with contacts they arent supposed to make contact with.

This is my 1st Arduino project so yes, I'm a n00b.

Thanks!

Casper

Offline
Los Angeles

First off you don't need to tie that pin4 to the optoisolator on that board unless you cut the power pin trace to the optoisolator. the reason arduinoboy uses pin4 to tie to the optoisolator is so that the code can turn on/off the optoisolator (it provides power) ... The sparkfun board uses a switch "run/program" instead.

Whats happening in your video is that the arduinoboy is cycling modes, your push button isnt working for whatever reason. Also that setting in your code doesn't do force mode, it just means that you can overwrite those default settings via EEPROM using the arduinoboy settings editor.

Your gonna also have to do this:

code wrote:

byte defaultMemoryMap[MEM_MAX] = {
  0x7F,0x01,0x02,0x7F, //memory init check
  0x01, //force mode (forces lsdj to be sl)
  0x00, //mode
 
  15, //sync effects midi channel (0-15 = 1-16)
  15, //masterNotePositionMidiChannel - LSDJ in master mode will send its song position on the start button via midi note. (0-15 = 1-16)
 
  15, //keyboardInstrumentMidiChannel - midi channel for keyboard instruments in lsdj. (0-15 = 1-16)
  1, //Keyboard Compatability Mode
  1, //Set to true if you want to have midi channel set the instrument number / doesnt do anything anymore
 
  0,1,2,3, //midiOutNoteMessageChannels - midi channels for lsdj midi out note messages Default: channels 1,2,3,4
  0,1,2,3, //midiOutCCMessageChannels - midi channels for lsdj midi out CC messages Default: channels 1,2,3,4
  1,1,1,1, //midiOutCCMode - CC Mode, 0=use 1 midi CC, with the range of 00-6F, 1=uses 7 midi CCs with the
                       //range of 0-F (the command's first digit would be the CC#), either way the value is scaled to 0-127 on output
  1,1,1,1, //midiOutCCScaling - CC Scaling- Setting to 1 scales the CC value range to 0-127 as oppose to lsdj's incomming 00-6F (0-112) or 0-F (0-15)
  1,2,3,7,10,11,12, //pu1: midiOutCCMessageNumbers - CC numbers for lsdj midi out, if CCMode is 1, all 7 ccs are used per channel at the cost of a limited resolution of 0-F
  1,2,3,7,10,11,12, //pu2
  1,2,3,7,10,11,12, //wav
  1,2,3,7,10,11,12, //noi
 
  0, 1, 2, 3, 4, //mGB midi channels (0-15 = 1-16)
  15, //livemap / sync map midi channel (0-15 = 1-16)
  80,1,  //midiout bit check delay & bit check delay multiplier
  0,0//midiout byte received delay & byte received delay multiplier
};

Offline
Sacramento, CA

Hey, Having the same problem. I breadboarded mine out and all the connections seem to be fine; although if the switch is the problem maybe I got the wrong type. I'm using a SPST push-on/off switch. I'm a noob at arduino as well...so confused.

Also, i'm using a DMG-07 cable, right now it's all alligator clipped up, but the wire is stranded; do you think I should tin them for the prototyping?

Last question: With the midi out, will I be able to play music and trigger midi at the same time. As in use one channel (preferably the noise channel) just to trigger samples on my sp-303 and use the other 3 channels as I like?

Offline
Sacramento, CA

Alright, I know it must be something with the switch, upon further research that is usually to blame. I tinned the DMG-07 wires just in case, although I know it wasn't a problem because the arduino would still remain on after pulling the USB out. The LEDs flicker on upon restart and "re-flashing", so no problem there. I've checked everything a million times against trash's schematic and 2 player's schematic. (
http://2playermusic.tumblr.com/post/703 … arduinoboy) No connections where there shouldn't be.

Anyways, the arduino no longer cycles modes, but the button doesn't have any affect. I've tried 2 other SPST switches, although they were both toggle switches and not push buttons. I've also tried the suggested code change from up above. Nothing. This is getting a bit frustrating, any help appreciated! I already bought my bottle of 2 buck chuck expecting to jam out tonight! I'll keep troubleshooting. Do you guys want photos or videos? I can do either...In fact, i'll upload photos and make a video if requested.

Also: Should I ground the shield from the DMG-07 or something. Right now i've just twisted it off to the side and have done nothing with it.

Last edited by Slumpy (Jun 8, 2012 2:31 am)

Offline
Sacramento, CA

http://www.youtube.com/watch?v=GPBGsFAa … e=youtu.be

Video up. Pictures soon to come...probably tomorrow though.

PS: Sorry for completely butchering your name Nitro2k01; if it's any consolation i'm kind of drunk and frustrated.

Also: wtf casper, If you solved this problem i'm going to be pissed that you didn't update this thread.

PSS: I'm drunk and bad with words

Last edited by Slumpy (Jun 8, 2012 6:27 am)

Offline
Sacramento, CA

Alright, I know double posting is usually frowned upon in forums (in this case quadruple posting), but this board moves slow enough that I figure it's OK.

Anyways, the video I posted is really worthless, so hopefully these pics will help.

http://www.imagebanana.com/view/zc0zznk2/DSCN1876.JPG

http://www.imagebanana.com/code/ehpbw3va/DSCN1872.JPG

http://www.imagebanana.com/view/zf4gk4be/DSCN1873.JPG

Won't let me embed the pics with the  tags sad

So this morning I took everything apart and put it back together again. No mode cycling this time, but still no button response. I've tried wiring pin 3 straight to the SPST button and the SPST button to ground, taking out the 2k resistor, and the button will then shut off/on the gameboy itself; don't know if that's useful information.

And here I thought that the hardest part to get going would be the midi connections themselves, unless it still is the hardest part, in which case it's not very reassuring!

UPDATE: I've tried bypassing the whole button select mode and force start the arduinoboy into mGB mode. I set forcemode to 4 and put alwaysUseDefaultSettings = true. My akai mpk25 is outputting midi but no sound from mGB....

UPDATE2: I've checked the actual DIN plug with my continuity option on my volt-ohmeter along with all the pins of the optoisolator. Everything checks out. I've made sure my akaiMPK25 is outputting midi data on channel 1. Still nothing.

I've tried force starting mode 4 and 5 because i'm not sure which one is mGB. In mode 4, the 6th LED lights up. In mode 5, the first 3 LEDs light up. In all cases the LEDs don't stay lit up.

I don't know what I should do with pin 3 since i'm force starting to mGB. I've tried taking out the switch but leaving the rest of the connections in tact. I've tried putting pin 3 straight to ground; and through the 2k resistor to ground. I've also tried taking off pin 3 completely. Still nothing.

I guess my only option is to buy a new 6n138 and hope to god that works. Any help appreciated, or at least any acknowledgment that I exist in this thread will help too. In retrospect I probably should have just started my own thread. Actually, if a new 6n138 doesn't work I may just start my own thread.

Also: It's not shown in the picture, but i've added the 4.7k resistor suggested by nitro2k01

Last edited by Slumpy (Jun 8, 2012 10:25 pm)