You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
const { SerialPort } = require('serialport')
const port = new SerialPort({
path: '/dev/ttyAMA1',
baudRate: 38400,
autoOpen: true,
parity: 'even',
dataBits: 8,
stopBits: 1,
rtscts:true
})
port.open(function (err) {
if (err) {
return console.log('Error opening port: ', err.message)
}
console.log('Port opened! Starting timer')
setInterval(()=>{
console.log('Send HELLO')
port.write("HELLO",function(err){
if (err) {
return console.log('Error on write: ', err.message)
}
port.drain(function(){
console.log('- port data written')
})
});
},1000)
})
What happens?
The data is sent, but the RTS signal is not switched!
We tested it with an Oszilloscope!
The RTS signal could be switched back and forth with the manual command: port.set({rts:true/false}).
But we can't implement this with nodeJS because the timing would then become unacceptably bad
What should have happened?
I've already seen in the documentation that you probably haven't tested this board (V8) but it should probably work, but maybe you could still give me a tip on how to get it done.
Thank you and best regards to your Team
Additional information
With the following python script the RTS hardware handshake worked as desired!
SerialPort Version
12.0.0
Node Version
v20.7.0
Electron Version
No response
Platform
Linux pkcm4test 6.1.21-v8+ #1642 SMP PREEMPT Mon Apr 3 17:24:16 BST 2023 aarch64 GNU/Linux
=> Raspberry CM4
Architecture
ARM V8
Hardware or chipset of serialport
Raspberry CM4
What steps will reproduce the bug?
What happens?
The data is sent, but the RTS signal is not switched!
We tested it with an Oszilloscope!
The RTS signal could be switched back and forth with the manual command: port.set({rts:true/false}).
But we can't implement this with nodeJS because the timing would then become unacceptably bad
What should have happened?
I've already seen in the documentation that you probably haven't tested this board (V8) but it should probably work, but maybe you could still give me a tip on how to get it done.
Thank you and best regards to your Team
Additional information
With the following python script the RTS hardware handshake worked as desired!
No response
The text was updated successfully, but these errors were encountered: