Sand Casting Implementation of Two-Dimensional Digital Code Direct-Part-Marking Using Additively Manufactured Tags

Statistical quality control is used in foundries to identify special cause defects and root causes by correlating process input variations with casting defects. A difficulty exists in associating process data collected with individual cast parts as the parts are processed through the foundry and then out into the supply chain. Typically, alphanumeric labels for marking castings and manual identification of the castings with route-paper based tracing approaches have been used. Such manual-based systems make root cause analysis of quality defect issues tedious. This study presents the development of a semi-automated approach using 3D printed sand mold inserts shaped as 2D matrix codes which thereby permit directly cast identification code into the parts. This enables automated part tracking at the very beginning of the casting process including mold making. Automated scan based tracking of parts through a foundry and subsequent supply chain allows for statistical process data collected to also be associated with each part processed with unique identification, building upon the part history and pedigree.


Introduction
In the metal casting industry, the Smart Foundry concept is being developed to improve workflow and quality. This includes elements such as internet of things (IoT) process automation and data collection with process data analytics to and track quality capability data and obtain higher quality metal castings. 1,2 This also includes process automation, to enable a part itself to indicate any needed process setups. 3 As a part of these efforts, object identification and tracking technologies are needed to enable part interaction with production systems with real-time data transfer. To do this, a smart object must carry a unique digital identification, such as provided by barcodes, 2D part codes, RFID tags or similar. 4 Yet today, many foundries continue to use manual based route papers for part identification, tracking and data collection. 5 Processes such as pattern preparation, molding, melting, and casting have extreme environments, and uneasily observed conditions make it difficult to trace individual materials, consumables and castings. Given this difficultly, cast part markings are often made using identifiers on the pattern plate or on mold inserts. As such, most part tracking does not initiate until after a casting is made. For example, each casting can have an identification number including date and logos, where marking patterns must be adjusted for each of the castings. On the other hand, to maximum data utilization for process management, parts ought be marked at the earliest stage of the production. 6 A method to permanently label parts including serial numbers and other necessary information is called a direct part marking (DPM). A direct part marking that allows labeling on the early stages of the casting operations and provides access to digital identification for IoT process control is necessary. In this paper, a novel method for direct part marking of sand castings utilizing additively manufactured mold inserts containing machine-readable 2D codes is demonstrated. This enables rapid and simple creation of part-level customized identifiers permanently molded into the cast part.

