Jump to content

Antichambre

Programmer
  • Posts

    1,291
  • Joined

  • Last visited

  • Days Won

    101

Posts posted by Antichambre

  1. Hello some update were made on the dokuwiki ;)

    dipCoreF4

    fetch.php?w=400&tok=a9746a&media=anticha
    A reduced Core for your MIDIbox App, an STM32F405RG in a DIP40 format.
    fetch.php?w=600&tok=df1ade&media=anticha

     

    Features

    • MIOS32 uses same processor family and drivers(no deep change).
    • Same internal hardware as Disco or wCore (speed, memory, peripherals, etc…) .
    • Board pinout and package compatible with a MIOS8 PIC 8-)
    • USB connector onboard. 2 OTG are available, second(new) USB is Host only.
    • 5V power input and led.
    • 3.3V regulator and led on board.
    • 74HCT541 on board for the 5V output ports.
    • User and Reset buttons.
    • 2 user leds.
    • 12 extra pins for USB, buttons and leds.
    • Your favorite Core is now a current component easy to integrate.

    All commons MIOS32 ports are available except:

    • General purpose J10x ports were removed.
    • LCD port was reduced to a serial one, no more pins J15.D0-D7 , no back-light power supply.
    • 2 UART only(2 MIDI In/2Out).
    • 2 AIN channels only(e.g. pedal inputs).
    • SPI slave only supported by J19(SPI3).

    Check the dipBoardF4 for more details :-P
     


    Download

    dipCoreF4 eagle lib for easy integration in your design. dipcoref4_v2a.zip
     


     

    Pinout

    The dipCoreF4 and the legacy MIOS32 ports.

    fetch.php?w=600&tok=ab8434&media=anticha

    Check dipBoardF4 for more details about the connectors.

    BOM

    Due to the small SMD, which is sometime a difficulty to solder, the board is already assembled by manufacturer, except the connectors.
    The mini-USB is optional.

    Qty Value Package Parts Mouser Reichelt Conrad LCSC Notes
    Headers
    3 1*20 male   437-3501012000006101     No Adapted to sockets
    Mill-Max 0552-1-15-01-11-27-10-0
    or 0553-1-15-15-11-27-10-0
    Connnector
    1 mini-USB THT USB 571-1734510-1     no! for other ref take care about restricted area!

    • Like 3
  2. Hi Flavio,

    Just now, FlavioB said:

    Question: why did you plan 2 MIDI IN? Wouldn't 1 MIDI IN just be enough, or do you have some features which can benefit from the 2 MIDI INs? Like assigning MIDI IN 1 to the (external) transpose function and MIDI IN 2 for MIDI Clock?

     

    For MIDI in, in the App, there's two kind of MIDI input:
    - The SYNTH, the NOTE On and Off which come from its selected input will fill the notestack of the Voices, others messages can be forwarded to the synth(CC pitchbend etc).
    - The CONTROL, CC will control the HAARP parameters, the Note On and Off will be use as realtime transpose of the whole arppegio Or to fill a dedicated notestack which is use for REPEAT function, for sequenced transpose. Those messages can be forwarded too as you can record them.
    About the Outputs, for the same reason and/or because there's 8 voices then you will be able to connect directly 2 synth, of course more if you use their MIDI THRU.

     

    Just now, FlavioB said:

    Also, is there any chance to have analog sync - at least DinSync (IN is the most important im my eyes, but eventually also OUT)?

    There's no DIN Sync or other 48ppqn sync like Korg, sorry.
     

    Just now, FlavioB said:

    I understand that most probably there will be no time/space for some design changes like the above, just curious! :-)

    Yep I just received the PCB, too late to change and no space to add others DIN connectors, but you can add it externally with any MIDI<>Sync interface. Or you maybe have a Drum machine which can do this job.
    This interface can be done with a MB platform too ;)

    Best regards
    Bruno

     

    • Like 1
  3. 37 minutes ago, Hawkeye said:

    @Antichambre hope you managed to get home before the eurozone lockdown.

    The Schengen lock-down is mainly terrestrial, by plane there's only restrictions for some countries like Italy China etc... I'm still in Tanzania and it does not apply from here for the moment, my flight is on Sunday, KLM told us they continue to fly, I saw one of this blue bird in the sky today so seems true and it should be fine, just a transit in Amsterdam then my own country can't refuse me, I hope! ;)

    37 minutes ago, Hawkeye said:

    If you want to apply for the french speaking countries only, no problem, you'd be very welcome to join.

    Yes i think I will do, just let me come back home and write some presentation words...

    37 minutes ago, Hawkeye said:

    It seems like we're in for a bit of soldering in the next weeks, time to finish all those unfinished projects :).

    If authorities do not put me in quarantine, my girl will do it for sure ;). HAARP, Euro format and dipCoreF4 PCBA should arrive next week normally, so I'm in for a bit of soldering next week. I hope too ;)

    Best regards
    Bruno
     

  4. It is tempting. :)
    I would still like to limit the area to France and perhaps French-speaking Belgium.
    It makes sense to limit the final shipment, it may even be added as a suggestion to your program ?
    Something like: "If possible, prefer a local manufacturer, to limit the ecological impact a bit and provide suitable support if English is not a confortable language for one or both contractors."

    I am safe and not in France ;) but the question for me is whether I can go home once my work is done ...

    Best Regards
    Bruno
     

  5. Hi Guys!

    Well done!
    Peter, it's sometimes frustrating not being able to give you a "like" ;)

    Question: Is it possible to reuse the box of the SEQ V4+ Casing you send and place a built Sequencer inside? I don't remember how mine was.

    Have a good WE too!

    Bruno


     

  6. Hi,


    Your if condition is never true cause you put initialization to 0 and increment of seccount in the same hook. APP_Tick is called by TASK_Hooks every ms.

    #include <mios32.h>
    #include <FreeRTOS.h>
    #include <task.h>
    #include "app.h"
    
    	static int seccount = 0;
    
    // Init J5A+B Pin 0 as ANalog Input
    void APP_Init(void){
    
    	MIOS32_BOARD_J5_PinInit(0, MIOS32_BOARD_PIN_MODE_ANALOG);
    	MIOS32_BOARD_J5_PinInit(4, MIOS32_BOARD_PIN_MODE_ANALOG); }
    	
    
    void APP_Background(void) {}
    
    // Get J5A-B Pin 0 every second
    void APP_Tick(void){
    	
    						seccount++;
    						
    						if (seccount > 1000) {	seccount = 0;	// reset counter
    	
    												static s16 state = 0;
    												
    												// Get J5A0
    												state = MIOS32_BOARD_J5_PinGet (0);
    												MIOS32_MIDI_SendDebugMessage("J5A-Pin0: %d   ", state ) ;
    												
    												// Get J5b0
    												state = MIOS32_BOARD_J5_PinGet (4);
    												MIOS32_MIDI_SendDebugMessage("J5B-Pin0: %d   ", state ) ;
    											}
    }
    	
    void APP_MIDI_NotifyPackage(mios32_midi_port_t port, mios32_midi_package_t midi_package){}
    void APP_SRIO_ServicePrepare(void){}
    void APP_SRIO_ServiceFinish(void){}
    void APP_DIN_NotifyToggle(u32 pin, u32 pin_value) {}
    void APP_ENC_NotifyChange(u32 encoder, s32 incrementer){}
  7. Events are read from midi file and scheduled by the seq_bpm(sequencer module) thru the seq.c file, sent to seq_midi_out(still sequencer module) and played from it.
    You can modify the private hook which is installed by SEQ_MIDI_OUT_Callback_MIDI_SendPackage_Set and called by the scheduler.

    This hook:

    /////////////////////////////////////////////////////////////////////////////
    // this hook is called when the MIDI scheduler sends a package
    /////////////////////////////////////////////////////////////////////////////
    static s32 Hook_MIDI_SendPackage(mios32_midi_port_t port, mios32_midi_package_t package)
    {
      // realtime events are already scheduled by MIDI_ROUTER_SendMIDIClockEvent()
      if( package.evnt0 >= 0xf8 ) {
        MIOS32_MIDI_SendPackage(port, package);
      } else {
        // forward to MIDIO
        if( seq_play_enable_dout )
          MIDIO_DOUT_MIDI_NotifyPackage(port, package);
    
        // forward to enabled MIDI ports
        int i;
        u16 mask = 1;
        for(i=0; i<16; ++i, mask <<= 1) {
          if( seq_play_enabled_ports & mask ) {
    	// USB0/1/2/3, UART0/1/2/3, IIC0/1/2/3, OSC0/1/2/3
    	mios32_midi_port_t port = USB0 + ((i&0xc) << 2) + (i&3);
    	MIOS32_MIDI_SendPackage(port, package);
          }
        }
      }
    
      return 0; // no error
    }

    But it seems this app was prepared for that purpose, have a look to the lines especially:

        // forward to MIDIO
        if( seq_play_enable_dout )
          MIDIO_DOUT_MIDI_NotifyPackage(port, package);


     

  8. 50 minutes ago, Philbert said:

    Thanks. Looks like I have to abandon my plan, then.

    Out of interest, what is it that makes it not possible to use a simple custom TRS -> DIN cable?

    Meris TRS is RX, TX + Ground. MIDI in input is RX + 5V. 5V is missing ;)


    But ok this is something you can try, at your own risk, I never tried it in this way...
    IMG_0993.JPG?raw=1

    it should be the inverse of this one which is to connect a Meris pedal.
    file#

     

     

  9. 2 hours ago, Htidwell1970 said:

     

    I know this is an old thread but I've been sitting on 2 mackie HUIs I got from a warehouse default sale - scratching my head for almost 2 years... neither start up I tried replacing suspect caps but no love... Did anyone ever figure out the transformer specs?  Sorry to hijack your board Midibox guys - this is the only active thread I could find on the net...  Thanks for tolerating us and thanks in advance to anyone that can help! Holly

     

    Hi,
    Service Manual

    schematic #1

    schematic #2

    Transformer is a 0-24-48V and can be found here:
    http://www.loudtechnologies.eu/shop/en/mackie-mcu-midi-controllers/hui/600-032-01/a-4082-10000210
     

    Best regards
    Bruno

  10. 11 hours ago, lichtuberstromt said:

    It gets weirder though.  The original AINSER64 code addresses the ADC channels in reverse order.

          u16 pin = muxed ? (mux_pin_map[mux_ctr] + 8*chn) : chn; // the mux/chn -> pin mapping is layout dependent
          //u16 pin = muxed ? (mux_pin_map[mux_ctr] + 8*(7-chn)) : (7-chn); // the mux/chn -> pin mapping is layout dependend

    The first line is modified as suggested by Antichambre to work around the fact that I wired it backwards from the original midibox wiring.  The commented out line is the original code.  Until now, I thought this was a bit of a kludge and fairly odd that MUX 1 was supposed to be wired to Chan 7 of the ADC.  I'm assuming the problem I'm having is maybe the reason (or one of the reasons) why its wired as such.  If I use the original code, I have no weird issues.  The pin numbers are completely wrong, but thats to be expected.

    I'm surprised cause I did it for the HAARP and use a 4 channel ADC to reduce the cost. But I use it on the regular J19. Channels are reversed like you.
    I don't use the AINSER64 module and add/rewrite a simplified/dedicated copy in the app folder.
    I made some changes to reduce the scanning and make it faster. The CS uses only 16 inputs, the 16 others are for a future extension like CV in.
    And it works for me.

    s32 ARP_AIN_POT_Handler(void (*_callback)(u32 pot, u32 value))
    {
      // the mux_ctr -> pin mappin is layout dependend
      const u8 mux_pin_map[8] = {0, 1, 2, 3, 4, 5, 6, 7};
      static u8 mux_ctr = 0; // will be incremented on each update to select the next AIN pin
      static u8 first_scan_done = 0;
      static u16 link_status_ctr = 0;
      s32 status = 0;
    
      // init SPI port for fast frequency access
      // we will do this here, so that other handlers (e.g. AOUT) could use SPI in different modes
      // Maxmimum allowed SCLK is 2 MHz according to datasheet
      // We select prescaler 64 @120 MHz (-> ca. 500 nS period)
      status |= MIOS32_SPI_TransferModeInit(ARP_AIN_SPI, MIOS32_SPI_MODE_CLK0_PHASE0, MIOS32_SPI_PRESCALER_64);
    
      // determine next MUX selection
      int next_mux_ctr = (mux_ctr + 1) % 8;
    
      // loop over channels
      int chn;
      for(chn=0; chn<2; ++chn) {
        // CS=0
        status |= MIOS32_SPI_RC_PinSet(ARP_AIN_SPI, ARP_AIN_SPI_RC_PIN, 0);
        
        // retrieve conversion values
        // shift in start bit + SGL + MSB of channel selection, shift out dummy byte
        MIOS32_SPI_TransferByte(ARP_AIN_SPI, 0x06 | (chn>>2));
        // shift in remaining 2 bits of channel selection, shift out MSBs of conversion value
        u8 b1 = MIOS32_SPI_TransferByte(ARP_AIN_SPI, chn << 6);
        // shift in mux_ctr + "Link LED" status to 74HC595, shift out LSBs of conversion value
        //u8 b2 = MIOS32_SPI_TransferByte(ARP_AIN_SPI, ((chn == (ARP_AIN_NUM_CHANNELS-1) ? next_mux_ctr : mux_ctr) << 5) | link_status);
        u8 b2 = MIOS32_SPI_TransferByte(ARP_AIN_SPI, (chn == 1 ? next_mux_ctr : mux_ctr) << 5);
        
        // CS=1 (the rising edge will update the 74HC595)
        MIOS32_SPI_RC_PinSet(ARP_AIN_SPI, ARP_AIN_SPI_RC_PIN, 1);
        
        // store conversion value if difference to old value is outside the deadband
        u16 pot = mux_pin_map[mux_ctr] + 8*chn; // the mux/chn -> pin mapping is layout dependend
        u16 value = (b2 | (b1 << 8)) & 0xfff;
        previous_arp_ain_pot_values = arp_ain_pot_values[pot];
        int diff = value - previous_arp_ain_pot_values;
        int abs_diff = (diff > 0 ) ? diff : -diff;
        
        if( !first_scan_done || abs_diff > ARP_AIN_POT_DEADBAND ) {
          arp_ain_pot_values[pot] = value;
          
          // notify callback function
          // check pin number as well... just to ensure
          if( first_scan_done && _callback && pot < 16 )
            _callback(pot, value);
        }
      }
    
      // select MUX input
      mux_ctr = next_mux_ctr;
    
      // one complete scan done?
      if( next_mux_ctr == 0 )
        first_scan_done = 1;
    
      return 0; // no error
    }

    For your layout:
    You can change the MUXes mapping here:

      // the mux_ctr -> pin mappin is layout dependend
      //const u8 mux_pin_map[8] = {0, 1, 2, 3, 4, 5, 6, 7 };
      //const u8 mux_pin_map[8] = {1, 4, 3, 5, 2, 7, 0, 6 }; // reversed pins
      const u8 mux_pin_map[8] = {6, 3, 4, 2, 5, 0, 7, 1 }; // order of MUX channels

    You can reduce the channels:

        for(chn=0; chn<3; ++chn) {
    u8 b2 = MIOS32_SPI_TransferByte(AINSER_SPI, ((chn == 2 ? next_mux_ctr : mux_ctr) << 5) | link_status);

    And limits the number of inputs by security:
     

    	if( first_scan_done && _callback && pin < 24 )

     

×
×
  • Create New...