Sep 22, 2013, 9:07 PM
Post #2 of 4
I cannot help you with your use of the module. You are right that you are using C rather than perl syntax for your array declaration.
Re: [SuperDude123] Writing to array to send to RS-232...Need Help with my code
[In reply to]
In perl, you must declare an array with an @ rather than $. In perl, we almost never specify the size of an array and you cannot do it the way to tried. Also note that your array has 19 elements.
Assuming that you need an array, Declare it:
Later you can initialize it by assigning a list to it:
Also note: Unlike C, strings in perl have nothing to do with arrays. I do not know your requirement, but it is likely that you need a string rather than an array.