Related Work
Eddy et al. 7 developed a digitalized framework for capturing and analyzing quality in a factory. Product development can be accelerated by utilizing increasingly available data from manufacturing and service. To accomplish this, it is important to associate data points collected on each machine with parts tracked through the factory. In this study, an approach is developed for cast parts with direct part markings.
Studies are employing foundry data analytics based on machine learning to compute the values of posterior probability for each input parameter. 8,9 This is a challenge in casting practice, since there are large number of parameters related to process and alloy composition involved. Also, many parameter values change for every casting, and so their effect on quality is not very well understood. It, therefore, becomes difficult to identify the most critical parameters influencing the quality of castings without associating process data collected with individual cast part quality inspection data. 10 Some form of tracking of parts is needed to associate process measurements with part quality inspection measurements. Richard et al. 11 utilized 3D printing of casting patterns. This allows for more complex castings. In this study, 3D printing technology is utilized to manufacture part marking tags for sand casting applications. The readability of a tag directly marked on a casting is in part related to the casting surface quality. Many studies have considered methods to characterize casting surface inspection quality. Tuttle et al. 12 consider the effects of sand binders and shakeout on surface quality. Daricilar and Peters 13 discuss the repeatability and reproducibility of image analysis for visually inspecting casting.
There are several methods under study for marking parts for tracking purposes. These include methods such as postfabrication adhered printed alphanumeric labels, laser markings and pin markings. Also, there are several methods under research for directly marking the part inherently in its fabrication. These include marking patterns of tags added to casting patterns or molds as stencils. These works are reviewed here.
Historically, alphanumerical labeling has been the marking method for many foundries regardless of production type and size. This method is often tedious requiring changing letters for each part or batch's mold according to the date, identifier and additional information. The part identifiers can be challenging if defects such as sand-metal penetration occur on the marking letters. This creates additional detailing challenges in fettling and cleaning.
For sand-based casting operations, laser technologies have been used to mark the sand molds or core boxes with alphanumerical characters shape. This allows marking each individual casting separately. Especially in foundries using single batch identification numbering for many parts, this technology becomes beneficial in terms of handling and tracking individual castings.
With laser marked parts, optical character recognition (OCR) technology can be used to read the alphanumeric characters. However, shiny metal surface reflectivity can cause unacceptable reading rates for OCR. Song et al. 14 have applied graphite printing of QR codes onto sand cores to track cores internal to the foundry operations. Winkel and Stein 15 have developed 3D techniques utilizing a stripe projection to allow reading of shape information rather than OCR. Another issue is laser marking systems often have a large footprint on the foundry floor and can become difficult for different mold pattern geometries. Further, laser safety risk can become important in a man-powered foundry environment. 16 Overall, there remain several issues for implementation of laser sand engraving technology, including difficulties in enterprise resource planning of the foundry, automated laser etching and id code reading.
Another part marking technology is the reconfigurable pintype tooling which enables direct part markings in green sand permanent molding machines. 17 A pin tool is applied to the inside of the mold which creates a Datamatrix symbol pattern. With this method, a unique DPM can be given to each individual casting. Vedel-Smith and Lenau 17 also studied the robustness of the matrix patterns generated through embossing the sand patterns in this manner. They reported that dots created as bumps survived the casting process well. Part markings created as dimples, however, were less structurally sound and generated defects in the casting process.
Another method of direct part marking is to make use of stencils made from mineral fiber with clay and latex binder. This is fastened to the sand after it has been sprayed with hot-melt glue, and the stencil can be used for much type of metals. This provides permanent DPM patterns that can be applied in sand, lost foam, investment and permanent mold castings. The stencils can be prepared as pre-encoded via automated laser engraving system in a special box. 18 Finally yet importantly, there are couple of manual subprocesses such as spraying heat-resisted adhesives on to stencil and preparation of the mold surface as well as after production-the contrast painting of the DPM codes. Additionally to sub-processes, consumables such as thermal spray prints need to be used to provide contrast to DPM codes.
Another method is to use CNC machined pattern inserts. Saveraid 19 studied contrast differences for two-dimensional code readability when using bumps or dimples in CNC machined plastic permanent patterns for sand molding. He compared using both dimples and bumps for their readability as direct part markings and found dimples to consistently have higher contrast and better readability.
In addition to markings embedded in the part at the onset of production, there are also post-production marking methods such as laser-engraving technology, 20 pin impact marking 21 or even simple painted stencils. In contrast to the methods has been discussed so far, such methods are used at the end of the production phase and used for part tracking in production steps subsequent to casting operations. Here, it is focused on part marking technologies that can be used to track parts in casting operations.

Additive Manufactured 2D-Code Inserts
3D printed tags are beginning to be explored for use in part identification and casting. 22,23 Kikuchi et al. 24 discuss algorithms to represent 3D shaped two-dimensional QR codes shaped onto curved surfaces, but for 3D printed parts. This result has the potential for use in future work to create curved surface 2D code inserts for casting, but remains unexplored The process of creating an additively manufactured wax pattern identification tag is explored here, complete as a two-dimensional matrix code for direct application in traditional lost wax sand casting. There are several methods available for augmenting a traditional casting process with a wax tag. With investment casting using wax patterns, a wax tag can be easily added to the pattern and the traditional lost wax process used. With sand casting, a wax tag can be added to the pattern and a sand mold created. Yet, a third option is to apply sand molding with a pattern to which the tag is inserted but not attached. The wax tag can remain in the sand mold and burn away upon casting.
For sand casting with a detailed tag unique to the individual casting, this last option is likely a good candidate for quality in readability and ease of operations. This third option of using tags is explored here, using wooden patterns with the tag remaining in the sand molding.
As outlined in Figure 1, our research methodology is to explore the necessary steps including generating a unique digital identifier, converting this into a three-dimensional tag and from this creating a direct part marking on a casting.

