cancel
Showing results for 
Search instead for 
Did you mean: 

How to configure clock at 38 Khz with some other operation

parag
Associate II
Posted on June 11, 2011 at 00:22

Hi All,

     I want to configure the clock output at 32 Khz to 38 Khz in one of the pins and at the same time I want to send the data from USART. It is like two parallel operation; one pin is continuously generating the clock ouput independant of the other operation. Can we configure the clock like that with their respective pin? I read about MCO pin but I did not understand how to code for 32 Khz to 38 Khz.

      My situation is like one pin will be continuously generating the clock and Tx of USART will be sending at the same time. I can do USART part, please help me for clock part.

Thanks in advance.

2 REPLIES 2
picguy2
Associate II
Posted on June 13, 2011 at 06:31

From your description it’s hard to understand what is the purpose of what you are asking.  I’m guessing you want a regular pulse stream plus RS-232.  With that in mind...

1) Make a regular pulse train with PWM.  Once started it requires no processor attention.

2) Do your RS-232 thing ignoring PWM output.

2a) See my http://hmtown.com/fifo.htm for a simple way of separating the logical and physical parts of RS-232 communication.
Posted on June 13, 2011 at 17:32

[DEAD LINK /public/STe2ecommunities/mcu/Lists/cortex_mx_stm32/Flat.aspx?RootFolder=/public/STe2ecommunities/mcu/Lists/cortex_mx_stm32/How to configure clock at 38 Khz with some other operation 8121&FolderCTID=0x01200200770978C69A1141439FE559EB459D7580009C4E14902C3CDE46A77F0FFD06506F5B&TopicsView=https://my.st.com/public/STe2ecommunities/mcu/Lists/cortex_mx_stm32/AllItems.aspx&currentviews=25]Duplicate Thread - FYI

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..