• Content Count

  • Joined

  • Last visited

About sungsik

  • Rank

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Hi. now i am using ZYBO and i tried to implement ethernet communication with ZYBO. I already done Lwip echo server example [Getting Started with Zynq Server] ( and now i want to transfer PL data to PC by UDP based on this example. i did my best for 2weeks, it is difficult. The concept of ethernet is very strange for me. So. is there any example or SDK code as reference for UDP communication ? please anybody help! thank you.🙂
  2. hi Now i'm using ZYBO. I tried to send data from ZYBO to PC by ethernet communication. I already succeed to check lwip echo server example. ( what i want to do is sending XADC data from PS to pc by ethernet. So, can i do this by modifying echo server code? Is there any example about this? or other method? thanks.
  3. Hi. i'm newbie in electronic engineering. i start to study soc with zybo. When i saw schemetic of ZYBO, i founded some symbol that i have not ever seen. i attached picture. what does red symbol mean?
  4. sungsik

    xadc example on ZYBO

    Hi. Now i am using z-7010 with ZYBO. I tried to convert sine function (by function generator) to digital output. I used Aux14 P/N port. positive port was connected to sine signal and negative one was connected to ground.(like single-ended). I got an array of raw data using XSysmon_GetAdcData(), and converted that array by using newly defined function. (below code) #define XSysMon_RawToExtVoltage(AdcData) ((((float)(AdcData))*(1.0f))/65536.0f) Function generator output a 100-300mv, sine wave. But when i used serial oscilloscope to see waveform of digitalized output, amplitude of output signal was twice the input. As you can se e, amplitude is 200-600mV. i don't know why the output is twice the input. Is there any problem in my code? (I didn;t checked bipolar mode in xadc wizard.) i used below code. #include <stdio.h> #include "platform.h" #include "xsysmon.h" static XSysMon SysMonInst; //sysmon instance static int SysMonFractionToInt (float FloatNum); #define SYSMON_DEVICE_ID XPAR_XADC_WIZ_0_DEVICE_ID #define XSM_CH_AUX_7 23 //AUX7 #define XSM_CH_AUX_14 30 //AUX14 #define XSysMon_RawToExtVoltage(AdcData) ((((float)(AdcData))*(1.0f))/65536.0f) //#define XSysMon_RawToExtVoltage(AdcData) ((((float)(AdcData)))) int main( void ) { //u8 SeqMode; u32 TempRawData,VccIntRawData,Aux_7_raw,Aux_14_raw; float TempData,VccIntData,Aux_7,Aux_14; XSysMon_Config *SysMonConfigPtr; XSysMon *SysMonInstPtr = &SysMonInst; int xStatus; //prvSetupHardware(); SysMonConfigPtr = XSysMon_LookupConfig(SYSMON_DEVICE_ID); if (SysMonConfigPtr == NULL) printf("LookupConfig FAILURE\n\r"); xStatus = XSysMon_CfgInitialize(SysMonInstPtr, SysMonConfigPtr, SysMonConfigPtr->BaseAddress); if(xStatus != XST_SUCCESS) printf("CfgInitialize FAILED\r\n"); XSysMon_GetStatus(SysMonInstPtr); //polling while(1) { while ((XSysMon_GetStatus(SysMonInstPtr) & XSM_SR_EOS_MASK) != XSM_SR_EOS_MASK);// Aux_7_raw = XSysMon_GetAdcData(SysMonInstPtr,XSM_CH_AUX_7); Aux_7 =XSysMon_RawToExtVoltage(Aux_7_raw); Aux_14_raw = XSysMon_GetAdcData(SysMonInstPtr,XSM_CH_AUX_14); Aux_14 =XSysMon_RawToExtVoltage(Aux_14_raw); TempRawData = XSysMon_GetAdcData(SysMonInstPtr, XSM_CH_TEMP);//Read the on-chip Temperature Data TempData = XSysMon_RawToTemperature(TempRawData); VccIntRawData = XSysMon_GetAdcData(SysMonInstPtr, XSM_CH_VCCINT); //Read the on-chip Vccint Data VccIntData = XSysMon_RawToVoltage(VccIntRawData); //for serial oscilloscope printf("\r\n%0d.%03d,%0d.%03d,%0d.%03d,%0d.%03d", (int)(Aux_7), SysMonFractionToInt(Aux_7), (int)(Aux_14), SysMonFractionToInt(Aux_14), (int)(VccIntData), SysMonFractionToInt(VccIntData), (int)(TempData), SysMonFractionToInt(TempData)); } return 0; } /*-----------------------------------------------------------*/ /*The AUX14 channel is defined to be 30 in xsysmon.h :*/ // #define XSM_CH_VCCPDRO 0x0F /**< On-chip PS VCCPDRO Channel, Zynq */ #define XSM_CH_AUX_MIN 16 /**< Channel number for 1st Aux Channel */ #define XSM_CH_AUX_MAX 31 /**< Channel number for Last Aux channel */ #define XSM_CH_VUSR0 32 /**< VUSER0 Supply - UltraScale */ int SysMonFractionToInt(float FloatNum) { float Temp; Temp = FloatNum; if (FloatNum < 0) { Temp = -(FloatNum); } return( ((int)((Temp -(float)((int)Temp)) * (1000.0f)))); } //---------------------------------------------------------------------------------------------- thanks.