surei Posted September 13, 2009 Report Share Posted September 13, 2009 Hi all,I just put together a small circuit based on the MIDIbox PIC-core that is suspposed to just read in a few pots and put this out via MIDI. In addition, I put a second PIC for the USB out on the same VERO-board, but that's another story.The PIC was preburned by SmashTV, so I expect it to be fine. In my attempt to solve the problem, I reburned the bootloader into it anyway using the PIC burner (which I had built to burn the 4550 chip for the USB out), but the problem remains. Here is what happens:The MIDI in and out do show something, MIDI in works fine, as I can upload MIOS and application using MIDIStudio, when using manual mode (not waiting for requests fromPIC).MIDI OUT is producing nonsense though. Instead of the normal upload request from the bootloader I get "FF FF FD", and that's it. It does repeat every two seconds as it should, and the string is always identical, so there is no random error here.Loading an application that is just supposed to send the same message every time a pot is turned, will sen a message every time I turn the pot, but again it is entirely different from what I have programmed it to send. This time the message is changed at random.I do assume a hardware problem here. Obviously the polarity must be correct, otherwise I would not get anything. I do not have a scope to check the signals.Any idea?Many thanksReiner Quote Link to comment Share on other sites More sharing options...
lylehaze Posted September 13, 2009 Report Share Posted September 13, 2009 The serial output from the PIC, (used for MIDI OUT), can both source and sink current, so you would get SOMETHING if the polarity is reversed.Good Luck,LyleHaze Quote Link to comment Share on other sites More sharing options...
surei Posted September 13, 2009 Author Report Share Posted September 13, 2009 The serial output from the PIC, (used for MIDI OUT), can both source and sink current, so you would get SOMETHING if the polarity is reversed.Actually I did try it, and I did not get anything when I switched the polarity.Reiner Quote Link to comment Share on other sites More sharing options...
TK. Posted September 13, 2009 Report Share Posted September 13, 2009 Sounds like the PIC is sending with the wrong baudrate.Maybe you use the wrong crystal for this board as well?Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
surei Posted September 13, 2009 Author Report Share Posted September 13, 2009 I'm using the 10MHz for the PIC18F452, which I think is correct, right?I shtere an easy way to check for the baudrate? Can't use MIOS-Studio for testing, since it cannot read the input. I also tried reburning the chip with the PIC burner, using the bootloader that comes with the MIOS 1.9f download. The burner claimed success and when plugging it backI do get these garbled messages every two seconds. So where else could the baudrate be set?THanks for your helpReiner Quote Link to comment Share on other sites More sharing options...
seppoman Posted September 13, 2009 Report Share Posted September 13, 2009 So where else could the baudrate be set?maybe you have the PIC ID set to serial port mode (38400)? http://www.ucapps.de/mios_bootstrap_experts.htmlS Quote Link to comment Share on other sites More sharing options...
surei Posted September 13, 2009 Author Report Share Posted September 13, 2009 maybe you have the PIC ID set to serial port mode (38400)? http://www.ucapps.de/mios_bootstrap_experts.htmlThat would certainly be a logical explanation, but how could this be? The PIC was preburned by SmashTV with ID 000 000 000 0001, so everything default except the Device-ID. Besides, shouldn't the MIDI In fail also in this case? Since I can upload applications and Mos to the PIC with Mios studio (in manual mode), the MIDI In is obviously working.What's the easiest way to check this setting?Thanks againReiner Quote Link to comment Share on other sites More sharing options...
seppoman Posted September 13, 2009 Report Share Posted September 13, 2009 Besides, shouldn't the MIDI In fail also in this case? Since I can upload applications and Mos to the PIC with Mios studio (in manual mode), the MIDI In is obviously working.What's the easiest way to check this setting?that's right, the baud rate of input and output are always the same - so taking your "turning pot" experiment into account, I guess the ID is not the problem. If you wanna be sure, you can read out the ID with your burner. Don't ask me how though, it's been a long time since I burned my last PICs ;) Quote Link to comment Share on other sites More sharing options...
TK. Posted September 13, 2009 Report Share Posted September 13, 2009 Which MIDI interface is connected to the MIDI OUT of your core module?And:http://www.ucapps.de/howto_debug_midi.htmlWhat's the result of TEST_INOUT1?Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
surei Posted September 13, 2009 Author Report Share Posted September 13, 2009 HalloThorsten,it is a Saffire LE, and it is working fine with another MIDIbox.However, I just did the INOUTtest shortening Rx and Tx on the board and it fails miserably. I sent some simple controller messages out using MIDIox, and got backtotal garbage.So where do I look next?Thanks so far (now I know it can't be the PIC)Reiner Quote Link to comment Share on other sites More sharing options...
surei Posted September 13, 2009 Author Report Share Posted September 13, 2009 Mistery solved, and again a silly mistake!I wired the 220Ohm resistor from Pin 4 of MIDI Out to 0V instead of +5V. Now it works fine, thanks for your patience!Best regardsReiner Quote Link to comment Share on other sites More sharing options...
TK. Posted September 13, 2009 Report Share Posted September 13, 2009 :)Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.