Step 1: 2D Code Generation
The first step is to generate the tag design. The 2D code matrix design includes symbology concerns over size and complexity. The 2D code concerns for cast part markings include factors such as the dimension of the DPM frame and the number of small squares within the matrix needed to digitally represent an ID code. Smaller dimensions are better for small castings, but larger dimensions may be necessary for readability and castability of a marking. Further, part identifiers with more digits require more dots and hence a more detailed 2D code.
Another concern for cast part markings using 2D codes is the coding standard. 25 There are many coding standards available, both proprietary and public domain. Here, the popular Data Matrix Code standard 26 is explored. An alternative matrix coding system, the Dotcode standard is also considered, 27 since it includes an adjustable dot spacing and has a dot pattern with no adjacent dots. This coding, therefore, can perhaps be most readable as a casting. Based on this, these two coding standards here for direct part markings on castings are explored and compared.
As a demonstration, several part identifiers encoded with 10 decimal digit complexity are considered. For example, a ten decimal digit number might be '1234567890'. The addition of alphanumeric including letters and numbers also changes the digital coding complexity. More complex strings can be used to include text such as a URL, but the tag size grows accordingly. Foundry surveys indicated an alphanumeric string of 10 digits are adequate for identification purposes. 5 Given a text string to be converted into a matrix code, the Datamatrix two-dimensional pattern is different if generated as a square pattern or as evenly spaced dots. Figure 2 shows the difference between the square version and the dot version of the Datamatrix for our reference numeric string. This choice of squares or dots is an option in Datamatrix code generation software. Ventura et al. 28 report that the square Datamatrix creates contrast issues which have a negative affect on readability when etched onto metal surfaces. Further, for our metal casting purposes, dots are more easily generated than squares as 3D dimples or bumps. Therefore, the Datamatrix dot pattern was generated. The Dotcode standard is inherently made of dots.
The two code-type matrices were generated for testing purposes using common matrix code generator software. The difference of the Datamatrix dot pattern and the Dotcode matrices for the same 10 digit '1234567890' example is shown in Figure 3.
Notice the outer dimensional frame ratios are different for the two different coding standards. The Datamatrix frames are always square, whereas the Dotcode frame can be rectangular; the aspect ratio is selectable. Also, the Datamatrix codes have lower left continuous alignment dots by default, so the orientation is always understood. On the other hand, Dotcode matrices never have dots next to one another, the dots are always diagonal and so are perhaps more easily cast. As a result, Dotcode matrices are also inherently larger in terms of matrix cells.
For the chosen text string, the Datamatrix had 12 dots per side (144 cells). Since Dotcode matrices can be rectangular, the default rectangular pattern with an aspect ratio of 12 columns by 19 rows (228 cells) was chosen. The sizes shown in Figure 4 are the minimum necessary to represent 10 decimal digits. Shown in Figure 4 are matrix code sizes for different number of decimal digits. The tabulated results are larger when including letters in the code, but nonetheless, the trends hold. Generally, either coding system works well.
One obvious consideration is the dot size: the dot diameter and the dot spacing. Smaller and tighter dot geometry results in smaller tags, but also a tag that is more difficult to consistently fabricate and cast into a resulting part marking. The Datamatrix default dot spacing to dot size ratio is 1 to 0.85, whereas it is selectable for the Dotcode matrix. The default Dotcode spacing was chosen to be the same as the Datamatrix of 1 to 0.85. An expectation was for the Dotcode to be more easily read that the Datamatrix result, since the diagonal dot spacing allows for improved sand molded surface quality given the prevention of possible molding defects from loose sand attached to any dot.
Between the tag fabrication using an additively manufactured wax printer and the sand casting process, the sand casting is the limiting process in terms of dimensional control. The sand casting process and sand used had a grain size of 0.2 mm, and a minimum of three sand grains creates   a castable shape, and therefore, a minimal castable thickness was determined 0.6 mm. Therefore, the minimum dot and bump size were deemed 0.6 mm, and the minimum separation between dots was deemed 0.6 mm. These dimensions were applied for a minimum tag size, with larger dots and spacing also studied. Given the tolerance capability of sand casting at less than a millimeter over the tag dimensions, a dot size and space at 2x larger were chosen. Also, tags at smaller and larger dot diameters of 1.5, 2 mm and 2.5 mm were created.
The dot size and spacing are the tag design variables that drive the tag design. The overall dimension of the tag is therefore variable depending on the complexity of the coded identifier. For our 10 place decimal number and with the 1.5 9 1.5 mm cylindrical dots, the resulting tag size was 2.8 9 2.8 9 0.3 cm, as shown in Figure 5.
Another geometrical decision is whether to use dimples out of the tag or hole bumps into the tag. Either can generate visual outline shadow pattern that an optical code reader could image and decode.
There are also further refined detailed geometric dimensions necessary to a tag. For example, the back plane thickness was chosen at 3 mm. Also, every bump as a cylinder has a base and crown fillet radius. These detailed dimensions were left at the capability of the casting process used.
Step 2: 3D Printing of the DPM Tags In our process shown in Figure 1, the next step is to manufacture the tag represented by the 3D solid model of the 2D matrix code. For rapid and mass-customized generation of a wax tag that can be added to a traditional wax pattern, the idea of a rapid additive manufactured tag was explored.
The wax tag was printed using a 3D wax printer with dimensional accuracy of ± 0.0254 mm, the ProJet MJP 3600W printer. Figure 6 depicts the bump and dimple alternatives of the Datamatrix tags printed as wax tags. The wax material used was a purple colored wax material.
The wax printing process includes a backing material upon which the wax is printed. A post processing step is to chemically remove this backing. This dewaxing operation of the support wax had no impact on the top surface wax tag dot matrix.
The resulting tags appeared consistently high in surface quality. In Figure 6, notice the contrast differences in the image of the tags themselves, as bumps or dimples. As a check, the printed wax tags for readability were tested with consistently positive results for both the Datamatrix and Dotcode tags. Read attempts were successful with either dimple or bump dots, with 1.5 mm dot diameter and 0.5 mm spacing between adjacent dot centers.

