Reputation: 3822
I wanted to know whether there is any endpoints available for reading from Serial port in Apache Camel. I heard that MINA can be used for the purpose but I can't find an example for that. Can anyone help me?
Upvotes: 1
Views: 1139
Reputation: 141
If you're thinking usb, rather than rs232 the Stream component would do it. This is what I use to read my arduino on my MacBook:
<route>
<from uri="stream:file?fileName=/dev/cu.usbserial-A900acSz&scanStream=true&scanStreamDelay=1000"/>
<convertBodyTo type="java.lang.String"/>
<to uri="seda:myfeed"/>
</route>
scanStream gives you a tail -f equivalent on a 'file'.
Upvotes: 1