I’m working on a big project with a LPC core controlling several LCD’s Buttons,Led’s.
LPC17 core’s can’t control touch sensors so I have a PIC 18F in slave.
I’ve connected Tx(25) pin from the PIC to J11 MI1 P2.1 from the LPC.
I’ve made a copy from a pic (Old MIDIBox64 Project but still running 100% OK) with the PIC burner
The Midibox64 project has been configured for the MIDIbox - to - com link.
In the extern “C” void APP_Init(void)
I’ve set these lines:
MIOS32_UART_BaudrateSet(1, 38400);
MIOS32_MIDI_Init(0);
But nothing works, On midistudio I get an debug message from the midi receive handler(LPC) ==> Timeout on port 0x20
I don’t know what I’m doing wrong..
Also when i measure with a scope on pin 1 from the 74hc165 from the first touch sensors. i’ve get pulses for the first 5 a 10 seconds after thad noting.
Ive tested the pic in the old Midibox 64 project and thad works fine.
I don’t really know whats happening in the PIC, I know the pic works in an older midibox (using pre-made pcb’s from SmashTV).
This is on my own pcb, i dubbel checked every connection. I only can see if the pic is alive by meassuring the the clock or LD signals on the 74hc165.
The first 10 seconds I’ve get puls trains after thad it just stops.
It makes sense to troubleshoot this first before continuing with the LPC17 connection.
One possible reason for a “crash” (resp. hang-up) could be, that there are no pull-up resistors connected to Pin RA4 and RD5
It could happen that the MB64E application tries to read from a BankStick, and if it reads an “undefined” value (e.g. 0 instead of 1) then it could wait endless since clock stretching is assumed.
The settings I’ve made in the LPC are correct?
yes
Do I have to test UART0 or UART1 in my recieve midi package function? It’s kind of confusing when reading the MIOS32_MIDI functions…
I’ve made the midi connection to port p2.0 & p2.1
That’s UART0 (internally - in the software - we are counting from 0, for the users we are counting from 1)