Step 3: Sand Mold Making and Casting
The next step is to combine the created wax tag with the pattern fabricated to cast the part. Our pattern is a CNC machined wooden block structure. The wax tag was attached to the wooden pattern with a small amount of adhesive tape.
The resulting pattern complete with attached tags is shown in Figure 7, within the wooden molding frame. The Datamatrix and Dotcode tags, each at 1.5, 2.0 and 2.5 mm dot sizes as bump versions, are attached to the rectangular block pattern.
With this pattern complete with wax tags, the sand mold can be fabricated. Our molding sand was 0.2 mm quartz sand with an ester hardened alkaline phenolic binder, hand molded. When the pattern was removed from the upper mold, the wax tags remained with the sand mold and gating is arranged accordingly to the bottom mold. During the pour, the wax simply burned away.
Subsequent to the molding process, the test parts were cast with molten recycled Aluminum at 740°C. The casting result was air cooled in the foundry laboratory.

Experiment Scope
While the process outlined is clear, feasibility remains to be demonstrated. To consider this, several tag dimensions were studied as well as code reading metrics including contrast. This is reviewed next.

Tag Size and Type
The tags were 3D printed in three dot sizes and two dot types (dimple or bump), as shown in Table 1. After the manufacturing, the tags are visually tested and read by DPM reader. After the sand mold making process, molten aluminum is poured to create the actual casting, at which time the 2D code wax patterns are burned away. After  cooling, the parts are cleaned and the DPM tags tested and analyzed by their quality characteristics.

Quality Characteristics
An industrial scanner (Honeywell 1920i) and a mobile phone camera (Samsung S4) with a free barcode reader application were both used as image sensor for readability tests of the DPMs. An enclosed photo booth was used capture images according to ISO/IEC DIS 29158 standards. 29 Accordingly, two directions and types of lighting were setup, where the light source is aimed at the part at 30°and 45°angles, from two sides of the part. The camera is positioned such that the plane of the image sensor is parallel to the plane of the symbol area, a 90°camera angle. A Pass/Fail read test was used to assess the readability of DPMs. Two randomized repeat tests were done per condition, both equally for the industrial reader and the mobile phone.

