OneLittleFonzie Posted January 28, 2010 Report Share Posted January 28, 2010 I just started building Midibox stuff. The MIOS32 version Midibox 64 is my goal. Now that I'm testing a bit with programming I realize that for instance DOUT doesn't work. Is that right? How far is the STM32 version project. If necessary I could contribute. Thanks Ron Quote Link to comment Share on other sites More sharing options...
philetaylor Posted January 28, 2010 Report Share Posted January 28, 2010 AFAIK, almost all of MIOS8 is currently working in MIOS32 (and quite a lot more!) DIN/DOUT are certainly working (or the MB_SEQ_V4 wouldn't be usable!) Cheers Phil Quote Link to comment Share on other sites More sharing options...
OneLittleFonzie Posted January 29, 2010 Author Report Share Posted January 29, 2010 Thanks for the quick reply So, I've used the example "apps\tutorials\009_dout" should work. In my case it doesn. I've connected 1 led for now and nothing happens. When it starts up the led lits while booting as well as the activity led on the board. I've added this piece in de APP_Init and the APP_MIDI_NotifyPackage event handler u8 i; for i = 0 ; i < 127 ; i++ ) { MIOS32_DOUT_PinSet(i, 1); } Nothing happens when I press a button, also the activity led doesn't flip while MIOS32_BOARD_LED_Set(1, ~MIOS32_BOARD_LED_Get()); is in the handler body. When I add: if( midi_package.type == NoteOn && midi_package.chn == Chn1 && midi_package.velocity > 0 ) MIOS32_MIDI_SendCC(port, Chn1, 1, midi_package.velocity); I receive something back from the MIOS32 in my midi monitor so that handler is activited. What is happening (or not). Thanks very much Ron Quote Link to comment Share on other sites More sharing options...
philetaylor Posted January 29, 2010 Report Share Posted January 29, 2010 (edited) Strange... It should work. I assume you are using a DOUTx4 module and have the LED connected between the output and ground as per this diagram I am at work at the moment so I can't try it myself! Cheers Phil Edited January 29, 2010 by philetaylor Quote Link to comment Share on other sites More sharing options...
OneLittleFonzie Posted January 29, 2010 Author Report Share Posted January 29, 2010 It sure is strange. It's exactly like on the diagram I'm going to buy a LCD 4*20 this afternoon. This way I can check what the MIOS32_DOUT_PinSet method returns. I can imagine that I did something wrong but I'm more surprised about the activity led on the board. It does exactly what is needs to do but it doesn't toggle when I receive incoming midi data. The handler works because I can return midi messages which I see in the midi monitor strange, strange, strange Thanks Ron Quote Link to comment Share on other sites More sharing options...
philetaylor Posted January 29, 2010 Report Share Posted January 29, 2010 You can also use MIOS32_MIDI_SendDebugMessage() to send messages to the MIOSStudio Terminal window if you haven't got an LCD. Cheers Phil Quote Link to comment Share on other sites More sharing options...
OneLittleFonzie Posted January 29, 2010 Author Report Share Posted January 29, 2010 I quickly tried that yesterday evening. I'll read the documentation of MIOS studio and try again. Thanks very much for your time. I'll come back on this. Regards Ron Quote Link to comment Share on other sites More sharing options...
TK. Posted January 29, 2010 Report Share Posted January 29, 2010 One possible reason (beside of bad solderings or wrong connections between MBHP_CORE_STM32 and MBHP_DOUTX4 module) is that the 220 Ohm Pull-up resistor array R31 is not mounted. You can test this by measuring the voltage between ground and pin J8:SO, J8:SC, J8:RC when the DOUT module is *not* connected. Note that due to the AC waveforms generated by the SPI transfers you won't measure exact DC values with a common multimeter, but they could give you some hints. E.g., J8:SO should be 0V when your application sends 0 to all DOUT pins, and it should be ca. 5V when you application sends all-1 J8:SC should be between 4V..5V (each mS this pin sends a burst of 1 MHz for ca. 300 uS) J8:RC should be ca. 5V (only short pulses sent each mS) If you always read 0V, the pins are probably floating, accordingly the pull-ups are not connected. Btw: the usage of MIOS32_MIDI_SendDebugMessage() is really recommented for debugging, it's more useful than a LCD. See also http://svnmios.midibox.org/listing.php?repname=svn.mios32&path=%2Ftrunk%2Fapps%2Ftutorials%2F003_debug_messages%2F Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
OneLittleFonzie Posted January 29, 2010 Author Report Share Posted January 29, 2010 Wow That's very impressing so much service :-) I guess it's because I missed the 3.3/5 volt selector I missed (J24/J25/J26) Going to try tomorrow morning Thanks very much Ron Quote Link to comment Share on other sites More sharing options...
OneLittleFonzie Posted January 30, 2010 Author Report Share Posted January 30, 2010 Well, the jumpers were the problem. Now it seems uploading is suddenly a problem :-) Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Starting upload of project.hex Requesting reboot... Waiting for upload request... Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Checksum: 00 - OK Received Upload Request Received Checksum: 00 - OK Received Checksum: 00 - OK Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received Checksum: 00 - Error Sending block #1 08004000-080040FF Received error code 01: Less bytes than expected have been received Aborting after 16 errors Quote Link to comment Share on other sites More sharing options...
TK. Posted January 30, 2010 Report Share Posted January 30, 2010 But it worked before, correct? I guess that you changed something on the MIOS Studio configuration which causes this effect, somehow it looks like a feedback loop, since messages are received multiple times. It could also be, that a second application is running in background which forwards MIDI events (you are working under MacOS, right?) -> check the MIDI routings. Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
OneLittleFonzie Posted January 30, 2010 Author Report Share Posted January 30, 2010 Wow Thorsten, you are the best. I quickly wanted to check because you responded so fast. It works after I deleted the miosstudio.xml file. Still not sure why it didn't work at some point. I guess the default connection from the menu doesn't do the same as removing the file. Anyway Thanks very much Ron Quote Link to comment Share on other sites More sharing options...
OneLittleFonzie Posted January 31, 2010 Author Report Share Posted January 31, 2010 (edited) Excellent. Everything works fine except for the LCD. It's an old Hitachi HLM 2041. Need to check whether it's compatible. Otherwise I have a smaller one too. Going to start programming now :-) Thanks for all the help Ron Edited January 31, 2010 by OneLittleFonzie 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.