in reply to Re^12: warning: use of uninitialized value
in thread warning: use of uninitialized value

It's possible that you have blank lines or lines with just one part of the key like: 'chipId::'. You can skip those by checking for them explicitly or something like: next if $readline =~ /^$/;.

That said, you have ignored my first point entirely -- Do Not enclose the open in an if condition check.

This has already gotten really long - I'm not going to continue anymore. If you still have any more problems, open a new post and others will pick up where we left off.