In this post you are going to find the example codes that where mentioned during the "Learning to Easily Develop LIN-based Actuator Applications with Mixed-signal MCUs" webinar. In the "S12ZVMA_Webinar_ExampleCodes" package you are going to find the code for the S12ZVMA slave node, the code for the S12ZVL master node and the LIN configuration files (LDF and NPF's files).
In the images below you can find the information you need to know to create the setup and get running your LIN network and the DC motor.
Note: Remember that in this code we are using the active configuration where the High Side Driver and the Low Side Driver are being used to control de motor.
- Place jumper J21 in the position [3-2]. With this step, we are connecting the PHASE_A_HS with the PHASE_A_LS to get the active configuration.
- Connect one line of your DC motor to J30 (connect it in pin 2 or 3, do not use pin 1) and the other line to any GND point of your S12ZVMAEVB.
- Connect the master and the slave nodes using J6 jumper.