I am trying to read from serial port that receives data from an Arduino nanodevice, I already have matlab implementation of it and it reads the correct data,
However, I am trying to migrate it to node js, and I am having following issue, The data that should be received as ']<N ÿÿ¢ ÿÿò½·½ÓïÏÜÔιõa' is actually getting received as ']<N�������������������P�k�z^�y| zz{zz|{|��s?f���>oC���B�'
The first frame above is how I am receiving it in matlab and therefore I am able to use it, in node js for some reason the whole frame is replaced by '?'. especially characters such as 'ÿ' are replaced by '?'. I am using the serial port module used a read line parser the snippet looks like,
myPort.on("data", data => {
console.log(data);
});
This definitely not a baudrate issue as other data is received perfectly. it has something to do with the encoding.