How to position textview in text in arkit

I am trying to enter textfield text as arkit text and place the text as a object in the arkitview. What I have below is not working and there are a couple of compiling errors.

let cZ = randomFloat(min: -2, max: -0.2)
   //uitextfield
let cubeNode = SCNNode(theBar.text!)



let cc = getCameraCoordinates(sceneView:augmentedRealityView )
cubeNode.position = SCNVector3(cc.x, cc.y, cc.z)

augmentedRealityView.scene.rootNode.addChildNode(cubeNode)