- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm trying to work with the peripheral uart and I am having trouble compiling code when I added the initialization code as specified by the How to use the WICED Smart Hardware Devices. I've attached a snippet of the code:
static void peripheral_uart_init()
{
puart_init();
puart_flowoff();
/* BEGIN - puart interrupt
The following lines enable interrupt when one (or more) bytes
are received over the peripheral uart interface. This is optional.
In the absense of this, the app is expected to poll the peripheral
uart to pull out received bytes.
*/
// clear interrupt
P_UART_INT_CLEAR(P_UART_ISR_RX_AFF_MASK);
// set watermark to 1 byte - will interrupt on every byte received.
P_UART_WATER_MARK_RX_LEVEL (1);
// enable UART interrupt in the Main Interrupt Controller and RX Almost Full in the UART
// Interrupt Controller
P_UART_INT_ENABLE |= P_UART_ISR_RX_AFF_MASK;
// Set callback function to app callback function.
puart_bleRxCb = application_puart_interrupt_callback;
// Enable the CPU level interrupt
puart_enableInterrupt();
/* END - puart interrupt */
// print a string message assuming that the device connected
// to the peripheral uart can handle this string
}
I'm getting a compile error in the saying:
../../Apps/RAM/table_proximity/table_proximity.c:396:2: error: lvalue required as left operand of assignment
makefile:270: recipe for target '../../build/table_proximity-BCM920732TAG_Q32-rom-ram-Wiced-release/table_proximity.o' failed
make.exe[1]: *** [../../build/table_proximity-BCM920732TAG_Q32-rom-ram-Wiced-release/table_proximity.o] Error 1
Makefile:287: recipe for target 'RAM.table_proximity-BCM920732TAG_Q32' failed
make: *** [RAM.table_proximity-BCM920732TAG_Q32] Error 2
I have included uart.h at the top of the file.
Any help will be appreciated.
Thanks
Kartik
Solved! Go to Solution.
- Labels:
-
Peripherhal UART
- Tags:
- puart
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This has come up a few times recently.
You may find this thread helpful: Could you provide sample code using UART communication between BCM20732 and MCU?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This has come up a few times recently.
You may find this thread helpful: Could you provide sample code using UART communication between BCM20732 and MCU?