EngineersGarage

  • Engineers Garage Main Site
  • Visit our active EE Forums
    • EDABoard.com
    • Electro-Tech-Online
  • Projects & Tutorials
    • Circuits
    • Electronic Projects
    • Tutorials
    • Components
  • Digi-Key Store
    • Cables, Wires
    • Connectors, Interconnect
    • Discrete
    • Electromechanical
    • Embedded Computers
    • Enclosures, Hardware, Office
    • Integrated Circuits (ICs)
    • Isolators
    • LED/Optoelectronics
    • Passive
    • Power, Circuit Protection
    • Programmers
    • RF, Wireless
    • Semiconductors
    • Sensors, Transducers
    • Test Products
    • Tools
  • Advertise
You are here: Home / Topics / operator ‘==’ has no left operand

operator ‘==’ has no left operand

|

Projects › Projects › operator ‘==’ has no left operand

  • This topic has 2 replies, 3 voices, and was last updated 7 years, 10 months ago by Ashutosh Bhatt.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • March 20, 2018 at 11:42 am #4720
    phoren
    Participant

    i wrote a peogram for measuring voltage using pic.but copiled that program i got ths error.

     adcValue/=100;
        #if==adcData  \here am getting that error.
        volt= (((float)adcValue*240.0)/1023.0);
        #else

     

    am using ic is dspic30f2010

    and the compiler is mplab c30

    anyone please help for solving this error.

    thanks

     

    March 21, 2018 at 6:57 am #14807
    GANEEV SINGH
    Participant

    Hi

    The error is correctly highlighted by the compiler. This is because if() statement requires a condition to work on and in your case it must be something which when equals to adcData should run the if statement. The error has occured beacuse in above code that something is missing. Perform a dry-run, you will be able to figure it out.

    April 3, 2018 at 6:33 pm #14827
    Ashutosh Bhatt
    Participant

    I think you are not familier with basics of C programming!!!!!

    if==adcData

    this does not have any meaning

    it must be

    if (x == adcdata)     // x can be any value

    if statemet in C programming checks boolean condition as true or false

  • Author
    Posts
Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.
Log In

RSS Recent Posts

  • RC Electronic Speed Control Capacitors February 17, 2026
  • Annex32 / Annex RDS For ESP Micros - A Quick and Dirty Example February 16, 2026
  • Convenient audio FFT module? February 16, 2026
  • CR2/CR123A Batteries In Projects February 16, 2026
  • Harman Kardon radio module BMW noise February 16, 2026

Stay Up To Date

Newsletter Signup
EngineersGarage

Copyright © 2026 WTWH Media LLC. All Rights Reserved. The material on this site may not be reproduced, distributed, transmitted, cached or otherwise used, except with the prior written permission of WTWH Media
Privacy Policy | Advertising | About Us

Search Engineers Garage

  • Engineers Garage Main Site
  • Visit our active EE Forums
    • EDABoard.com
    • Electro-Tech-Online
  • Projects & Tutorials
    • Circuits
    • Electronic Projects
    • Tutorials
    • Components
  • Digi-Key Store
    • Cables, Wires
    • Connectors, Interconnect
    • Discrete
    • Electromechanical
    • Embedded Computers
    • Enclosures, Hardware, Office
    • Integrated Circuits (ICs)
    • Isolators
    • LED/Optoelectronics
    • Passive
    • Power, Circuit Protection
    • Programmers
    • RF, Wireless
    • Semiconductors
    • Sensors, Transducers
    • Test Products
    • Tools
  • Advertise