Experiment Results and Discussion
The objective of the experiment was to determine the decodable symbol that could be sand molded and cast in aluminum, as well as to estimate the readability relation by size and contrast modules (dimple and bump). It was clearly observed that bump DPMs have higher surface roughness and are less readable than dimples (see Figure 8). At the smallest dot size of 1.5 mm, the bumps were not readable, while the dimple version was completely readable.
Tag Casting Results Figure 9 shows a view of the Datamatrix and Dotcode DPMs after the casting, mold breaking and cleaning process. These parts were studied at each of these steps for casting quality considerations, including the separation of dots, missing dots, adjacent dot wall thickness and surface quality. These can all impact readability.
As shown in Figure 10, the 2.5 mm dimple Datamatrix code shows high surface roughness from the casting process, with a negative impact on apparent contrast. The Dotcode code shows high surface accuracy and excellent contrast. Notice the Dotcode has even higher wall separation and excellent contrast at the same dot size, since adjacent dots are always diagonal.

Tag Readability Experimental Results
Next, tag reading experiments are completed as outlined in Figure 1. Part quality is considered in terms of tag readability for purposes here. Additional quality concerns include internal quality such as porosity that is left for future work. It could be the case that burn out of paraffin wax or PLA plastic tag material could affect the porosity, particularly for aluminum castings. However, the combustion products would only affect the metal quality if the tag size is not small compared to the casting. Further, proper gating and risers can mitigate this. Nonetheless, the impact of tag burn out on porosity remains as future work. Table 2 shows the Pass/Fail results over all reading conditions, both equally for the industrial reader and the mobile phone. There was no difference in the readability test results between the industrial reader and the mobile phone application.
There are 65 dots on the Dotcode and 83 dots on the Datamatrix code for the same ten digits of numbers encoded as a part identification number (1234567890). This represents how many dots are need to encode the part identification for representation in the production process. The Datamatrix code is inherently more compact, since it makes use of adjacent dots, whereas the Dotcode always has diagonal dot spacing, as can be seen from the Figure 10. In the molding process, wider dot space results in improved DPM form as a result of better sand filling. Less space between dots also creates higher susceptibility of the tag pattern in the sand of the mold due to possible impact damage from the working environment. The Dotcode is more robust to the sand molding process.
On the other hand, the Datamatrix code occupies less space on the metal part and has less 3D printed material   consumption accordingly. As the number digits represented increases, the Datamatrix code begins to offer substantial size advantage.
Finally, the Datamatrix code has better error correction capability, where the code remains readable with 17% error in the dots. In our experiment, when 14 of the dots were missing, the code was still readable. 29 No such error correction is provided with the DotCode standard. It was observed that 2.5 mm casting had three dots missing and it remained readable, a 5% error rate.

Verification Across Multiple Identifiers, Parts and Operations
The previous discussion developed the process parameters and settings needed to effectively cast direct part markings using sand casting, in terms of dot code size, shape and location. To demonstrate this, direct part marking is applied to a variety of parts.
Various unique identification codes on the same part were attempted. The readability at various steps in the casting process from molding to final part was checked. Finally, the readability of codes on a variety of different parts was checked.

Verification of Reading Multiple Unique Codes
To verify the efficacy of the process, first multiple tags each with a unique code are made and used while serially casting a rotor part, each with a unique tag. In this, 48 rotor parts are casted each with a unique tag identifier. Four examples are shown in Figure 11.
A set of four rotor patterns were used in each mold, with the tag placed at the top of the mold. The riser supports are included next to each tag to ensure adequate venting and feeding, to allow the 3D printed tag gases to vent as the tag burns away. All 48 rotor tags were readable as metal rotor cast parts. All of the 48 part castings were readable using a common mobile phone barcode reading app.

