Hello,
I have an aplication that uses 2 stop bits (4800,N,8,2) and I don't know how to do it using PBP compiler.
It is possible?
Can you help me please?
Thanks for your support
Pimentel
Hello,
I have an aplication that uses 2 stop bits (4800,N,8,2) and I don't know how to do it using PBP compiler.
It is possible?
Can you help me please?
Thanks for your support
Pimentel
Stop bits are at "IDLE" level.
So if you use ...
DEFINE CHAR_PACING xxx
where xxx = 1 bit period in us, then you're good to go.
<br>
DT
Darrel, Can you help me?
I restarted my old project and now I need to send a serial data in 4800 TTL levels , 8 data bits and 2 stop bits. How to do it using PBP?
I have to simulate the second stop bit ok? And 1 bit in 4800 baud ~ 208us
The 4800 baud is missing in the serout command mode but is possible to use char_pacing in microsenconds
Using the serout2 command is possible to use a {pace} but just in milisenconds !
How to do it then???
Thanks
Pimentel
http://melabs.com/resources/ser2modes.htm
Has the modes for 4800.
Dave
Always wear safety glasses while programming.
Pimentel,
You could try something like this ...Assuming you have PBP 2.60
Code:DEFINE OSC 8 BuffLength CON 32 Buff VAR BYTE[BuffLength] Idx VAR BYTE SerPin VAR PORTC.6 HIGH SerPin PAUSE 100 Main: ARRAYWRITE Buff,["Hello World!",13,10,0] GOSUB SendBuff PAUSE 1000 GOTO Main ;---------------------------------------------------- SendBuff: FOR Idx = 0 TO BuffLength -1 IF Buff(Idx) = 0 THEN EXIT SEROUT2 SerPin,188,[Buff(Idx)] PAUSEUS 220 NEXT Idx RETURN
DT
Thanks Darrel,
I am using 2.46 version!
I will test it idea today on job. I do not know if go work because I already tested it:
SEROUT2 TX,188,[$00,$50,$42,$01,$0A] 'ex: 14.2500 MHz
and other mode:
SEROUT2 TX,188,[$00]: PAUSEUS 208 '1/4800 ~208us
SEROUT2 TX,188,[$50]:PAUSEUS 208
SEROUT2 TX,188,[$42]:PAUSEUS 208
SEROUT2 TX,188,[$01]:PAUSEUS 208
SEROUT2 TX,188,[$0A]:PAUSEUS 208
but without sucess!
Why do you used a pauseus of 220us?
I used a 4MHz cristal as osc
Thanks again
Pimentel
Bookmarks