Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8592517
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T23:46:07+00:00 2026-06-11T23:46:07+00:00

I recently took over some C and firmware responsibilities at work, and am having

  • 0

I recently took over some C and firmware responsibilities at work, and am having trouble with what seems like a basic issue but one that I can’t find the answer to. I’m not very experienced with C, but I’ve had many years of experience with higher level languages.

The firmware is written for a PIC18F4865 and I can’t get it to compile and program correctly. It was originally written on MPLAB IDE 8 using the HI-TECH PICC18 compiler, but I moved up to MPLAB X IDE and have been having problems.

First, I was using the same HI-TECH PICC18 compiler and it appeared to program successfully, but the device was not reading correctly. I then switched to the XC8 compiler and began to get an error message during compile that I can’t get around.

C:/_Sable/Firmware_C/lib\eeprom.h:10: error: no identifier in declaration
C:/_Sable/Firmware_C/lib\eeprom.h:10: error: ";" expected

The eeprom.h file is

#ifndef _EEPROM_H_
#define _EEPROM_H_

#define EE_ADDR(member) (offsetof(struct ee_map_s, (member)))

extern unsigned char eeprom_read(unsigned int); // this is line 10
extern void eeprom_write(unsigned int, unsigned char);
extern void ee_read(unsigned char, void *vp, unsigned char);
extern void ee_write(unsigned char, void *vp, unsigned char);

#endif

I looked around online and saw that this error can occur in a previous included file, and I checked that file and all appeared to be fine. I even rearranged the include order, think that the error message would change if that was the case, but the error still complains about this line.

I then thought maybe the function declaration was invalid because none of the parameters are named, so I changed line 10 to:

extern unsigned char eeprom_read(unsigned int addr)

This didn’t change anything. But I did have a weird feeling that when I cleaned and built again, it was not re-compiling eeprom.h. I don’t know if that happens or how to force it to recompile.

I don’t know if fixing this will fix the firmware issues I’m having or if I need to go back to MPLAB IDE 8, but it is still something I’d like to fix.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T23:46:08+00:00Added an answer on June 11, 2026 at 11:46 pm

    Some header file is using a macro to #define eeprom_read into something else, possibly the empty string. If you use a different function name, #undef eeprom_read, or do something else to cause the header to no longer make that macro, it should work.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I recently took over some work form another developer and am trying to understand
I recently took over an iOS project that seems to be crashing whenever I
I recently took over a project that has a pretty dirty database... The table
I recently took over management of a Windows 2003 server. The application log is
Recently I encountered a bug in an application I took over from another developer.
Just recently took over a project from my developer. I'm a noob to coding,
So, I took over an existing WinForms app recently. We need to change it
I recently took over a project and they have a SQL job setup to
I recently took up learning some css... and I am getting stuck on some
I recently took over development of a mobile website that uses the Facebook Graph

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.