I'm sorry, I just don't understand what you're trying to do here. Debug will run to 115K baud. If you want faster, go hardware, or shiftin/ shiftout with a faster clock.Originally Posted by MaxG
I'm sorry, I just don't understand what you're trying to do here. Debug will run to 115K baud. If you want faster, go hardware, or shiftin/ shiftout with a faster clock.Originally Posted by MaxG
Dear Ron,
I am sorry for my poor way of self-explaining. I am only trying to transmit some data (16 bytes bursts) at 115Kbaud using a 16F84A, PBP and the command DEBUG or SEROUT. I started doing some testings on 12F629, 12F508... with their internal 4Mhz RC oscillators and I could not go faster than about 30Kbaud. I follow your advise and put a Crystal, 12Mhz, on a 16F84A to make my testings.
It happens the same; PBP and PIC 16F84A can not go faster than about 80Kbaud, sometimes even slower. DEBUG can not be used with 16F84a and a 12Mhz EXTERNAL HS OSCILLATOR for reaching 115Kbaud. I suppose (I know) that in pieces with specific Hardware for Serial in/out, rates faster than 115Kbaud can be programmed but I would like to know why I can not reach 115Kb with the configuration noted above and where can be found a document with the limits for the commands DEBUG, SEROUT, SEROUT2. Again, I apologize for my short knowledge, and hope that you will be kind enough for taking a glance on my problem.
Sincerely,
Maxi.
The higher the baudrate the faster and more accurate the clock has to be.
I doubt you can achieve reliable 115k with only 12MHz Clock speed.
Try a faster (and calibrated) clock.
If you have a DSO, scope the output and push it step by step to the limits.
AND: I wouldn't put anything into production that is ways off specs.
regards
Ralph
_______________________________________________
There are only 10 types of people:
Those who understand binary, and those who don't ...
_______________________________________________
I've had no issues with a 4 MHz xtal and Debug pushing 115200 baud. Am I doing something wrong(right)?
Ron
Hello,
I have increassed the frec. of the crystal to 18.432 Mhz (I use this not very usual frec for generating accurate 4ms periodic interrupts) and put
DEFINE OSC 16
DEFINE HSER_TXSTA 20h
DEFINE HSER_BAUD 115200
in the testing software.
HSEROUT can output now 49 bytes in 3.340ms from inside a for..next loop (it counts an small time for jumping from the end to the begining of the for), what makes about 146Kbit/sec. The PIC used is a 16F876-20.
Ron, could you tell me what model have you pushed to 115200 baud with a 4Mhz crystal? I will try to reproduce your results. I do not like loosing time rediscovering the gun-podwer.
Last question: how can I define my 18,432Mhz oscillator to let PB generate accurate timming? Could it be done?
Thanks a lot
Maxi.
>> Last question: how can I define my 18,432Mhz oscillator to let PB generate accurate timming? Could it be done?
No. If you want to use faster clock speeds with PBP keeping good order, pick a frequency that PBP supports - see PBP's manual.
Thanks Melanie. I yesterday put a 20Mhz XTal and all in my "old fashioned assembler firmware" started to run under PBP (there is some line in assembler for the interrupt handler, but in general the program has won in clarity and number of features).
Maxi.
Bookmarks