Verification of Multiple Operations
Further, the efficacy of the approach within foundry operations was tested, including sand molding, metal casting, shakeout, cleaning and finishing. The intent was to capture processing data associated to each unique cast part. For example, Figure 12a depicts the pattern with four different encoded marking tags (3D printed) on the pattern before the sand molding process. The pattern is removed from the sand molding, but the plastic tag remains in the mold during casting and burns away. Figure 12b shows the results after mold shakeout on the metal casting. These tags and tag imprints were all readable even at this early stage in production before cleaning and finishing. Cleaning and finishing were done using metal brushes, cutting each piece and polishing. All of the 48 cast parts were readable using a common mobile phone barcode reading app even at shakeout.

Verification of Multiple Parts
To demonstrate the usage of the tags in foundry operations, variety of codes could be marked on a variety of different parts. Figure 12 shows a set of different shaped parts that were marked in size and shape according to our findings. These codes were all successfully created and were readable.
The experimental summary for the different parts and identifications encoded is show in Table 3. It was found that with proper gating, all parts can be successfully direct part marked. Four very different part shapes were cast and some with repeated counts. Most parts were easily setup for casting with easily read tags. Some parts can be more difficult due to their shape and require more careful gating. This included the valve body shown in Figure 12c. The cause of the non-readability with the valve body was tag burning and inadequate feeding and venting from poor initial gating. If the tag location has inadequate feeding and venting, then when the plastic tag is burned the tag gases can destroy the marking, as shown in Figure 13. This is dependent on the part shape and gating design to ensure the metal fills the shape and gases vent. The tag needs to be on the path of metal flow and gas release, to allow the metal to fill and burn the tag away and for the burned gases to escape.
Overall, direct part markings as 2D codes can be casted into the part using sand casting. Care is needed to ensure the gating system is adequate for the part. Problems arise when there is insufficient metal volume to burn the tag (inadequate gate height) and if there is insufficient gas escape path (inadequate riser location). Also, the mold can have insufficient sand binder content leading to tag separation from the mold. These are all typically well controlled with mold and gate design ( Figure 14).

Conclusion
To implement the digitalized quality control and part compliance certification, there is a need for permanent digital part markings. A rapid marking system was demonstrated here making use of 3D printed tags for use directly in the molding process. This enables data codes which are readable even with by mobile phone barcode reading applications. This enables cast part traceability using ubiquitous mobile phone applications rather than expensive dedicated industrial readers. This method was demonstrated with sand castings but can be easily extended to other forms of casting such as investment casting. There are limits on part size, small parts become difficult since they need a surface big enough for the tag, and metal volume big enough to burn out the tag.
The future work now extends to considering how the embedded codes enable traceability in foundries, including linking the history of production to the part. For example, research is needed into cloud-based storage of material, sand, machine, operator, pattern, etc., data. This should consider using DPM codes for workstation setups and consideration over how many setups to employ versus often a scan is needed in a process flow. Also, future work ought consider industry standard coding schemes to allow for company agnostic coding.
Overall, there are number of important characteristics to consider in matrix code DPMs. The choice of coding   Figure 13. Valve body casting with inadequately filled and vented tag, the same part as Figure 12c.
standard such as Datamatrix and Dotcode has an impact on the tag size and castability. The results also indicate that dimple versions are more readable. Finally, high contrast is needed for a readable tag, and dot sizes larger than the inherent molding tolerance are necessary. In summary, 3D printing of matrix code tags for sand casting provides a feasible means to provide permanent digital part markings.
It was further confirmed the tag solution worked within a sand molding foundry operation. An operator can uniquely mark, identify and track the parts throughout the foundry operation. This application enables a simple tracking operation via industrial tablets or mobile phones utilizing free barcode reader application. Such an application would help solve a huge individual digital part tracking problem which remains as obstacle for a foundry's industrial 4.0 transformation as well as please the foundries' customers by enabling digital code reading of purchased parts.

DM DataMatrix coding DC
DotCode coding DPM Direct part marking IoT Internet of things OCR Optical character recognition RFID Radio frequency identification