开发者

Linux Uart driver modification

开发者 https://www.devze.com 2023-02-13 05:23 出处:网络
I want to modify my linux kernel\'s (2.6.32) UART driver.I am using the standard开发者_高级运维 uart driver for ttyS2 I dont know the exact files.The problem is Simple, setting and keeping a gpio pin

I want to modify my linux kernel's (2.6.32) UART driver. I am using the standard开发者_高级运维 uart driver for ttyS2 I dont know the exact files. The problem is Simple, setting and keeping a gpio pin high during transmission and while receving it must be low.

Which files should i refer to ? And any ideas about bitbanging gpio s from uart driver are wellcome...

Regards.


  • Try to understand how the Linux Serial Driver Layers are working and organized .
  • Determine which serial chip (driver) your device is using.
  • Hack the bit-banging GPIO into the low-lever driver.

OR:

Maybe you can abuse another signal line instead of a GPIO. If you operate your UART in RS485 mode, mostly the RTS behaves like you want -> high during transmission. I'm not sure if the rest of the communication would be rs232-compliant, but why not just try.

0

精彩评论

暂无评论...
验证码 换一张
取 消