Hi!
I would configure a 12f675 to send midi messages, i know it is possible with the serout2 command, but the rate of midi is 31250 so i must use an external 20mhz crystal and bypass the internal clock.....How?
Thanks in advance
Hi!
I would configure a 12f675 to send midi messages, i know it is possible with the serout2 command, but the rate of midi is 31250 so i must use an external 20mhz crystal and bypass the internal clock.....How?
Thanks in advance
hi
cool project!
i did the same with an 16f876a once, here the most important settings :
this commands and defines are the same on a 12f675Code:DEFINE OSC 20 ' oscillator speed define HSER_TXSTA 20h ' enable transmit register define HSER_BAUD 31250 ' midi baud rate hserout [$90,$45,$40] ' send a midi comand. noteon ch 1. middle A. middle velocity
eventually it would be possible to work with the debug command on the 12f675 and you could use the internal oscillator. must be tried. the debug command is the most fastest of the serial commands.
take a look at the pbp manual for setup the right debug settings.
I used this hardware setup
cheers
i know it's only microcontrolling, but i like it!
thank you mischl!
But the hserout command "Send one or more Items to the hardware serial port" and the 12f675 hasn't one!
I used this SerOut2 PORTB.3,12,[$B0,0,control] with a 16f84a and it's ok,but with 12f675 it doesn't work!
Any idea?
GPIO.3 is INPUT ONLY. Use a different pin and please read the datasheet. You probably need to disable AD and comparator aswell.
I used gpio.2 as output to send midi messages and i must use the gpio.0 and gpio.1 as ad inputs with pots!
I'm a beginner in pic programming,so please explain me how to configure these pins!
Thanks a lot
uuups. sorry, you are right, there is no uart at the 12f675 ;-)
look at the manual under SEROUT2 for calculating baud rate. 31250 baud needs a 20 mhz crystal.
for analog in : some sample program with a 12F675 look at TESTX4.BAS
i know it's only microcontrolling, but i like it!
Bookmarks