mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-17 06:13:33 +08:00
Fix LPC17 CAN driver; TX must be interrupt driven
git-svn-id: https://nuttx.svn.sourceforge.net/svnroot/nuttx/trunk@4290 7fd9a85b-ad96-42d3-883c-3090e2eb8679
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
/************************************************************************************
|
||||
* include/nuttx/can.h
|
||||
*
|
||||
* Copyright (C) 2008, 2009, 2011 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2008, 2009, 2011-2012 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@@ -84,6 +84,7 @@
|
||||
#define dev_ioctl(dev,cmd,arg) dev->cd_ops->co_ioctl(dev,cmd,arg)
|
||||
#define dev_remoterequest(dev,id) dev->cd_ops->co_remoterequest(dev,id)
|
||||
#define dev_send(dev,m) dev->cd_ops->co_send(dev,m)
|
||||
#define dev_txready(dev) dev->cd_ops->co_txready(dev)
|
||||
#define dev_txempty(dev) dev->cd_ops->co_txempty(dev)
|
||||
|
||||
/* CAN message support */
|
||||
@@ -205,6 +206,10 @@ struct can_ops_s
|
||||
|
||||
CODE int (*co_send)(FAR struct can_dev_s *dev, FAR struct can_msg_s *msg);
|
||||
|
||||
/* Return true if the CAN hardware can accept another TX message. */
|
||||
|
||||
CODE bool (*co_txready)(FAR struct can_dev_s *dev);
|
||||
|
||||
/* Return true if all message have been sent. If for example, the CAN
|
||||
* hardware implements FIFOs, then this would mean the transmit FIFO is
|
||||
* empty. This method is called when the driver needs to make sure that
|
||||
|
||||
Reference in New Issue
Block a user