<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>UART IRQ Callback Set Causes Crash</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/85010/uart-irq-callback-set-causes-crash</link><description>Hi, 
 I have a nRF52833 DK which I&amp;#39;m evaluating for a new product which uses a UART connected GPS receiver. 
 I found some simple UART code which compiles OK, but crashes when uart_irq_callback_set is called. 
 I think I have everything set up OK, so</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 22 Feb 2022 16:26:24 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/85010/uart-irq-callback-set-causes-crash" /><item><title>RE: UART IRQ Callback Set Causes Crash</title><link>https://devzone.nordicsemi.com/thread/354414?ContentTypeID=1</link><pubDate>Tue, 22 Feb 2022 16:26:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:68ddf838-85b4-4d05-93f5-df512ff07c84</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Please try the project attached below and see if it results in the same crash. I have not worked with the &lt;a href="https://docs.zephyrproject.org/latest/reference/peripherals/uart.html"&gt;UART interrupt APIs&lt;/a&gt; before, but from the API documentation it seems like you can only call the send functions inside the UART callback itself. Maybe it is the call to uart_fifo_fill() from main() that causes your program to crash?&lt;/p&gt;
&lt;p&gt;Test code:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/7317.simple_5F00_uart.zip"&gt;devzone.nordicsemi.com/.../7317.simple_5F00_uart.zip&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;This project is one I made only to see if I could replicate the crash your mentioned. If you want a project to use as a reference, then it is probably better that you use the &lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/samples/peripheral/lpuart/README.html"&gt;Low Power UART&lt;/a&gt; SDK sample.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Vidar&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>